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 | |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3 | # From configure.in Revision: 1.119 |
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 | e6c2cf1 | 1999-01-08 21:08:33 +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 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 17 | --with-next-archs='arch1 arch2 ..' build MAB binary" |
| 18 | ac_help="$ac_help |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 19 | --with-next-framework Build (OpenStep|Rhapsody|MacOS10) framework" |
| 20 | ac_help="$ac_help |
| 21 | --with-dyld Use (OpenStep|Rhapsody|MacOS10) dynamic linker" |
| 22 | ac_help="$ac_help |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 23 | --without-gcc never use gcc" |
| 24 | ac_help="$ac_help |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 25 | --with-cxx=<compiler> enable C++ support" |
| 26 | ac_help="$ac_help |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 27 | --with-libs='lib1 ...' link against additional libs" |
| 28 | ac_help="$ac_help |
Guido van Rossum | b06df27 | 1997-08-05 21:50:20 +0000 | [diff] [blame] | 29 | --with(out)-readline obsolete, edit Modules/Setup instead" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 30 | ac_help="$ac_help |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 31 | --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries" |
| 32 | ac_help="$ac_help |
| 33 | --with-threads alias for --with-thread" |
| 34 | ac_help="$ac_help |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 35 | --with-thread[=DIRECTORY] make interpreter thread-safe" |
| 36 | ac_help="$ac_help |
| 37 | --with-sgi-dl=DIRECTORY IRIX 4 dynamic linking" |
| 38 | ac_help="$ac_help |
| 39 | --with-dl-dld=DL_DIR,DLD_DIR GNU dynamic linking" |
| 40 | ac_help="$ac_help |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 41 | --with-fpectl enable SIGFPE catching" |
| 42 | ac_help="$ac_help |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 43 | --with-libm=STRING math library" |
| 44 | ac_help="$ac_help |
| 45 | --with-libc=STRING C library" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 46 | ac_help="$ac_help |
| 47 | --with-wctype-functions use wctype.h functions" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 48 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 49 | # Initialize some variables set by options. |
| 50 | # The variables have the same names as the options, with |
| 51 | # dashes changed to underlines. |
| 52 | build=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 53 | cache_file=./config.cache |
| 54 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 55 | host=NONE |
| 56 | no_create= |
| 57 | nonopt=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 58 | no_recursion= |
| 59 | prefix=NONE |
| 60 | program_prefix=NONE |
| 61 | program_suffix=NONE |
| 62 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 63 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 64 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 65 | srcdir= |
| 66 | target=NONE |
| 67 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 68 | x_includes=NONE |
| 69 | x_libraries=NONE |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 70 | bindir='${exec_prefix}/bin' |
| 71 | sbindir='${exec_prefix}/sbin' |
| 72 | libexecdir='${exec_prefix}/libexec' |
| 73 | datadir='${prefix}/share' |
| 74 | sysconfdir='${prefix}/etc' |
| 75 | sharedstatedir='${prefix}/com' |
| 76 | localstatedir='${prefix}/var' |
| 77 | libdir='${exec_prefix}/lib' |
| 78 | includedir='${prefix}/include' |
| 79 | oldincludedir='/usr/include' |
| 80 | infodir='${prefix}/info' |
| 81 | mandir='${prefix}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 82 | |
| 83 | # Initialize some other variables. |
| 84 | subdirs= |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 85 | MFLAGS= MAKEFLAGS= |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 86 | SHELL=${CONFIG_SHELL-/bin/sh} |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 87 | # Maximum number of lines to put in a shell here document. |
| 88 | ac_max_here_lines=12 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 89 | |
| 90 | ac_prev= |
| 91 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 92 | do |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 93 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 94 | # If the previous option needs an argument, assign it. |
| 95 | if test -n "$ac_prev"; then |
| 96 | eval "$ac_prev=\$ac_option" |
| 97 | ac_prev= |
| 98 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 99 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 100 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 101 | case "$ac_option" in |
| 102 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; |
| 103 | *) ac_optarg= ;; |
| 104 | esac |
| 105 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 106 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 107 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 108 | case "$ac_option" in |
| 109 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 110 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 111 | ac_prev=bindir ;; |
| 112 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
| 113 | bindir="$ac_optarg" ;; |
| 114 | |
| 115 | -build | --build | --buil | --bui | --bu) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 116 | ac_prev=build ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 117 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 118 | build="$ac_optarg" ;; |
| 119 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 120 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 121 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 122 | ac_prev=cache_file ;; |
| 123 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 124 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
| 125 | cache_file="$ac_optarg" ;; |
| 126 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 127 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
| 128 | ac_prev=datadir ;; |
| 129 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ |
| 130 | | --da=*) |
| 131 | datadir="$ac_optarg" ;; |
| 132 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 133 | -disable-* | --disable-*) |
| 134 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 135 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 136 | 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] | 137 | { 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] | 138 | fi |
| 139 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 140 | eval "enable_${ac_feature}=no" ;; |
| 141 | |
| 142 | -enable-* | --enable-*) |
| 143 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 144 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 145 | 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] | 146 | { 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] | 147 | fi |
| 148 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 149 | case "$ac_option" in |
| 150 | *=*) ;; |
| 151 | *) ac_optarg=yes ;; |
| 152 | esac |
| 153 | eval "enable_${ac_feature}='$ac_optarg'" ;; |
| 154 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 155 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 156 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 157 | | --exec | --exe | --ex) |
| 158 | ac_prev=exec_prefix ;; |
| 159 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 160 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 161 | | --exec=* | --exe=* | --ex=*) |
| 162 | exec_prefix="$ac_optarg" ;; |
| 163 | |
| 164 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 165 | # Obsolete; use --with-gas. |
| 166 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 167 | |
| 168 | -help | --help | --hel | --he) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 169 | # Omit some internal or obsolete options to make the list less imposing. |
| 170 | # 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] | 171 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 172 | Usage: configure [options] [host] |
| 173 | Options: [defaults in brackets after descriptions] |
| 174 | Configuration: |
| 175 | --cache-file=FILE cache test results in FILE |
| 176 | --help print this message |
| 177 | --no-create do not create output files |
| 178 | --quiet, --silent do not print \`checking...' messages |
| 179 | --version print the version of autoconf that created configure |
| 180 | Directory and file names: |
| 181 | --prefix=PREFIX install architecture-independent files in PREFIX |
| 182 | [$ac_default_prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 183 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 184 | [same as prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 185 | --bindir=DIR user executables in DIR [EPREFIX/bin] |
| 186 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] |
| 187 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] |
| 188 | --datadir=DIR read-only architecture-independent data in DIR |
| 189 | [PREFIX/share] |
| 190 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] |
| 191 | --sharedstatedir=DIR modifiable architecture-independent data in DIR |
| 192 | [PREFIX/com] |
| 193 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] |
| 194 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] |
| 195 | --includedir=DIR C header files in DIR [PREFIX/include] |
| 196 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] |
| 197 | --infodir=DIR info documentation in DIR [PREFIX/info] |
| 198 | --mandir=DIR man documentation in DIR [PREFIX/man] |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 199 | --srcdir=DIR find the sources in DIR [configure dir or ..] |
| 200 | --program-prefix=PREFIX prepend PREFIX to installed program names |
| 201 | --program-suffix=SUFFIX append SUFFIX to installed program names |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 202 | --program-transform-name=PROGRAM |
| 203 | run sed PROGRAM on installed program names |
| 204 | EOF |
| 205 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 206 | Host type: |
| 207 | --build=BUILD configure for building on BUILD [BUILD=HOST] |
| 208 | --host=HOST configure for HOST [guessed] |
| 209 | --target=TARGET configure for TARGET [TARGET=HOST] |
| 210 | Features and packages: |
| 211 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 212 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
| 213 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 214 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
| 215 | --x-includes=DIR X include files are in DIR |
| 216 | --x-libraries=DIR X library files are in DIR |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 217 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 218 | if test -n "$ac_help"; then |
| 219 | echo "--enable and --with options recognized:$ac_help" |
| 220 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 221 | exit 0 ;; |
| 222 | |
| 223 | -host | --host | --hos | --ho) |
| 224 | ac_prev=host ;; |
| 225 | -host=* | --host=* | --hos=* | --ho=*) |
| 226 | host="$ac_optarg" ;; |
| 227 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 228 | -includedir | --includedir | --includedi | --included | --include \ |
| 229 | | --includ | --inclu | --incl | --inc) |
| 230 | ac_prev=includedir ;; |
| 231 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 232 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
| 233 | includedir="$ac_optarg" ;; |
| 234 | |
| 235 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 236 | ac_prev=infodir ;; |
| 237 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
| 238 | infodir="$ac_optarg" ;; |
| 239 | |
| 240 | -libdir | --libdir | --libdi | --libd) |
| 241 | ac_prev=libdir ;; |
| 242 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
| 243 | libdir="$ac_optarg" ;; |
| 244 | |
| 245 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 246 | | --libexe | --libex | --libe) |
| 247 | ac_prev=libexecdir ;; |
| 248 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 249 | | --libexe=* | --libex=* | --libe=*) |
| 250 | libexecdir="$ac_optarg" ;; |
| 251 | |
| 252 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
| 253 | | --localstate | --localstat | --localsta | --localst \ |
| 254 | | --locals | --local | --loca | --loc | --lo) |
| 255 | ac_prev=localstatedir ;; |
| 256 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
| 257 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ |
| 258 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) |
| 259 | localstatedir="$ac_optarg" ;; |
| 260 | |
| 261 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 262 | ac_prev=mandir ;; |
| 263 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
| 264 | mandir="$ac_optarg" ;; |
| 265 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 266 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 267 | # Obsolete; use --without-fp. |
| 268 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 269 | |
| 270 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 271 | | --no-cr | --no-c) |
| 272 | no_create=yes ;; |
| 273 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 274 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 275 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 276 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 277 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 278 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 279 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 280 | | --oldin | --oldi | --old | --ol | --o) |
| 281 | ac_prev=oldincludedir ;; |
| 282 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 283 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 284 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
| 285 | oldincludedir="$ac_optarg" ;; |
| 286 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 287 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 288 | ac_prev=prefix ;; |
| 289 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
| 290 | prefix="$ac_optarg" ;; |
| 291 | |
| 292 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 293 | | --program-pre | --program-pr | --program-p) |
| 294 | ac_prev=program_prefix ;; |
| 295 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 296 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
| 297 | program_prefix="$ac_optarg" ;; |
| 298 | |
| 299 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 300 | | --program-suf | --program-su | --program-s) |
| 301 | ac_prev=program_suffix ;; |
| 302 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 303 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
| 304 | program_suffix="$ac_optarg" ;; |
| 305 | |
| 306 | -program-transform-name | --program-transform-name \ |
| 307 | | --program-transform-nam | --program-transform-na \ |
| 308 | | --program-transform-n | --program-transform- \ |
| 309 | | --program-transform | --program-transfor \ |
| 310 | | --program-transfo | --program-transf \ |
| 311 | | --program-trans | --program-tran \ |
| 312 | | --progr-tra | --program-tr | --program-t) |
| 313 | ac_prev=program_transform_name ;; |
| 314 | -program-transform-name=* | --program-transform-name=* \ |
| 315 | | --program-transform-nam=* | --program-transform-na=* \ |
| 316 | | --program-transform-n=* | --program-transform-=* \ |
| 317 | | --program-transform=* | --program-transfor=* \ |
| 318 | | --program-transfo=* | --program-transf=* \ |
| 319 | | --program-trans=* | --program-tran=* \ |
| 320 | | --progr-tra=* | --program-tr=* | --program-t=*) |
| 321 | program_transform_name="$ac_optarg" ;; |
| 322 | |
| 323 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 324 | | -silent | --silent | --silen | --sile | --sil) |
| 325 | silent=yes ;; |
| 326 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 327 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 328 | ac_prev=sbindir ;; |
| 329 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 330 | | --sbi=* | --sb=*) |
| 331 | sbindir="$ac_optarg" ;; |
| 332 | |
| 333 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 334 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 335 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 336 | | --sha | --sh) |
| 337 | ac_prev=sharedstatedir ;; |
| 338 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 339 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 340 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 341 | | --sha=* | --sh=*) |
| 342 | sharedstatedir="$ac_optarg" ;; |
| 343 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 344 | -site | --site | --sit) |
| 345 | ac_prev=site ;; |
| 346 | -site=* | --site=* | --sit=*) |
| 347 | site="$ac_optarg" ;; |
| 348 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 349 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 350 | ac_prev=srcdir ;; |
| 351 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
| 352 | srcdir="$ac_optarg" ;; |
| 353 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 354 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 355 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 356 | ac_prev=sysconfdir ;; |
| 357 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 358 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
| 359 | sysconfdir="$ac_optarg" ;; |
| 360 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 361 | -target | --target | --targe | --targ | --tar | --ta | --t) |
| 362 | ac_prev=target ;; |
| 363 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
| 364 | target="$ac_optarg" ;; |
| 365 | |
| 366 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 367 | verbose=yes ;; |
| 368 | |
| 369 | -version | --version | --versio | --versi | --vers) |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 370 | echo "configure generated by autoconf version 2.13" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 371 | exit 0 ;; |
| 372 | |
| 373 | -with-* | --with-*) |
| 374 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 375 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 376 | 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] | 377 | { 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] | 378 | fi |
| 379 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 380 | case "$ac_option" in |
| 381 | *=*) ;; |
| 382 | *) ac_optarg=yes ;; |
| 383 | esac |
| 384 | eval "with_${ac_package}='$ac_optarg'" ;; |
| 385 | |
| 386 | -without-* | --without-*) |
| 387 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 388 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 389 | 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] | 390 | { 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] | 391 | fi |
| 392 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 393 | eval "with_${ac_package}=no" ;; |
| 394 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 395 | --x) |
| 396 | # Obsolete; use --with-x. |
| 397 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 398 | |
| 399 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 400 | | --x-incl | --x-inc | --x-in | --x-i) |
| 401 | ac_prev=x_includes ;; |
| 402 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 403 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
| 404 | x_includes="$ac_optarg" ;; |
| 405 | |
| 406 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 407 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 408 | ac_prev=x_libraries ;; |
| 409 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 410 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
| 411 | x_libraries="$ac_optarg" ;; |
| 412 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 413 | -*) { 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] | 414 | ;; |
| 415 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 416 | *) |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 417 | 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] | 418 | echo "configure: warning: $ac_option: invalid host type" 1>&2 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 419 | fi |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 420 | if test "x$nonopt" != xNONE; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 421 | { 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] | 422 | fi |
| 423 | nonopt="$ac_option" |
| 424 | ;; |
| 425 | |
| 426 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 427 | done |
| 428 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 429 | if test -n "$ac_prev"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 430 | { 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] | 431 | fi |
| 432 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 433 | 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] | 434 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 435 | # File descriptor usage: |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 436 | # 0 standard input |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 437 | # 1 file creation |
| 438 | # 2 errors and warnings |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 439 | # 3 some systems may open it to /dev/tty |
| 440 | # 4 used on the Kubota Titan |
| 441 | # 6 checking for... messages and results |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 442 | # 5 compiler messages saved in config.log |
| 443 | if test "$silent" = yes; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 444 | exec 6>/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 445 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 446 | exec 6>&1 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 447 | fi |
| 448 | exec 5>./config.log |
| 449 | |
| 450 | echo "\ |
| 451 | This file contains any messages produced by compilers while |
| 452 | running configure, to aid debugging if configure makes a mistake. |
| 453 | " 1>&5 |
| 454 | |
| 455 | # Strip out --no-create and --no-recursion so they do not pile up. |
| 456 | # Also quote any args containing shell metacharacters. |
| 457 | ac_configure_args= |
| 458 | for ac_arg |
| 459 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 460 | case "$ac_arg" in |
| 461 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 462 | | --no-cr | --no-c) ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 463 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 464 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; |
| 465 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) |
| 466 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; |
| 467 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 468 | esac |
| 469 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 470 | |
| 471 | # NLS nuisances. |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 472 | # Only set these to C if already set. These must not be set unconditionally |
| 473 | # because not all systems understand e.g. LANG=C (notably SCO). |
| 474 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! |
| 475 | # Non-C LC_CTYPE values break the ctype check. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 476 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 477 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi |
| 478 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi |
| 479 | 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] | 480 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 481 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
| 482 | rm -rf conftest* confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 483 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. |
| 484 | echo > confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 485 | |
| 486 | # A filename unique to this package, relative to the directory that |
| 487 | # 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] | 488 | ac_unique_file=Include/object.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 489 | |
| 490 | # Find the source files, if location was not specified. |
| 491 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 492 | ac_srcdir_defaulted=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 493 | # Try the directory containing this script, then its parent. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 494 | ac_prog=$0 |
| 495 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` |
| 496 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
| 497 | srcdir=$ac_confdir |
| 498 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 499 | srcdir=.. |
| 500 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 501 | else |
| 502 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 503 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 504 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 505 | if test "$ac_srcdir_defaulted" = yes; then |
| 506 | { 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] | 507 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 508 | { 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] | 509 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 510 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 511 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` |
| 512 | |
| 513 | # Prefer explicitly selected file to automatically selected ones. |
| 514 | if test -z "$CONFIG_SITE"; then |
| 515 | if test "x$prefix" != xNONE; then |
| 516 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" |
| 517 | else |
| 518 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" |
| 519 | fi |
| 520 | fi |
| 521 | for ac_site_file in $CONFIG_SITE; do |
| 522 | if test -r "$ac_site_file"; then |
| 523 | echo "loading site script $ac_site_file" |
| 524 | . "$ac_site_file" |
| 525 | fi |
| 526 | done |
| 527 | |
| 528 | if test -r "$cache_file"; then |
| 529 | echo "loading cache $cache_file" |
| 530 | . $cache_file |
| 531 | else |
| 532 | echo "creating cache $cache_file" |
| 533 | > $cache_file |
| 534 | fi |
| 535 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 536 | ac_ext=c |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 537 | # 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] | 538 | ac_cpp='$CPP $CPPFLAGS' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 539 | 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] | 540 | 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] | 541 | cross_compiling=$ac_cv_prog_cc_cross |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 542 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 543 | ac_exeext= |
| 544 | ac_objext=o |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 545 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then |
| 546 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. |
| 547 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then |
| 548 | ac_n= ac_c=' |
| 549 | ' ac_t=' ' |
| 550 | else |
| 551 | ac_n=-n ac_c= ac_t= |
| 552 | fi |
| 553 | else |
| 554 | ac_n= ac_c='\c' ac_t= |
| 555 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 556 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 557 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 558 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 559 | |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 560 | # Set VERSION so we only need to edit in one place (i.e., here) |
| 561 | |
Guido van Rossum | 6a6a77c | 2000-03-31 15:15:17 +0000 | [diff] [blame] | 562 | VERSION=1.6 |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 563 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 564 | # NEXTSTEP stuff |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 565 | 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] | 566 | |
| 567 | echo $ac_n "checking for --with-next-archs""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 568 | echo "configure:569: checking for --with-next-archs" >&5 |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 569 | # Check whether --with-next-archs or --without-next-archs was given. |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 570 | if test "${with_next_archs+set}" = set; then |
| 571 | withval="$with_next_archs" |
| 572 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 573 | if test -n "$withval"; then |
| 574 | ac_arch_flags=`/usr/lib/arch_tool -archify_list $withval` |
| 575 | # GCC does not currently support multi archs on the NeXT |
| 576 | with_gcc=no |
| 577 | fi |
| 578 | echo "$ac_t""$with_next_archs" 1>&6 |
| 579 | |
| 580 | else |
| 581 | echo "$ac_t""none: using `arch`" 1>&6 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 582 | fi |
| 583 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 584 | |
| 585 | if test -z "$MACHDEP" |
| 586 | then |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 587 | set X `hostinfo | egrep '(NeXT Mach|Kernel Release).*:' | \ |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 588 | sed -e 's/://' -e 's/\./_/'` && \ |
| 589 | ac_sys_system=next && ac_sys_release=$4 |
| 590 | |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 591 | MACHDEP="$ac_sys_system$ac_sys_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 592 | fi |
| 593 | fi |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 594 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 595 | # Check whether --with-next-framework or --without-next-framework was given. |
| 596 | if test "${with_next_framework+set}" = set; then |
| 597 | withval="$with_next_framework" |
| 598 | : |
| 599 | fi |
| 600 | |
| 601 | # Check whether --with-dyld or --without-dyld was given. |
| 602 | if test "${with_dyld+set}" = set; then |
| 603 | withval="$with_dyld" |
| 604 | : |
| 605 | fi |
| 606 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 607 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 608 | # Set name for machine-dependent library files |
| 609 | |
| 610 | echo $ac_n "checking MACHDEP""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 611 | echo "configure:612: checking MACHDEP" >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 612 | if test -z "$MACHDEP" |
| 613 | then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 614 | ac_sys_system=`uname -s` |
| 615 | if test "$ac_sys_system" = "AIX" ; then |
| 616 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 617 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 618 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 619 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 620 | ac_md_system=`echo $ac_sys_system | |
| 621 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 622 | ac_md_release=`echo $ac_sys_release | |
| 623 | tr -d '/ ' | sed 's/\..*//'` |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 624 | MACHDEP="$ac_md_system$ac_md_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 625 | |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 626 | case $MACHDEP in |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 627 | '') MACHDEP="unknown";; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 628 | esac |
| 629 | fi |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 630 | |
| 631 | # |
| 632 | # SGI compilers allow the specification of the both the ABI and the |
| 633 | # ISA on the command line. Depending on the values of these switches, |
| 634 | # different and often incompatable code will be generated. |
| 635 | # |
| 636 | # The SGI_ABI variable can be used to modify the CC and LDFLAGS and |
| 637 | # thus supply support for various ABI/ISA combinations. The MACHDEP |
| 638 | # variable is also adjusted. |
| 639 | # |
| 640 | |
| 641 | if test ! -z "$SGI_ABI" |
| 642 | then |
| 643 | CC="cc $SGI_ABI" |
| 644 | LDFLAGS="$SGI_ABI $LDFLAGS" |
| 645 | MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'` |
| 646 | fi |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 647 | echo "$ac_t""$MACHDEP" 1>&6 |
| 648 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 649 | # |
| 650 | # CCC is the command that compiles C++ programs |
| 651 | # |
| 652 | # Not all make programs have this predefined. |
| 653 | # |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 654 | #AC_SUBST(SET_CCC) |
| 655 | #AC_MSG_CHECKING(CCC) |
| 656 | #if test -z "$CCC" |
| 657 | #then |
| 658 | # case $ac_sys_system in |
| 659 | # IRIX*) SET_CCC="CCC= CC ${SGI_ABI}";; |
| 660 | # Linux*) SET_CCC="CCC= g++";; |
| 661 | # *) SET_CCC="" |
| 662 | # esac |
| 663 | #else |
| 664 | # SET_CCC="CCC= ${CCC}" |
| 665 | #fi |
| 666 | #AC_MSG_RESULT($SET_CCC) |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 667 | |
| 668 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 669 | # checks for alternative programs |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 670 | echo $ac_n "checking for --without-gcc""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 671 | echo "configure:672: checking for --without-gcc" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 672 | # Check whether --with-gcc or --without-gcc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 673 | if test "${with_gcc+set}" = set; then |
| 674 | withval="$with_gcc" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 675 | |
| 676 | case $withval in |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 677 | no) CC=cc |
| 678 | without_gcc=yes;; |
| 679 | yes) CC=gcc |
| 680 | without_gcc=no;; |
| 681 | *) CC=$withval |
| 682 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 683 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 684 | else |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 685 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 686 | case $ac_sys_system in |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 687 | OSF1) CC=cc |
| 688 | without_gcc=;; |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 689 | BeOS*) |
| 690 | # Dunno if it's a good idea to get this over with all at once, or |
| 691 | # to handle it in with the other goodies. |
| 692 | MACHDEP=beos |
| 693 | |
| 694 | case $BE_HOST_CPU in |
| 695 | ppc) |
Guido van Rossum | 8137680 | 1999-04-06 15:50:51 +0000 | [diff] [blame] | 696 | CC="mwcc -I$PWD/BeOS -nodup" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 697 | without_gcc=yes |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 698 | case `uname -r` in |
| 699 | 4.0*) OPT="-DUSE_DL_EXPORT -O7 -opt schedule604 -export pragma" ;; |
| 700 | *) OPT="-DUSE_DL_EXPORT -O2 -proc 604e -export pragma" ;; |
| 701 | esac |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 702 | CCSHARED=-UUSE_DL_EXPORT |
| 703 | LDFLAGS="$LDFLAGS -nodup" |
| 704 | |
| 705 | AR="$PWD/BeOS/ar-fake" |
| 706 | RANLIB=: |
| 707 | |
| 708 | cat >> confdefs.h <<\EOF |
| 709 | #define DL_EXPORT_HEADER "dl_export.h" |
| 710 | EOF |
| 711 | |
| 712 | ;; |
| 713 | x86) |
| 714 | CC="gcc -I$PWD/BeOS" |
| 715 | without_gcc=no |
| 716 | OPT="-DUSE_DL_EXPORT -O3 -mpentiumpro" |
| 717 | CCSHARED=-UUSE_DL_EXPORT |
| 718 | |
| 719 | AR="$PWD/BeOS/ar-fake" |
| 720 | RANLIB=: |
| 721 | |
| 722 | cat >> confdefs.h <<\EOF |
| 723 | #define DL_EXPORT_HEADER "dl_export.h" |
| 724 | EOF |
| 725 | |
| 726 | ;; |
| 727 | *) |
| 728 | { echo "configure: error: Your BeOS system isn't PowerPC or x86... neat" 1>&2; exit 1; } |
| 729 | ;; |
| 730 | esac |
| 731 | ;; |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 732 | *) without_gcc=no;; |
| 733 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 734 | fi |
| 735 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 736 | echo "$ac_t""$without_gcc" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 737 | |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 738 | |
| 739 | |
| 740 | MAINOBJ=python.o |
| 741 | echo $ac_n "checking for --with-cxx=<compiler>""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 742 | echo "configure:743: checking for --with-cxx=<compiler>" >&5 |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 743 | # Check whether --with-cxx or --without-cxx was given. |
| 744 | if test "${with_cxx+set}" = set; then |
| 745 | withval="$with_cxx" |
| 746 | |
| 747 | case $withval in |
| 748 | no) CXX= |
| 749 | with_cxx=no;; |
| 750 | *) CXX=$withval |
| 751 | MAINOBJ=ccpython.o |
| 752 | with_cxx=$withval;; |
| 753 | esac |
| 754 | else |
| 755 | |
| 756 | with_cxx=no |
| 757 | |
| 758 | fi |
| 759 | |
| 760 | echo "$ac_t""$with_cxx" 1>&6 |
| 761 | SET_CXX="CXX = $CXX" |
| 762 | |
| 763 | #AC_MSG_CHECKING(CCC) |
| 764 | #if test -z "$CCC" |
| 765 | #then |
| 766 | # case $ac_sys_system in |
| 767 | # IRIX*) SET_CCC="CCC= CC ${SGI_ABI}";; |
| 768 | # Linux*) SET_CCC="CCC= g++";; |
| 769 | # *) SET_CCC="" |
| 770 | # esac |
| 771 | #else |
| 772 | # SET_CCC="CCC= ${CCC}" |
| 773 | #fi |
| 774 | #AC_MSG_RESULT($SET_CCC) |
| 775 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 776 | # If the user switches compilers, we can't believe the cache |
| 777 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 778 | then |
| 779 | { echo "configure: error: cached CC is different -- throw away $cache_file |
| 780 | (it is also a good idea to do 'make clean' before compiling)" 1>&2; exit 1; } |
| 781 | fi |
| 782 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 783 | # Extract the first word of "gcc", so it can be a program name with args. |
| 784 | set dummy gcc; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 785 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 786 | echo "configure:787: checking for $ac_word" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 787 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
| 788 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 789 | else |
| 790 | if test -n "$CC"; then |
| 791 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 792 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 793 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 794 | ac_dummy="$PATH" |
| 795 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 796 | test -z "$ac_dir" && ac_dir=. |
| 797 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 798 | ac_cv_prog_CC="gcc" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 799 | break |
| 800 | fi |
| 801 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 802 | IFS="$ac_save_ifs" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 803 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 804 | fi |
| 805 | CC="$ac_cv_prog_CC" |
| 806 | if test -n "$CC"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 807 | echo "$ac_t""$CC" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 808 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 809 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 810 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 811 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 812 | if test -z "$CC"; then |
| 813 | # Extract the first word of "cc", so it can be a program name with args. |
| 814 | set dummy cc; ac_word=$2 |
| 815 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 816 | echo "configure:817: checking for $ac_word" >&5 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 817 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
| 818 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 819 | else |
| 820 | if test -n "$CC"; then |
| 821 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 822 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 823 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 824 | ac_prog_rejected=no |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 825 | ac_dummy="$PATH" |
| 826 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 827 | test -z "$ac_dir" && ac_dir=. |
| 828 | if test -f $ac_dir/$ac_word; then |
| 829 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then |
| 830 | ac_prog_rejected=yes |
| 831 | continue |
| 832 | fi |
| 833 | ac_cv_prog_CC="cc" |
| 834 | break |
| 835 | fi |
| 836 | done |
| 837 | IFS="$ac_save_ifs" |
| 838 | if test $ac_prog_rejected = yes; then |
| 839 | # We found a bogon in the path, so make sure we never use it. |
| 840 | set dummy $ac_cv_prog_CC |
| 841 | shift |
| 842 | if test $# -gt 0; then |
| 843 | # We chose a different compiler from the bogus one. |
| 844 | # However, it has the same basename, so the bogon will be chosen |
| 845 | # first if we set CC to just the basename; use the full file name. |
| 846 | shift |
| 847 | set dummy "$ac_dir/$ac_word" "$@" |
| 848 | shift |
| 849 | ac_cv_prog_CC="$@" |
| 850 | fi |
| 851 | fi |
| 852 | fi |
| 853 | fi |
| 854 | CC="$ac_cv_prog_CC" |
| 855 | if test -n "$CC"; then |
| 856 | echo "$ac_t""$CC" 1>&6 |
| 857 | else |
| 858 | echo "$ac_t""no" 1>&6 |
| 859 | fi |
| 860 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 861 | if test -z "$CC"; then |
| 862 | case "`uname -s`" in |
| 863 | *win32* | *WIN32*) |
| 864 | # Extract the first word of "cl", so it can be a program name with args. |
| 865 | set dummy cl; ac_word=$2 |
| 866 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 867 | echo "configure:868: checking for $ac_word" >&5 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 868 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
| 869 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 870 | else |
| 871 | if test -n "$CC"; then |
| 872 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 873 | else |
| 874 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 875 | ac_dummy="$PATH" |
| 876 | for ac_dir in $ac_dummy; do |
| 877 | test -z "$ac_dir" && ac_dir=. |
| 878 | if test -f $ac_dir/$ac_word; then |
| 879 | ac_cv_prog_CC="cl" |
| 880 | break |
| 881 | fi |
| 882 | done |
| 883 | IFS="$ac_save_ifs" |
| 884 | fi |
| 885 | fi |
| 886 | CC="$ac_cv_prog_CC" |
| 887 | if test -n "$CC"; then |
| 888 | echo "$ac_t""$CC" 1>&6 |
| 889 | else |
| 890 | echo "$ac_t""no" 1>&6 |
| 891 | fi |
| 892 | ;; |
| 893 | esac |
| 894 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 895 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } |
| 896 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 897 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 898 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 899 | echo "configure:900: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 900 | |
| 901 | ac_ext=c |
| 902 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 903 | ac_cpp='$CPP $CPPFLAGS' |
| 904 | 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] | 905 | 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] | 906 | cross_compiling=$ac_cv_prog_cc_cross |
| 907 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 908 | cat > conftest.$ac_ext << EOF |
| 909 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 910 | #line 911 "configure" |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 911 | #include "confdefs.h" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 912 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 913 | main(){return(0);} |
| 914 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 915 | if { (eval echo configure:916: \"$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] | 916 | ac_cv_prog_cc_works=yes |
| 917 | # If we can't run a trivial program, we are probably using a cross compiler. |
| 918 | if (./conftest; exit) 2>/dev/null; then |
| 919 | ac_cv_prog_cc_cross=no |
| 920 | else |
| 921 | ac_cv_prog_cc_cross=yes |
| 922 | fi |
| 923 | else |
| 924 | echo "configure: failed program was:" >&5 |
| 925 | cat conftest.$ac_ext >&5 |
| 926 | ac_cv_prog_cc_works=no |
| 927 | fi |
| 928 | rm -fr conftest* |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 929 | ac_ext=c |
| 930 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 931 | ac_cpp='$CPP $CPPFLAGS' |
| 932 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 933 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 934 | cross_compiling=$ac_cv_prog_cc_cross |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 935 | |
| 936 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 |
| 937 | if test $ac_cv_prog_cc_works = no; then |
| 938 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } |
| 939 | fi |
| 940 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 941 | echo "configure:942: 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] | 942 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
| 943 | cross_compiling=$ac_cv_prog_cc_cross |
| 944 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 945 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 946 | echo "configure:947: checking whether we are using GNU C" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 947 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
| 948 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 949 | else |
| 950 | cat > conftest.c <<EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 951 | #ifdef __GNUC__ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 952 | yes; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 953 | #endif |
| 954 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 955 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:956: \"$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] | 956 | ac_cv_prog_gcc=yes |
| 957 | else |
| 958 | ac_cv_prog_gcc=no |
| 959 | fi |
| 960 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 961 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 962 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 963 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 964 | if test $ac_cv_prog_gcc = yes; then |
| 965 | GCC=yes |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 966 | else |
| 967 | GCC= |
| 968 | fi |
| 969 | |
| 970 | ac_test_CFLAGS="${CFLAGS+set}" |
| 971 | ac_save_CFLAGS="$CFLAGS" |
| 972 | CFLAGS= |
| 973 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 974 | echo "configure:975: checking whether ${CC-cc} accepts -g" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 975 | 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] | 976 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 977 | else |
| 978 | echo 'void f(){}' > conftest.c |
| 979 | 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] | 980 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 981 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 982 | ac_cv_prog_cc_g=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 983 | fi |
| 984 | rm -f conftest* |
| 985 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 986 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 987 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 988 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 989 | if test "$ac_test_CFLAGS" = set; then |
| 990 | CFLAGS="$ac_save_CFLAGS" |
| 991 | elif test $ac_cv_prog_cc_g = yes; then |
| 992 | if test "$GCC" = yes; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 993 | CFLAGS="-g -O2" |
| 994 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 995 | CFLAGS="-g" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 996 | fi |
| 997 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 998 | if test "$GCC" = yes; then |
| 999 | CFLAGS="-O2" |
| 1000 | else |
| 1001 | CFLAGS= |
| 1002 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1003 | fi |
| 1004 | |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1005 | |
Guido van Rossum | dd997f7 | 1998-10-07 19:58:26 +0000 | [diff] [blame] | 1006 | case $MACHDEP in |
| 1007 | bsdos*) |
| 1008 | case $CC in |
| 1009 | gcc) CC="$CC -D_HAVE_BSDI";; |
| 1010 | esac;; |
| 1011 | esac |
| 1012 | |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 1013 | case $ac_sys_system in |
| 1014 | hp*|HP*) |
| 1015 | case $CC in |
| 1016 | cc|*/cc) CC="$CC -Aa -D_HPUX_SOURCE";; |
| 1017 | esac;; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1018 | BeOS*) |
| 1019 | case $CC in |
| 1020 | cc) CC=cc;; |
| 1021 | esac;; |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 1022 | esac |
| 1023 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1024 | # LDLIBRARY is the name of the library to link against (as opposed to the |
| 1025 | # name of the library into which to insert object files). On systems |
| 1026 | # without shared libraries, LDLIBRARY is the same as LIBRARY (defined in |
| 1027 | # the Makefiles). |
| 1028 | |
| 1029 | |
| 1030 | LDLIBRARY='' |
| 1031 | |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1032 | # LINKCC is the command that links the python executable -- default is $(CC). |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1033 | # This is altered for AIX and BeOS in order to build the export list before |
| 1034 | # linking. |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1035 | |
| 1036 | echo $ac_n "checking LINKCC""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1037 | echo "configure:1038: checking LINKCC" >&5 |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 1038 | if test -z "$LINKCC" -a ! -z "$CXX" |
| 1039 | then |
| 1040 | LINKCC="$CXX" |
| 1041 | fi |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1042 | if test -z "$LINKCC" |
| 1043 | then |
| 1044 | case $ac_sys_system in |
| 1045 | AIX*) |
Guido van Rossum | 45140f9 | 1997-08-29 18:44:06 +0000 | [diff] [blame] | 1046 | LINKCC="\$(srcdir)/makexp_aix python.exp \"\" \$(LIBRARY); \$(PURIFY) \$(CC)";; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1047 | BeOS*) |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 1048 | LINKCC="\$(srcdir)/../BeOS/linkcc \$(LIBRARY) \$(PURIFY) \$(CC) \$(OPT)" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1049 | LDLIBRARY='libpython$(VERSION).so';; |
Guido van Rossum | 3c4bb80 | 1997-12-18 23:55:32 +0000 | [diff] [blame] | 1050 | dgux*) |
| 1051 | LINKCC="LD_RUN_PATH=$libdir \$(PURIFY) \$(CC)";; |
Guido van Rossum | 25f9303 | 1997-08-18 16:00:04 +0000 | [diff] [blame] | 1052 | *) LINKCC="\$(PURIFY) \$(CC)";; |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1053 | esac |
| 1054 | fi |
| 1055 | echo "$ac_t""$LINKCC" 1>&6 |
| 1056 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1057 | echo $ac_n "checking LDLIBRARY""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1058 | echo "configure:1059: checking LDLIBRARY" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1059 | |
| 1060 | # NeXT framework builds require that the 'ar' library be converted into |
| 1061 | # a bundle using libtool. |
| 1062 | if test "$with_next_framework" |
| 1063 | then |
| 1064 | LDLIBRARY='libpython$(VERSION).dylib' |
| 1065 | fi |
| 1066 | |
| 1067 | # DG/UX requires some fancy ld contortions to produce a .so from an .a |
| 1068 | if test "$MACHDEP" = "dguxR4" |
| 1069 | then |
| 1070 | LDLIBRARY='libpython$(VERSION).so' |
| 1071 | OPT="$OPT -pic" |
| 1072 | fi |
| 1073 | echo "$ac_t""$LDLIBRARY" 1>&6 |
| 1074 | |
| 1075 | # If LDLIBRARY is different from LIBRARY, emit a rule to build it. |
| 1076 | if test -z "$LDLIBRARY" |
| 1077 | then |
| 1078 | LDLIBRARY='libpython$(VERSION).a' |
| 1079 | MAKE_LDLIBRARY="true" |
| 1080 | else |
| 1081 | MAKE_LDLIBRARY='$(MAKE) $(LDLIBRARY)' |
| 1082 | fi |
| 1083 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1084 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 1085 | set dummy ranlib; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1086 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1087 | echo "configure:1088: checking for $ac_word" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1088 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
| 1089 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1090 | else |
| 1091 | if test -n "$RANLIB"; then |
| 1092 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 1093 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1094 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 1095 | ac_dummy="$PATH" |
| 1096 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1097 | test -z "$ac_dir" && ac_dir=. |
| 1098 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1099 | ac_cv_prog_RANLIB="ranlib" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1100 | break |
| 1101 | fi |
| 1102 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1103 | IFS="$ac_save_ifs" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1104 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1105 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1106 | fi |
| 1107 | RANLIB="$ac_cv_prog_RANLIB" |
| 1108 | if test -n "$RANLIB"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1109 | echo "$ac_t""$RANLIB" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1110 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1111 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1112 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1113 | |
| 1114 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1115 | for ac_prog in ar aal |
| 1116 | do |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1117 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 1118 | set dummy $ac_prog; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1119 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1120 | echo "configure:1121: checking for $ac_word" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1121 | if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then |
| 1122 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1123 | else |
| 1124 | if test -n "$AR"; then |
| 1125 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 1126 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1127 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 1128 | ac_dummy="$PATH" |
| 1129 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1130 | test -z "$ac_dir" && ac_dir=. |
| 1131 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1132 | ac_cv_prog_AR="$ac_prog" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1133 | break |
| 1134 | fi |
| 1135 | done |
| 1136 | IFS="$ac_save_ifs" |
| 1137 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1138 | fi |
| 1139 | AR="$ac_cv_prog_AR" |
| 1140 | if test -n "$AR"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1141 | echo "$ac_t""$AR" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1142 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1143 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1144 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1145 | |
| 1146 | test -n "$AR" && break |
| 1147 | done |
| 1148 | test -n "$AR" || AR="ar" |
| 1149 | |
| 1150 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1151 | |
| 1152 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1153 | # Install just never works :-( |
| 1154 | if test -z "$INSTALL" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1155 | then |
| 1156 | INSTALL=cp |
| 1157 | INSTALL_PROGRAM=cp |
| 1158 | INSTALL_DATA=cp |
| 1159 | else |
| 1160 | INSTALL_PROGRAM="$INSTALL" |
| 1161 | INSTALL_DATA="$INSTALL -m 644" |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1162 | fi |
| 1163 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1164 | # Not every filesystem supports hard links |
| 1165 | |
| 1166 | if test -z "$LN" ; then |
| 1167 | case $ac_sys_system in |
| 1168 | BeOS*) LN="ln -s";; |
| 1169 | *) LN=ln;; |
| 1170 | esac |
| 1171 | fi |
| 1172 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1173 | # Optimizer/debugger flags passed between Makefiles |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1174 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1175 | if test -z "$OPT" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1176 | then |
Guido van Rossum | edca74a | 1997-07-18 23:29:40 +0000 | [diff] [blame] | 1177 | case $GCC in |
| 1178 | yes) |
| 1179 | case $ac_cv_prog_cc_g in |
| 1180 | yes) OPT="-g -O2";; |
| 1181 | *) OPT="-O2";; |
| 1182 | esac |
| 1183 | ;; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1184 | *) OPT="-O";; |
| 1185 | esac |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1186 | fi |
| 1187 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1188 | if test "$ac_arch_flags" |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 1189 | then |
| 1190 | OPT="$OPT $ac_arch_flags" |
| 1191 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1192 | # checks for UNIX variants that set C preprocessor variables |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1193 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1194 | echo "configure:1195: checking how to run the C preprocessor" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1195 | # On Suns, sometimes $CPP names a directory. |
| 1196 | if test -n "$CPP" && test -d "$CPP"; then |
| 1197 | CPP= |
| 1198 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1199 | if test -z "$CPP"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1200 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then |
| 1201 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1202 | else |
| 1203 | # This must be in double quotes, not single quotes, because CPP may get |
| 1204 | # substituted into the Makefile and "${CC-cc}" will confuse make. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1205 | CPP="${CC-cc} -E" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1206 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 1207 | # not just through cpp. |
| 1208 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1209 | #line 1210 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1210 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1211 | #include <assert.h> |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1212 | Syntax Error |
| 1213 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1214 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1215 | { (eval echo configure:1216: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1216 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1217 | if test -z "$ac_err"; then |
| 1218 | : |
| 1219 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1220 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1221 | echo "configure: failed program was:" >&5 |
| 1222 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1223 | rm -rf conftest* |
| 1224 | CPP="${CC-cc} -E -traditional-cpp" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1225 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1226 | #line 1227 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1227 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1228 | #include <assert.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1229 | Syntax Error |
| 1230 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1231 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1232 | { (eval echo configure:1233: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1233 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 1234 | if test -z "$ac_err"; then |
| 1235 | : |
| 1236 | else |
| 1237 | echo "$ac_err" >&5 |
| 1238 | echo "configure: failed program was:" >&5 |
| 1239 | cat conftest.$ac_ext >&5 |
| 1240 | rm -rf conftest* |
| 1241 | CPP="${CC-cc} -nologo -E" |
| 1242 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1243 | #line 1244 "configure" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1244 | #include "confdefs.h" |
| 1245 | #include <assert.h> |
| 1246 | Syntax Error |
| 1247 | EOF |
| 1248 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1249 | { (eval echo configure:1250: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1250 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1251 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1252 | : |
| 1253 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1254 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1255 | echo "configure: failed program was:" >&5 |
| 1256 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1257 | rm -rf conftest* |
| 1258 | CPP=/lib/cpp |
| 1259 | fi |
| 1260 | rm -f conftest* |
| 1261 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1262 | rm -f conftest* |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1263 | fi |
| 1264 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1265 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1266 | fi |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 1267 | CPP="$ac_cv_prog_CPP" |
| 1268 | else |
| 1269 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1270 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1271 | echo "$ac_t""$CPP" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1272 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1273 | echo $ac_n "checking for AIX""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1274 | echo "configure:1275: checking for AIX" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1275 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1276 | #line 1277 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1277 | #include "confdefs.h" |
| 1278 | #ifdef _AIX |
| 1279 | yes |
| 1280 | #endif |
| 1281 | |
| 1282 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1283 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1284 | egrep "yes" >/dev/null 2>&1; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1285 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1286 | echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1287 | #define _ALL_SOURCE 1 |
| 1288 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1289 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1290 | else |
| 1291 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1292 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1293 | fi |
| 1294 | rm -f conftest* |
| 1295 | |
| 1296 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1297 | ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1298 | echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1299 | echo "configure:1300: checking for minix/config.h" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1300 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 1301 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1302 | else |
| 1303 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1304 | #line 1305 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1305 | #include "confdefs.h" |
| 1306 | #include <minix/config.h> |
| 1307 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1308 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1309 | { (eval echo configure:1310: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1310 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1311 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1312 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1313 | eval "ac_cv_header_$ac_safe=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1314 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1315 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1316 | echo "configure: failed program was:" >&5 |
| 1317 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1318 | rm -rf conftest* |
| 1319 | eval "ac_cv_header_$ac_safe=no" |
| 1320 | fi |
| 1321 | rm -f conftest* |
| 1322 | fi |
| 1323 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1324 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1325 | MINIX=yes |
| 1326 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1327 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1328 | MINIX= |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1329 | fi |
| 1330 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1331 | if test "$MINIX" = yes; then |
| 1332 | cat >> confdefs.h <<\EOF |
| 1333 | #define _POSIX_SOURCE 1 |
| 1334 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1335 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1336 | cat >> confdefs.h <<\EOF |
| 1337 | #define _POSIX_1_SOURCE 2 |
| 1338 | EOF |
| 1339 | |
| 1340 | cat >> confdefs.h <<\EOF |
| 1341 | #define _MINIX 1 |
| 1342 | EOF |
| 1343 | |
| 1344 | fi |
| 1345 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1346 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1347 | echo $ac_n "checking whether $CC accepts -OPT:Olimit=0""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1348 | echo "configure:1349: checking whether $CC accepts -OPT:Olimit=0" >&5 |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1349 | if eval "test \"`echo '$''{'ac_cv_opt_olimit_ok'+set}'`\" = set"; then |
| 1350 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1351 | else |
| 1352 | ac_save_cc="$CC" |
| 1353 | CC="$CC -OPT:Olimit=0" |
| 1354 | if test "$cross_compiling" = yes; then |
| 1355 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1356 | else |
| 1357 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1358 | #line 1359 "configure" |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1359 | #include "confdefs.h" |
| 1360 | int main() { return 0; } |
| 1361 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1362 | if { (eval echo configure:1363: \"$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] | 1363 | then |
| 1364 | ac_cv_opt_olimit_ok=yes |
| 1365 | else |
| 1366 | echo "configure: failed program was:" >&5 |
| 1367 | cat conftest.$ac_ext >&5 |
| 1368 | rm -fr conftest* |
| 1369 | ac_cv_opt_olimit_ok=no |
| 1370 | fi |
| 1371 | rm -fr conftest* |
| 1372 | fi |
| 1373 | |
| 1374 | CC="$ac_save_cc" |
| 1375 | fi |
| 1376 | |
| 1377 | echo "$ac_t""$ac_cv_opt_olimit_ok" 1>&6 |
Guido van Rossum | 2efa34b | 1997-10-23 17:43:11 +0000 | [diff] [blame] | 1378 | if test $ac_cv_opt_olimit_ok = yes; then |
Guido van Rossum | 304dd2d | 1997-10-20 23:10:56 +0000 | [diff] [blame] | 1379 | OPT="$OPT -OPT:Olimit=0" |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1380 | else |
| 1381 | echo $ac_n "checking whether $CC accepts -Olimit 1500""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1382 | echo "configure:1383: checking whether $CC accepts -Olimit 1500" >&5 |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1383 | if eval "test \"`echo '$''{'ac_cv_olimit_ok'+set}'`\" = set"; then |
| 1384 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1385 | else |
| 1386 | ac_save_cc="$CC" |
| 1387 | CC="$CC -Olimit 1500" |
| 1388 | if test "$cross_compiling" = yes; then |
| 1389 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1390 | else |
| 1391 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1392 | #line 1393 "configure" |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1393 | #include "confdefs.h" |
| 1394 | int main() { return 0; } |
| 1395 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1396 | if { (eval echo configure:1397: \"$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] | 1397 | then |
| 1398 | ac_cv_olimit_ok=yes |
| 1399 | else |
| 1400 | echo "configure: failed program was:" >&5 |
| 1401 | cat conftest.$ac_ext >&5 |
| 1402 | rm -fr conftest* |
| 1403 | ac_cv_olimit_ok=no |
Guido van Rossum | 201afe5 | 1997-05-14 21:14:44 +0000 | [diff] [blame] | 1404 | fi |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1405 | rm -fr conftest* |
| 1406 | fi |
| 1407 | |
| 1408 | CC="$ac_save_cc" |
| 1409 | fi |
| 1410 | |
| 1411 | echo "$ac_t""$ac_cv_olimit_ok" 1>&6 |
| 1412 | if test $ac_cv_olimit_ok = yes; then |
| 1413 | OPT="$OPT -Olimit 1500" |
| 1414 | fi |
| 1415 | fi |
| 1416 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1417 | # check for ANSI or K&R ("traditional") preprocessor |
| 1418 | echo $ac_n "checking for C preprocessor type""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1419 | echo "configure:1420: checking for C preprocessor type" >&5 |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1420 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1421 | #line 1422 "configure" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1422 | #include "confdefs.h" |
| 1423 | |
| 1424 | #define spam(name, doc) {#name, &name, #name "() -- " doc} |
| 1425 | int foo; |
| 1426 | struct {char *name; int *addr; char *doc;} desc = spam(foo, "something"); |
| 1427 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1428 | int main() { |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1429 | ; |
| 1430 | ; return 0; } |
| 1431 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1432 | if { (eval echo configure:1433: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1433 | rm -rf conftest* |
| 1434 | cpp_type=ansi |
| 1435 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1436 | echo "configure: failed program was:" >&5 |
| 1437 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1438 | rm -rf conftest* |
| 1439 | cat >> confdefs.h <<\EOF |
| 1440 | #define HAVE_OLD_CPP 1 |
| 1441 | EOF |
| 1442 | cpp_type=traditional |
| 1443 | fi |
| 1444 | rm -f conftest* |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1445 | echo "$ac_t""$cpp_type" 1>&6 |
| 1446 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1447 | # checks for header files |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1448 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1449 | echo "configure:1450: checking for ANSI C header files" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1450 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
| 1451 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1452 | else |
| 1453 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1454 | #line 1455 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1455 | #include "confdefs.h" |
| 1456 | #include <stdlib.h> |
| 1457 | #include <stdarg.h> |
| 1458 | #include <string.h> |
| 1459 | #include <float.h> |
| 1460 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1461 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1462 | { (eval echo configure:1463: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1463 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1464 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1465 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1466 | ac_cv_header_stdc=yes |
| 1467 | else |
| 1468 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1469 | echo "configure: failed program was:" >&5 |
| 1470 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1471 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1472 | ac_cv_header_stdc=no |
| 1473 | fi |
| 1474 | rm -f conftest* |
| 1475 | |
| 1476 | if test $ac_cv_header_stdc = yes; then |
| 1477 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 1478 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1479 | #line 1480 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1480 | #include "confdefs.h" |
| 1481 | #include <string.h> |
| 1482 | EOF |
| 1483 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1484 | egrep "memchr" >/dev/null 2>&1; then |
| 1485 | : |
| 1486 | else |
| 1487 | rm -rf conftest* |
| 1488 | ac_cv_header_stdc=no |
| 1489 | fi |
| 1490 | rm -f conftest* |
| 1491 | |
| 1492 | fi |
| 1493 | |
| 1494 | if test $ac_cv_header_stdc = yes; then |
| 1495 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 1496 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1497 | #line 1498 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1498 | #include "confdefs.h" |
| 1499 | #include <stdlib.h> |
| 1500 | EOF |
| 1501 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1502 | egrep "free" >/dev/null 2>&1; then |
| 1503 | : |
| 1504 | else |
| 1505 | rm -rf conftest* |
| 1506 | ac_cv_header_stdc=no |
| 1507 | fi |
| 1508 | rm -f conftest* |
| 1509 | |
| 1510 | fi |
| 1511 | |
| 1512 | if test $ac_cv_header_stdc = yes; then |
| 1513 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 1514 | if test "$cross_compiling" = yes; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1515 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1516 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1517 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1518 | #line 1519 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1519 | #include "confdefs.h" |
| 1520 | #include <ctype.h> |
| 1521 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 1522 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1523 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1524 | int main () { int i; for (i = 0; i < 256; i++) |
| 1525 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); |
| 1526 | exit (0); } |
| 1527 | |
| 1528 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1529 | if { (eval echo configure:1530: \"$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] | 1530 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1531 | : |
| 1532 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1533 | echo "configure: failed program was:" >&5 |
| 1534 | cat conftest.$ac_ext >&5 |
| 1535 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1536 | ac_cv_header_stdc=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1537 | fi |
| 1538 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1539 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1540 | |
| 1541 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1542 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1543 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1544 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1545 | if test $ac_cv_header_stdc = yes; then |
| 1546 | cat >> confdefs.h <<\EOF |
| 1547 | #define STDC_HEADERS 1 |
| 1548 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1549 | |
| 1550 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1551 | |
Guido van Rossum | 9601315 | 1997-10-08 22:47:52 +0000 | [diff] [blame] | 1552 | for ac_hdr in dlfcn.h fcntl.h limits.h locale.h ncurses.h pthread.h \ |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 1553 | signal.h stdarg.h stddef.h stdlib.h thread.h unistd.h utime.h \ |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1554 | sys/audioio.h sys/file.h sys/lock.h \ |
| 1555 | sys/param.h sys/select.h sys/time.h sys/times.h \ |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 1556 | sys/un.h sys/utsname.h sys/wait.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1557 | do |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1558 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1559 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1560 | echo "configure:1561: checking for $ac_hdr" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1561 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 1562 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1563 | else |
| 1564 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1565 | #line 1566 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1566 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1567 | #include <$ac_hdr> |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1568 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1569 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1570 | { (eval echo configure:1571: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1571 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1572 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1573 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1574 | eval "ac_cv_header_$ac_safe=yes" |
| 1575 | else |
| 1576 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1577 | echo "configure: failed program was:" >&5 |
| 1578 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1579 | rm -rf conftest* |
| 1580 | eval "ac_cv_header_$ac_safe=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1581 | fi |
| 1582 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1583 | fi |
| 1584 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1585 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1586 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1587 | cat >> confdefs.h <<EOF |
| 1588 | #define $ac_tr_hdr 1 |
| 1589 | EOF |
| 1590 | |
| 1591 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1592 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1593 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1594 | done |
| 1595 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1596 | ac_header_dirent=no |
| 1597 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h |
| 1598 | do |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1599 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1600 | echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1601 | echo "configure:1602: checking for $ac_hdr that defines DIR" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1602 | if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then |
| 1603 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1604 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1605 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1606 | #line 1607 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1607 | #include "confdefs.h" |
| 1608 | #include <sys/types.h> |
| 1609 | #include <$ac_hdr> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1610 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1611 | DIR *dirp = 0; |
| 1612 | ; return 0; } |
| 1613 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1614 | if { (eval echo configure:1615: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1615 | rm -rf conftest* |
| 1616 | eval "ac_cv_header_dirent_$ac_safe=yes" |
| 1617 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1618 | echo "configure: failed program was:" >&5 |
| 1619 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1620 | rm -rf conftest* |
| 1621 | eval "ac_cv_header_dirent_$ac_safe=no" |
| 1622 | fi |
| 1623 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1624 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1625 | 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] | 1626 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1627 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1628 | cat >> confdefs.h <<EOF |
| 1629 | #define $ac_tr_hdr 1 |
| 1630 | EOF |
| 1631 | ac_header_dirent=$ac_hdr; break |
| 1632 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1633 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1634 | fi |
| 1635 | done |
| 1636 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 1637 | if test $ac_header_dirent = dirent.h; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1638 | echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1639 | echo "configure:1640: checking for opendir in -ldir" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1640 | ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1641 | 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] | 1642 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1643 | else |
| 1644 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1645 | LIBS="-ldir $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1646 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1647 | #line 1648 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1648 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1649 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1650 | /* We use char because int might match the return type of a gcc2 |
| 1651 | builtin and then its argument prototype would still apply. */ |
| 1652 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1653 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1654 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1655 | opendir() |
| 1656 | ; return 0; } |
| 1657 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1658 | if { (eval echo configure:1659: \"$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] | 1659 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1660 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1661 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1662 | echo "configure: failed program was:" >&5 |
| 1663 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1664 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1665 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1666 | fi |
| 1667 | rm -f conftest* |
| 1668 | LIBS="$ac_save_LIBS" |
| 1669 | |
| 1670 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1671 | 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] | 1672 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1673 | LIBS="$LIBS -ldir" |
| 1674 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1675 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1676 | fi |
| 1677 | |
| 1678 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1679 | echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1680 | echo "configure:1681: checking for opendir in -lx" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1681 | ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1682 | 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] | 1683 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1684 | else |
| 1685 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1686 | LIBS="-lx $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1687 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1688 | #line 1689 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1689 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1690 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1691 | /* We use char because int might match the return type of a gcc2 |
| 1692 | builtin and then its argument prototype would still apply. */ |
| 1693 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1694 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1695 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1696 | opendir() |
| 1697 | ; return 0; } |
| 1698 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1699 | if { (eval echo configure:1700: \"$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] | 1700 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1701 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1702 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1703 | echo "configure: failed program was:" >&5 |
| 1704 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1705 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1706 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1707 | fi |
| 1708 | rm -f conftest* |
| 1709 | LIBS="$ac_save_LIBS" |
| 1710 | |
| 1711 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1712 | 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] | 1713 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1714 | LIBS="$LIBS -lx" |
| 1715 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1716 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1717 | fi |
| 1718 | |
| 1719 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1720 | |
| 1721 | |
| 1722 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1723 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1724 | echo $ac_n "checking for clock_t in time.h""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1725 | echo "configure:1726: checking for clock_t in time.h" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1726 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1727 | #line 1728 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1728 | #include "confdefs.h" |
| 1729 | #include <time.h> |
| 1730 | EOF |
| 1731 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1732 | egrep "clock_t" >/dev/null 2>&1; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1733 | rm -rf conftest* |
| 1734 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1735 | else |
| 1736 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1737 | cat >> confdefs.h <<\EOF |
| 1738 | #define clock_t long |
| 1739 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1740 | |
| 1741 | fi |
| 1742 | rm -f conftest* |
| 1743 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1744 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1745 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1746 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 1747 | cat >> confdefs.h <<\EOF |
| 1748 | #if defined(SCO_DS) |
| 1749 | #undef _OFF_T |
| 1750 | #endif |
| 1751 | EOF |
| 1752 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1753 | # Type availability checks |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1754 | echo $ac_n "checking for mode_t""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1755 | echo "configure:1756: checking for mode_t" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1756 | if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then |
| 1757 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1758 | else |
| 1759 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1760 | #line 1761 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1761 | #include "confdefs.h" |
| 1762 | #include <sys/types.h> |
| 1763 | #if STDC_HEADERS |
| 1764 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1765 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1766 | #endif |
| 1767 | EOF |
| 1768 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1769 | 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] | 1770 | rm -rf conftest* |
| 1771 | ac_cv_type_mode_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1772 | else |
| 1773 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1774 | ac_cv_type_mode_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1775 | fi |
| 1776 | rm -f conftest* |
| 1777 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1778 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1779 | echo "$ac_t""$ac_cv_type_mode_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1780 | if test $ac_cv_type_mode_t = no; then |
| 1781 | cat >> confdefs.h <<\EOF |
| 1782 | #define mode_t int |
| 1783 | EOF |
| 1784 | |
| 1785 | fi |
| 1786 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1787 | echo $ac_n "checking for off_t""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1788 | echo "configure:1789: checking for off_t" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1789 | if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then |
| 1790 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1791 | else |
| 1792 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1793 | #line 1794 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1794 | #include "confdefs.h" |
| 1795 | #include <sys/types.h> |
| 1796 | #if STDC_HEADERS |
| 1797 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1798 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1799 | #endif |
| 1800 | EOF |
| 1801 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1802 | 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] | 1803 | rm -rf conftest* |
| 1804 | ac_cv_type_off_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1805 | else |
| 1806 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1807 | ac_cv_type_off_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1808 | fi |
| 1809 | rm -f conftest* |
| 1810 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1811 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1812 | echo "$ac_t""$ac_cv_type_off_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1813 | if test $ac_cv_type_off_t = no; then |
| 1814 | cat >> confdefs.h <<\EOF |
| 1815 | #define off_t long |
| 1816 | EOF |
| 1817 | |
| 1818 | fi |
| 1819 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1820 | echo $ac_n "checking for pid_t""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1821 | echo "configure:1822: checking for pid_t" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1822 | if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then |
| 1823 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1824 | else |
| 1825 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1826 | #line 1827 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1827 | #include "confdefs.h" |
| 1828 | #include <sys/types.h> |
| 1829 | #if STDC_HEADERS |
| 1830 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1831 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1832 | #endif |
| 1833 | EOF |
| 1834 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1835 | 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] | 1836 | rm -rf conftest* |
| 1837 | ac_cv_type_pid_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1838 | else |
| 1839 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1840 | ac_cv_type_pid_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1841 | fi |
| 1842 | rm -f conftest* |
| 1843 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1844 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1845 | echo "$ac_t""$ac_cv_type_pid_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1846 | if test $ac_cv_type_pid_t = no; then |
| 1847 | cat >> confdefs.h <<\EOF |
| 1848 | #define pid_t int |
| 1849 | EOF |
| 1850 | |
| 1851 | fi |
| 1852 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1853 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1854 | echo "configure:1855: checking return type of signal handlers" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1855 | if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then |
| 1856 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1857 | else |
| 1858 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1859 | #line 1860 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1860 | #include "confdefs.h" |
| 1861 | #include <sys/types.h> |
| 1862 | #include <signal.h> |
| 1863 | #ifdef signal |
| 1864 | #undef signal |
| 1865 | #endif |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1866 | #ifdef __cplusplus |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1867 | extern "C" void (*signal (int, void (*)(int)))(int); |
| 1868 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1869 | void (*signal ()) (); |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1870 | #endif |
| 1871 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1872 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1873 | int i; |
| 1874 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1875 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1876 | if { (eval echo configure:1877: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1877 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1878 | ac_cv_type_signal=void |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1879 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1880 | echo "configure: failed program was:" >&5 |
| 1881 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1882 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1883 | ac_cv_type_signal=int |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1884 | fi |
| 1885 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1886 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1887 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1888 | echo "$ac_t""$ac_cv_type_signal" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1889 | cat >> confdefs.h <<EOF |
| 1890 | #define RETSIGTYPE $ac_cv_type_signal |
| 1891 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1892 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1893 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1894 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1895 | echo "configure:1896: checking for size_t" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1896 | if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then |
| 1897 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1898 | else |
| 1899 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1900 | #line 1901 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1901 | #include "confdefs.h" |
| 1902 | #include <sys/types.h> |
| 1903 | #if STDC_HEADERS |
| 1904 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1905 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1906 | #endif |
| 1907 | EOF |
| 1908 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1909 | 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] | 1910 | rm -rf conftest* |
| 1911 | ac_cv_type_size_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1912 | else |
| 1913 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1914 | ac_cv_type_size_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1915 | fi |
| 1916 | rm -f conftest* |
| 1917 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1918 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1919 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1920 | if test $ac_cv_type_size_t = no; then |
| 1921 | cat >> confdefs.h <<\EOF |
| 1922 | #define size_t unsigned |
| 1923 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1924 | |
| 1925 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1926 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1927 | echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1928 | echo "configure:1929: checking for uid_t in sys/types.h" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1929 | if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then |
| 1930 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1931 | else |
| 1932 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1933 | #line 1934 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1934 | #include "confdefs.h" |
| 1935 | #include <sys/types.h> |
| 1936 | EOF |
| 1937 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1938 | egrep "uid_t" >/dev/null 2>&1; then |
| 1939 | rm -rf conftest* |
| 1940 | ac_cv_type_uid_t=yes |
| 1941 | else |
| 1942 | rm -rf conftest* |
| 1943 | ac_cv_type_uid_t=no |
| 1944 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1945 | rm -f conftest* |
| 1946 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1947 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1948 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1949 | echo "$ac_t""$ac_cv_type_uid_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1950 | if test $ac_cv_type_uid_t = no; then |
| 1951 | cat >> confdefs.h <<\EOF |
| 1952 | #define uid_t int |
| 1953 | EOF |
| 1954 | |
| 1955 | cat >> confdefs.h <<\EOF |
| 1956 | #define gid_t int |
| 1957 | EOF |
| 1958 | |
| 1959 | fi |
| 1960 | |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 1961 | echo $ac_n "checking for socklen_t""... $ac_c" 1>&6 |
| 1962 | echo "configure:1963: checking for socklen_t" >&5 |
| 1963 | if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then |
| 1964 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1965 | else |
| 1966 | cat > conftest.$ac_ext <<EOF |
| 1967 | #line 1968 "configure" |
| 1968 | #include "confdefs.h" |
| 1969 | #include <sys/types.h> |
| 1970 | #if STDC_HEADERS |
| 1971 | #include <stdlib.h> |
| 1972 | #include <stddef.h> |
| 1973 | #endif |
| 1974 | EOF |
| 1975 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1976 | egrep "(^|[^a-zA-Z_0-9])socklen_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
| 1977 | rm -rf conftest* |
| 1978 | ac_cv_type_socklen_t=yes |
| 1979 | else |
| 1980 | rm -rf conftest* |
| 1981 | ac_cv_type_socklen_t=no |
| 1982 | fi |
| 1983 | rm -f conftest* |
| 1984 | |
| 1985 | fi |
| 1986 | echo "$ac_t""$ac_cv_type_socklen_t" 1>&6 |
| 1987 | if test $ac_cv_type_socklen_t = no; then |
| 1988 | cat >> confdefs.h <<\EOF |
| 1989 | #define socklen_t int |
| 1990 | EOF |
| 1991 | |
| 1992 | fi |
| 1993 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1994 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1995 | # Sizes of various common basic types |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1996 | echo $ac_n "checking size of int""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 1997 | echo "configure:1998: checking size of int" >&5 |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1998 | if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then |
| 1999 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2000 | else |
| 2001 | if test "$cross_compiling" = yes; then |
| 2002 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2003 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2004 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2005 | #line 2006 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2006 | #include "confdefs.h" |
| 2007 | #include <stdio.h> |
| 2008 | main() |
| 2009 | { |
| 2010 | FILE *f=fopen("conftestval", "w"); |
| 2011 | if (!f) exit(1); |
| 2012 | fprintf(f, "%d\n", sizeof(int)); |
| 2013 | exit(0); |
| 2014 | } |
| 2015 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2016 | if { (eval echo configure:2017: \"$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] | 2017 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2018 | ac_cv_sizeof_int=`cat conftestval` |
| 2019 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2020 | echo "configure: failed program was:" >&5 |
| 2021 | cat conftest.$ac_ext >&5 |
| 2022 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2023 | ac_cv_sizeof_int=0 |
| 2024 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2025 | rm -fr conftest* |
| 2026 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2027 | |
| 2028 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2029 | echo "$ac_t""$ac_cv_sizeof_int" 1>&6 |
| 2030 | cat >> confdefs.h <<EOF |
| 2031 | #define SIZEOF_INT $ac_cv_sizeof_int |
| 2032 | EOF |
| 2033 | |
| 2034 | |
| 2035 | echo $ac_n "checking size of long""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2036 | echo "configure:2037: checking size of long" >&5 |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2037 | if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then |
| 2038 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2039 | else |
| 2040 | if test "$cross_compiling" = yes; then |
| 2041 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2042 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2043 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2044 | #line 2045 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2045 | #include "confdefs.h" |
| 2046 | #include <stdio.h> |
| 2047 | main() |
| 2048 | { |
| 2049 | FILE *f=fopen("conftestval", "w"); |
| 2050 | if (!f) exit(1); |
| 2051 | fprintf(f, "%d\n", sizeof(long)); |
| 2052 | exit(0); |
| 2053 | } |
| 2054 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2055 | if { (eval echo configure:2056: \"$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] | 2056 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2057 | ac_cv_sizeof_long=`cat conftestval` |
| 2058 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2059 | echo "configure: failed program was:" >&5 |
| 2060 | cat conftest.$ac_ext >&5 |
| 2061 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2062 | ac_cv_sizeof_long=0 |
| 2063 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2064 | rm -fr conftest* |
| 2065 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2066 | |
| 2067 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2068 | echo "$ac_t""$ac_cv_sizeof_long" 1>&6 |
| 2069 | cat >> confdefs.h <<EOF |
| 2070 | #define SIZEOF_LONG $ac_cv_sizeof_long |
| 2071 | EOF |
| 2072 | |
| 2073 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2074 | echo $ac_n "checking size of void *""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2075 | echo "configure:2076: checking size of void *" >&5 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2076 | if eval "test \"`echo '$''{'ac_cv_sizeof_void_p'+set}'`\" = set"; then |
| 2077 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2078 | else |
| 2079 | if test "$cross_compiling" = yes; then |
| 2080 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2081 | else |
| 2082 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2083 | #line 2084 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2084 | #include "confdefs.h" |
| 2085 | #include <stdio.h> |
| 2086 | main() |
| 2087 | { |
| 2088 | FILE *f=fopen("conftestval", "w"); |
| 2089 | if (!f) exit(1); |
| 2090 | fprintf(f, "%d\n", sizeof(void *)); |
| 2091 | exit(0); |
| 2092 | } |
| 2093 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2094 | if { (eval echo configure:2095: \"$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] | 2095 | then |
| 2096 | ac_cv_sizeof_void_p=`cat conftestval` |
| 2097 | else |
| 2098 | echo "configure: failed program was:" >&5 |
| 2099 | cat conftest.$ac_ext >&5 |
| 2100 | rm -fr conftest* |
| 2101 | ac_cv_sizeof_void_p=0 |
| 2102 | fi |
| 2103 | rm -fr conftest* |
| 2104 | fi |
| 2105 | |
| 2106 | fi |
| 2107 | echo "$ac_t""$ac_cv_sizeof_void_p" 1>&6 |
| 2108 | cat >> confdefs.h <<EOF |
| 2109 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
| 2110 | EOF |
| 2111 | |
| 2112 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2113 | echo $ac_n "checking size of char""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2114 | echo "configure:2115: checking size of char" >&5 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2115 | if eval "test \"`echo '$''{'ac_cv_sizeof_char'+set}'`\" = set"; then |
| 2116 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2117 | else |
| 2118 | if test "$cross_compiling" = yes; then |
| 2119 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2120 | else |
| 2121 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2122 | #line 2123 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2123 | #include "confdefs.h" |
| 2124 | #include <stdio.h> |
| 2125 | main() |
| 2126 | { |
| 2127 | FILE *f=fopen("conftestval", "w"); |
| 2128 | if (!f) exit(1); |
| 2129 | fprintf(f, "%d\n", sizeof(char)); |
| 2130 | exit(0); |
| 2131 | } |
| 2132 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2133 | if { (eval echo configure:2134: \"$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] | 2134 | then |
| 2135 | ac_cv_sizeof_char=`cat conftestval` |
| 2136 | else |
| 2137 | echo "configure: failed program was:" >&5 |
| 2138 | cat conftest.$ac_ext >&5 |
| 2139 | rm -fr conftest* |
| 2140 | ac_cv_sizeof_char=0 |
| 2141 | fi |
| 2142 | rm -fr conftest* |
| 2143 | fi |
| 2144 | |
| 2145 | fi |
| 2146 | echo "$ac_t""$ac_cv_sizeof_char" 1>&6 |
| 2147 | cat >> confdefs.h <<EOF |
| 2148 | #define SIZEOF_CHAR $ac_cv_sizeof_char |
| 2149 | EOF |
| 2150 | |
| 2151 | |
| 2152 | echo $ac_n "checking size of short""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2153 | echo "configure:2154: checking size of short" >&5 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2154 | if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then |
| 2155 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2156 | else |
| 2157 | if test "$cross_compiling" = yes; then |
| 2158 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2159 | else |
| 2160 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2161 | #line 2162 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2162 | #include "confdefs.h" |
| 2163 | #include <stdio.h> |
| 2164 | main() |
| 2165 | { |
| 2166 | FILE *f=fopen("conftestval", "w"); |
| 2167 | if (!f) exit(1); |
| 2168 | fprintf(f, "%d\n", sizeof(short)); |
| 2169 | exit(0); |
| 2170 | } |
| 2171 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2172 | if { (eval echo configure:2173: \"$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] | 2173 | then |
| 2174 | ac_cv_sizeof_short=`cat conftestval` |
| 2175 | else |
| 2176 | echo "configure: failed program was:" >&5 |
| 2177 | cat conftest.$ac_ext >&5 |
| 2178 | rm -fr conftest* |
| 2179 | ac_cv_sizeof_short=0 |
| 2180 | fi |
| 2181 | rm -fr conftest* |
| 2182 | fi |
| 2183 | |
| 2184 | fi |
| 2185 | echo "$ac_t""$ac_cv_sizeof_short" 1>&6 |
| 2186 | cat >> confdefs.h <<EOF |
| 2187 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
| 2188 | EOF |
| 2189 | |
| 2190 | |
| 2191 | echo $ac_n "checking size of float""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2192 | echo "configure:2193: checking size of float" >&5 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2193 | if eval "test \"`echo '$''{'ac_cv_sizeof_float'+set}'`\" = set"; then |
| 2194 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2195 | else |
| 2196 | if test "$cross_compiling" = yes; then |
| 2197 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2198 | else |
| 2199 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2200 | #line 2201 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2201 | #include "confdefs.h" |
| 2202 | #include <stdio.h> |
| 2203 | main() |
| 2204 | { |
| 2205 | FILE *f=fopen("conftestval", "w"); |
| 2206 | if (!f) exit(1); |
| 2207 | fprintf(f, "%d\n", sizeof(float)); |
| 2208 | exit(0); |
| 2209 | } |
| 2210 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2211 | if { (eval echo configure:2212: \"$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] | 2212 | then |
| 2213 | ac_cv_sizeof_float=`cat conftestval` |
| 2214 | else |
| 2215 | echo "configure: failed program was:" >&5 |
| 2216 | cat conftest.$ac_ext >&5 |
| 2217 | rm -fr conftest* |
| 2218 | ac_cv_sizeof_float=0 |
| 2219 | fi |
| 2220 | rm -fr conftest* |
| 2221 | fi |
| 2222 | |
| 2223 | fi |
| 2224 | echo "$ac_t""$ac_cv_sizeof_float" 1>&6 |
| 2225 | cat >> confdefs.h <<EOF |
| 2226 | #define SIZEOF_FLOAT $ac_cv_sizeof_float |
| 2227 | EOF |
| 2228 | |
| 2229 | |
| 2230 | echo $ac_n "checking size of double""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2231 | echo "configure:2232: checking size of double" >&5 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2232 | if eval "test \"`echo '$''{'ac_cv_sizeof_double'+set}'`\" = set"; then |
| 2233 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2234 | else |
| 2235 | if test "$cross_compiling" = yes; then |
| 2236 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2237 | else |
| 2238 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2239 | #line 2240 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2240 | #include "confdefs.h" |
| 2241 | #include <stdio.h> |
| 2242 | main() |
| 2243 | { |
| 2244 | FILE *f=fopen("conftestval", "w"); |
| 2245 | if (!f) exit(1); |
| 2246 | fprintf(f, "%d\n", sizeof(double)); |
| 2247 | exit(0); |
| 2248 | } |
| 2249 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2250 | if { (eval echo configure:2251: \"$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] | 2251 | then |
| 2252 | ac_cv_sizeof_double=`cat conftestval` |
| 2253 | else |
| 2254 | echo "configure: failed program was:" >&5 |
| 2255 | cat conftest.$ac_ext >&5 |
| 2256 | rm -fr conftest* |
| 2257 | ac_cv_sizeof_double=0 |
| 2258 | fi |
| 2259 | rm -fr conftest* |
| 2260 | fi |
| 2261 | |
| 2262 | fi |
| 2263 | echo "$ac_t""$ac_cv_sizeof_double" 1>&6 |
| 2264 | cat >> confdefs.h <<EOF |
| 2265 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
| 2266 | EOF |
| 2267 | |
| 2268 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2269 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2270 | echo $ac_n "checking for long long support""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2271 | echo "configure:2272: checking for long long support" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2272 | have_long_long=no |
| 2273 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2274 | #line 2275 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2275 | #include "confdefs.h" |
| 2276 | |
| 2277 | int main() { |
| 2278 | long long x; x = (long long)0; |
| 2279 | ; return 0; } |
| 2280 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2281 | if { (eval echo configure:2282: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2282 | rm -rf conftest* |
| 2283 | cat >> confdefs.h <<\EOF |
| 2284 | #define HAVE_LONG_LONG 1 |
| 2285 | EOF |
| 2286 | have_long_long=yes |
| 2287 | else |
| 2288 | echo "configure: failed program was:" >&5 |
| 2289 | cat conftest.$ac_ext >&5 |
| 2290 | fi |
| 2291 | rm -f conftest* |
| 2292 | echo "$ac_t""$have_long_long" 1>&6 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2293 | if test "$have_long_long" = yes ; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2294 | echo $ac_n "checking size of long long""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2295 | echo "configure:2296: checking size of long long" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2296 | if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then |
| 2297 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2298 | else |
| 2299 | if test "$cross_compiling" = yes; then |
| 2300 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2301 | else |
| 2302 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2303 | #line 2304 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2304 | #include "confdefs.h" |
| 2305 | #include <stdio.h> |
| 2306 | main() |
| 2307 | { |
| 2308 | FILE *f=fopen("conftestval", "w"); |
| 2309 | if (!f) exit(1); |
| 2310 | fprintf(f, "%d\n", sizeof(long long)); |
| 2311 | exit(0); |
| 2312 | } |
| 2313 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2314 | if { (eval echo configure:2315: \"$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] | 2315 | then |
| 2316 | ac_cv_sizeof_long_long=`cat conftestval` |
| 2317 | else |
| 2318 | echo "configure: failed program was:" >&5 |
| 2319 | cat conftest.$ac_ext >&5 |
| 2320 | rm -fr conftest* |
| 2321 | ac_cv_sizeof_long_long=0 |
| 2322 | fi |
| 2323 | rm -fr conftest* |
| 2324 | fi |
| 2325 | |
| 2326 | fi |
| 2327 | echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6 |
| 2328 | cat >> confdefs.h <<EOF |
| 2329 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
| 2330 | EOF |
| 2331 | |
| 2332 | |
| 2333 | fi |
| 2334 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2335 | # Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>. |
| 2336 | echo $ac_n "checking size of off_t""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2337 | echo "configure:2338: checking size of off_t" >&5 |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2338 | if eval "test \"`echo '$''{'ac_cv_sizeof_off_t'+set}'`\" = set"; then |
| 2339 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2340 | else |
| 2341 | if test "$cross_compiling" = yes; then |
| 2342 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2343 | else |
| 2344 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2345 | #line 2346 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2346 | #include "confdefs.h" |
| 2347 | #include <stdio.h> |
| 2348 | #include <sys/types.h> |
| 2349 | main() |
| 2350 | { |
| 2351 | FILE *f=fopen("conftestval", "w"); |
| 2352 | if (!f) exit(1); |
| 2353 | fprintf(f, "%d\n", sizeof(off_t)); |
| 2354 | exit(0); |
| 2355 | } |
| 2356 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2357 | if { (eval echo configure:2358: \"$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] | 2358 | then |
| 2359 | ac_cv_sizeof_off_t=`cat conftestval` |
| 2360 | else |
| 2361 | echo "configure: failed program was:" >&5 |
| 2362 | cat conftest.$ac_ext >&5 |
| 2363 | rm -fr conftest* |
| 2364 | ac_cv_sizeof_off_t=0 |
| 2365 | fi |
| 2366 | rm -fr conftest* |
| 2367 | fi |
| 2368 | |
| 2369 | |
| 2370 | fi |
| 2371 | |
| 2372 | echo "$ac_t""$ac_cv_sizeof_off_t" 1>&6 |
| 2373 | cat >> confdefs.h <<EOF |
| 2374 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
| 2375 | EOF |
| 2376 | |
| 2377 | |
| 2378 | echo $ac_n "checking whether to enable large file support""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2379 | echo "configure:2380: checking whether to enable large file support" >&5 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2380 | if test "$have_long_long" = yes -a \ |
| 2381 | "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \ |
| 2382 | "$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] | 2383 | cat >> confdefs.h <<\EOF |
| 2384 | #define HAVE_LARGEFILE_SUPPORT 1 |
| 2385 | EOF |
| 2386 | |
| 2387 | echo "$ac_t""yes" 1>&6 |
| 2388 | else |
| 2389 | echo "$ac_t""no" 1>&6 |
| 2390 | fi |
| 2391 | |
| 2392 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2393 | # Minor variations in building a framework between NextStep versions 4 and 5 |
| 2394 | |
| 2395 | case $ac_sys_system/$ac_sys_release in |
| 2396 | next/4*) |
| 2397 | ns_undef_sym='__environ' |
| 2398 | LIBTOOL_CRUFT="-U $ns_undef_sym" ;; |
| 2399 | next/5*) |
| 2400 | ns_undef_sym='_environ' |
| 2401 | LIBTOOL_CRUFT="-lcc_dynamic -U $ns_undef_sym" ;; |
| 2402 | esac |
| 2403 | |
| 2404 | echo $ac_n "checking for --with-next-framework""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2405 | echo "configure:2406: checking for --with-next-framework" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2406 | if test "$with_next_framework" |
| 2407 | then |
| 2408 | OPT="$OPT -fno-common" |
| 2409 | # -U __environ is needed since bundles don't have access |
| 2410 | # to crt0 when built but will always be linked against it |
| 2411 | LDFLAGS="$LDFLAGS -Wl,-U,$ns_undef_sym" |
| 2412 | cat >> confdefs.h <<\EOF |
| 2413 | #define WITH_NEXT_FRAMEWORK 1 |
| 2414 | EOF |
| 2415 | |
| 2416 | echo "$ac_t""yes" 1>&6 |
| 2417 | else |
| 2418 | echo "$ac_t""no" 1>&6 |
| 2419 | fi |
| 2420 | |
| 2421 | echo $ac_n "checking for --with-dyld""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2422 | echo "configure:2423: checking for --with-dyld" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2423 | if test "$with_next_framework" -o "$with_dyld" |
| 2424 | then |
| 2425 | if test "$with_dyld" |
| 2426 | then |
| 2427 | echo "$ac_t""yes" 1>&6 |
| 2428 | else |
| 2429 | echo "$ac_t""required for framework build" 1>&6 |
| 2430 | fi |
| 2431 | cat >> confdefs.h <<\EOF |
| 2432 | #define WITH_DYLD 1 |
| 2433 | EOF |
| 2434 | |
| 2435 | ns_dyld='set' |
| 2436 | else |
| 2437 | echo "$ac_t""no" 1>&6 |
| 2438 | fi |
| 2439 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2440 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2441 | |
| 2442 | |
| 2443 | |
| 2444 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2445 | # SO is the extension of shared libraries `(including the dot!) |
| 2446 | # -- usually .so, .sl on HP-UX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2447 | echo $ac_n "checking SO""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2448 | echo "configure:2449: checking SO" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2449 | if test -z "$SO" |
| 2450 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2451 | case $ac_sys_system in |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2452 | hp*|HP*) SO=.sl;; |
| 2453 | *) SO=.so;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2454 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2455 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2456 | echo "$ac_t""$SO" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2457 | # LDSHARED is the ld *command* used to create shared library |
| 2458 | # -- "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] | 2459 | # (Shared libraries in this instance are shared modules to be loaded into |
| 2460 | # Python, as opposed to building Python itself as a shared library.) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2461 | echo $ac_n "checking LDSHARED""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2462 | echo "configure:2463: checking LDSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2463 | if test -z "$LDSHARED" |
| 2464 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2465 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 45140f9 | 1997-08-29 18:44:06 +0000 | [diff] [blame] | 2466 | AIX*) LDSHARED="\$(srcdir)/ld_so_aix \$(CC)";; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2467 | BeOS*) LDSHARED="\$(srcdir)/../BeOS/linkmodule -L.. -lpython\$(VERSION)";; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2468 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 2469 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2470 | SunOS/4*) LDSHARED="ld";; |
| 2471 | SunOS/5*) LDSHARED="ld -G";; |
| 2472 | hp*|HP*) LDSHARED="ld -b";; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2473 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
| 2474 | DYNIX/ptx*) LDSHARED="ld -G";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2475 | next/*) |
| 2476 | if test "$ns_dyld" |
| 2477 | then LDSHARED='$(CC) $(LDFLAGS) -bundle -prebind' |
| 2478 | else LDSHARED='$(CC) $(CFLAGS) -nostdlib -r'; |
| 2479 | fi |
| 2480 | if test "$with_next_framework" ; then |
| 2481 | LDSHARED="$LDSHARED \$(LDLIBRARY)" |
| 2482 | fi ;; |
Guido van Rossum | 81652ab | 1996-07-21 02:53:27 +0000 | [diff] [blame] | 2483 | Linux*) LDSHARED="gcc -shared";; |
Guido van Rossum | 3c4bb80 | 1997-12-18 23:55:32 +0000 | [diff] [blame] | 2484 | dgux*) LDSHARED="ld -G";; |
Guido van Rossum | 458e7fa | 1999-09-17 15:40:40 +0000 | [diff] [blame] | 2485 | BSD/OS*/4*) LDSHARED="gcc -shared";; |
Guido van Rossum | a8acf72 | 1999-04-27 22:06:08 +0000 | [diff] [blame] | 2486 | FreeBSD*/[34]*) LDSHARED="gcc -shared";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2487 | FreeBSD*|OpenBSD*) LDSHARED="ld -Bshareable";; |
| 2488 | NetBSD*) |
| 2489 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 2490 | then |
| 2491 | LDSHARED="cc -shared" |
| 2492 | else |
| 2493 | LDSHARED="ld -Bshareable" |
| 2494 | fi;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2495 | SCO_SV*) LDSHARED="cc -G -KPIC -Ki486 -belf -Wl,-Bexport";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2496 | *) LDSHARED="ld";; |
| 2497 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2498 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2499 | echo "$ac_t""$LDSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2500 | # 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] | 2501 | # library (module) -- this is only needed for a few systems |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2502 | echo $ac_n "checking CCSHARED""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2503 | echo "configure:2504: checking CCSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2504 | if test -z "$CCSHARED" |
| 2505 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2506 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 2507 | hp*|HP*) if test "$GCC" = yes; |
| 2508 | then CCSHARED="-fpic"; |
| 2509 | else CCSHARED="+z"; |
| 2510 | fi;; |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2511 | Linux*) CCSHARED="-fpic";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2512 | BSD/OS*/4*) CCSHARED="-fpic";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2513 | FreeBSD*|OpenBSD*) CCSHARED="-fpic";; |
| 2514 | NetBSD*) CCSHARED="-fPIC";; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2515 | SCO_SV*) CCSHARED="-KPIC -dy -Bdynamic";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2516 | IRIX*/6*) case $CC in |
| 2517 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 2518 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2519 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2520 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2521 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2522 | echo "$ac_t""$CCSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2523 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2524 | # the python executable -- this is only needed for a few systems |
| 2525 | echo $ac_n "checking LINKFORSHARED""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2526 | echo "configure:2527: checking LINKFORSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2527 | if test -z "$LINKFORSHARED" |
| 2528 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2529 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 69f6580 | 1998-03-03 21:47:00 +0000 | [diff] [blame] | 2530 | AIX*) LINKFORSHARED='-Wl,-bE:python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2531 | hp*|HP*) |
Guido van Rossum | 304dd2d | 1997-10-20 23:10:56 +0000 | [diff] [blame] | 2532 | LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2533 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | a8acf72 | 1999-04-27 22:06:08 +0000 | [diff] [blame] | 2534 | FreeBSD/[34]*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 2d9feed | 1997-11-24 17:36:21 +0000 | [diff] [blame] | 2535 | Linux*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2536 | # -u libsys_s pulls in all symbols in libsys |
| 2537 | next/2*|next/3*) LINKFORSHARED="-u libsys_s";; |
| 2538 | # -u __dummy makes the linker aware of the objc runtime |
| 2539 | # in System.framework; otherwise, __objcInit (referenced in |
| 2540 | # crt1.o) gets erroneously defined as common, which breaks dynamic |
| 2541 | # loading of any modules which reference it in System.framework |
| 2542 | next/4*|next/5*) LINKFORSHARED="-u __dummy -framework System" ;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2543 | SCO_SV*) LINKFORSHARED="-Bdynamic -dy -Wl,-Bexport";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2544 | NetBSD*) |
| 2545 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 2546 | then |
| 2547 | LINKFORSHARED="-Wl,--export-dynamic" |
| 2548 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2549 | SunOS/5*) case $CC in |
| 2550 | *gcc*) |
Guido van Rossum | ff48418 | 2000-02-03 13:50:24 +0000 | [diff] [blame] | 2551 | if $CC -Xlinker -V 2>&1 | grep BFD >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 2552 | then |
| 2553 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2554 | fi;; |
| 2555 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2556 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2557 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2558 | echo "$ac_t""$LINKFORSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2559 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2560 | # checks for libraries |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2561 | echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2562 | echo "configure:2563: checking for dlopen in -ldl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2563 | ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2564 | 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] | 2565 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2566 | else |
| 2567 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2568 | LIBS="-ldl $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2569 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2570 | #line 2571 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2571 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2572 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2573 | /* We use char because int might match the return type of a gcc2 |
| 2574 | builtin and then its argument prototype would still apply. */ |
| 2575 | char dlopen(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2576 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2577 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2578 | dlopen() |
| 2579 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2580 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2581 | if { (eval echo configure:2582: \"$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] | 2582 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2583 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2584 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2585 | echo "configure: failed program was:" >&5 |
| 2586 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2587 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2588 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2589 | fi |
| 2590 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2591 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2592 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2593 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2594 | 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] | 2595 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2596 | ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 2597 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2598 | cat >> confdefs.h <<EOF |
| 2599 | #define $ac_tr_lib 1 |
| 2600 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2601 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2602 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2603 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2604 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2605 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2606 | fi |
| 2607 | # Dynamic linking for SunOS/Solaris and SYSV |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2608 | echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2609 | echo "configure:2610: checking for shl_load in -ldld" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2610 | ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2611 | 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] | 2612 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2613 | else |
| 2614 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2615 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2616 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2617 | #line 2618 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2618 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2619 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2620 | /* We use char because int might match the return type of a gcc2 |
| 2621 | builtin and then its argument prototype would still apply. */ |
| 2622 | char shl_load(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2623 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2624 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2625 | shl_load() |
| 2626 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2627 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2628 | if { (eval echo configure:2629: \"$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] | 2629 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2630 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2631 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2632 | echo "configure: failed program was:" >&5 |
| 2633 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2634 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2635 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2636 | fi |
| 2637 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2638 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2639 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2640 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2641 | 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] | 2642 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2643 | ac_tr_lib=HAVE_LIB`echo dld | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 2644 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2645 | cat >> confdefs.h <<EOF |
| 2646 | #define $ac_tr_lib 1 |
| 2647 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2648 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2649 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2650 | |
| 2651 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2652 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2653 | fi |
| 2654 | # Dynamic linking for HP-UX |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 2655 | |
| 2656 | # checks for system dependent C++ extensions support |
| 2657 | case "$ac_sys_system" in |
| 2658 | AIX*) echo $ac_n "checking for genuine AIX C++ extensions support""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2659 | echo "configure:2660: checking for genuine AIX C++ extensions support" >&5 |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 2660 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2661 | #line 2662 "configure" |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 2662 | #include "confdefs.h" |
| 2663 | #include "/usr/lpp/xlC/include/load.h" |
| 2664 | int main() { |
| 2665 | loadAndInit("", 0, "") |
| 2666 | ; return 0; } |
| 2667 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2668 | if { (eval echo configure:2669: \"$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] | 2669 | rm -rf conftest* |
| 2670 | cat >> confdefs.h <<\EOF |
| 2671 | #define AIX_GENUINE_CPLUSPLUS 1 |
| 2672 | EOF |
| 2673 | |
| 2674 | echo "$ac_t""yes" 1>&6 |
| 2675 | else |
| 2676 | echo "configure: failed program was:" >&5 |
| 2677 | cat conftest.$ac_ext >&5 |
| 2678 | rm -rf conftest* |
| 2679 | echo "$ac_t""no" 1>&6 |
| 2680 | fi |
| 2681 | rm -f conftest*;; |
| 2682 | *) ;; |
| 2683 | esac |
| 2684 | |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 2685 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
| 2686 | # However on SGI IRIX, these exist but are broken. |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2687 | # BeOS' sockets are stashed in libnet. |
| 2688 | case "$ac_sys_system" in |
| 2689 | IRIX*) ;; |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 2690 | *) |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2691 | echo $ac_n "checking for t_open in -lnsl""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2692 | echo "configure:2693: checking for t_open in -lnsl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2693 | ac_lib_var=`echo nsl'_'t_open | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2694 | 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] | 2695 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2696 | else |
| 2697 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2698 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2699 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2700 | #line 2701 "configure" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2701 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2702 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2703 | /* We use char because int might match the return type of a gcc2 |
| 2704 | builtin and then its argument prototype would still apply. */ |
| 2705 | char t_open(); |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2706 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2707 | int main() { |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 2708 | t_open() |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2709 | ; return 0; } |
| 2710 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2711 | if { (eval echo configure:2712: \"$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] | 2712 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2713 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2714 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2715 | echo "configure: failed program was:" >&5 |
| 2716 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2717 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2718 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2719 | fi |
| 2720 | rm -f conftest* |
| 2721 | LIBS="$ac_save_LIBS" |
| 2722 | |
| 2723 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2724 | 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] | 2725 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2726 | LIBS="-lnsl $LIBS" |
| 2727 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2728 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2729 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 2730 | # SVR4 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2731 | echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2732 | echo "configure:2733: checking for socket in -lsocket" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2733 | ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2734 | 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] | 2735 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2736 | else |
| 2737 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2738 | LIBS="-lsocket $LIBS $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2739 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2740 | #line 2741 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2741 | #include "confdefs.h" |
| 2742 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2743 | /* We use char because int might match the return type of a gcc2 |
| 2744 | builtin and then its argument prototype would still apply. */ |
| 2745 | char socket(); |
| 2746 | |
| 2747 | int main() { |
| 2748 | socket() |
| 2749 | ; return 0; } |
| 2750 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2751 | if { (eval echo configure:2752: \"$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] | 2752 | rm -rf conftest* |
| 2753 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2754 | else |
| 2755 | echo "configure: failed program was:" >&5 |
| 2756 | cat conftest.$ac_ext >&5 |
| 2757 | rm -rf conftest* |
| 2758 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2759 | fi |
| 2760 | rm -f conftest* |
| 2761 | LIBS="$ac_save_LIBS" |
| 2762 | |
| 2763 | fi |
| 2764 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2765 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2766 | LIBS="-lsocket $LIBS" |
| 2767 | else |
| 2768 | echo "$ac_t""no" 1>&6 |
| 2769 | fi |
| 2770 | # SVR4 sockets |
| 2771 | echo $ac_n "checking for socket in -lnet""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2772 | echo "configure:2773: checking for socket in -lnet" >&5 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2773 | ac_lib_var=`echo net'_'socket | sed 'y%./+-%__p_%'` |
| 2774 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 2775 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2776 | else |
| 2777 | ac_save_LIBS="$LIBS" |
| 2778 | LIBS="-lnet $LIBS $LIBS" |
| 2779 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2780 | #line 2781 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2781 | #include "confdefs.h" |
| 2782 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2783 | /* We use char because int might match the return type of a gcc2 |
| 2784 | builtin and then its argument prototype would still apply. */ |
| 2785 | char socket(); |
| 2786 | |
| 2787 | int main() { |
| 2788 | socket() |
| 2789 | ; return 0; } |
| 2790 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2791 | if { (eval echo configure:2792: \"$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] | 2792 | rm -rf conftest* |
| 2793 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2794 | else |
| 2795 | echo "configure: failed program was:" >&5 |
| 2796 | cat conftest.$ac_ext >&5 |
| 2797 | rm -rf conftest* |
| 2798 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2799 | fi |
| 2800 | rm -f conftest* |
| 2801 | LIBS="$ac_save_LIBS" |
| 2802 | |
| 2803 | fi |
| 2804 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2805 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2806 | LIBS="-lnet $LIBS" |
| 2807 | else |
| 2808 | echo "$ac_t""no" 1>&6 |
| 2809 | fi |
| 2810 | # BeOS |
| 2811 | ;; |
| 2812 | esac |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 2813 | |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 2814 | echo $ac_n "checking for --with-libs""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2815 | echo "configure:2816: checking for --with-libs" >&5 |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 2816 | # Check whether --with-libs or --without-libs was given. |
| 2817 | if test "${with_libs+set}" = set; then |
| 2818 | withval="$with_libs" |
| 2819 | |
| 2820 | echo "$ac_t""$withval" 1>&6 |
| 2821 | LIBS="$withval $LIBS" |
| 2822 | |
| 2823 | else |
| 2824 | echo "$ac_t""no" 1>&6 |
| 2825 | fi |
| 2826 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2827 | |
Guido van Rossum | 3c83bb4 | 1996-12-31 22:35:16 +0000 | [diff] [blame] | 2828 | echo $ac_n "checking for --with(out)-readline""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2829 | echo "configure:2830: checking for --with(out)-readline" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2830 | # Check whether --with-readline or --without-readline was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2831 | if test "${with_readline+set}" = set; then |
| 2832 | withval="$with_readline" |
Guido van Rossum | b06df27 | 1997-08-05 21:50:20 +0000 | [diff] [blame] | 2833 | echo "$ac_t""$withval" 1>&6 |
| 2834 | { echo "configure: error: --with(out)-readline is obsolete" 1>&2; exit 1; } |
Guido van Rossum | 3c83bb4 | 1996-12-31 22:35:16 +0000 | [diff] [blame] | 2835 | else |
Guido van Rossum | b06df27 | 1997-08-05 21:50:20 +0000 | [diff] [blame] | 2836 | echo "$ac_t""not specified." 1>&6 |
Guido van Rossum | 3c83bb4 | 1996-12-31 22:35:16 +0000 | [diff] [blame] | 2837 | fi |
| 2838 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2839 | |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 2840 | |
| 2841 | USE_THREAD_MODULE="#" |
| 2842 | |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2843 | echo $ac_n "checking for --with-dec-threads""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2844 | echo "configure:2845: checking for --with-dec-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2845 | |
| 2846 | # Check whether --with-dec-threads or --without-dec-threads was given. |
| 2847 | if test "${with_dec_threads+set}" = set; then |
| 2848 | withval="$with_dec_threads" |
| 2849 | echo "$ac_t""$withval" 1>&6 |
| 2850 | LDLAST=-threads |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2851 | if test "${with_thread+set}" != set; then |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2852 | with_thread="$withval"; |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2853 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2854 | else |
| 2855 | echo "$ac_t""no" 1>&6 |
| 2856 | fi |
| 2857 | |
| 2858 | |
| 2859 | echo $ac_n "checking for --with-threads""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2860 | echo "configure:2861: checking for --with-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2861 | # Check whether --with-threads or --without-threads was given. |
| 2862 | if test "${with_threads+set}" = set; then |
| 2863 | withval="$with_threads" |
| 2864 | echo "$ac_t""$withval" 1>&6 |
| 2865 | if test "${with_thread+set}" != set; then |
| 2866 | with_thread="$withval"; |
| 2867 | fi |
| 2868 | else |
| 2869 | echo "$ac_t""no" 1>&6 |
| 2870 | fi |
| 2871 | |
| 2872 | |
| 2873 | echo $ac_n "checking for --with-thread""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2874 | echo "configure:2875: checking for --with-thread" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2875 | # Check whether --with-thread or --without-thread was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2876 | if test "${with_thread+set}" = set; then |
| 2877 | withval="$with_thread" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2878 | |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 2879 | USE_THREAD_MODULE= |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2880 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2881 | if test -d "$withval" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2882 | then LDFLAGS="$LDFLAGS -L$withval" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2883 | fi |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 2884 | cat >> confdefs.h <<\EOF |
| 2885 | #define _REENTRANT 1 |
| 2886 | EOF |
| 2887 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2888 | ac_safe=`echo "mach/cthreads.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2889 | echo $ac_n "checking for mach/cthreads.h""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2890 | echo "configure:2891: checking for mach/cthreads.h" >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2891 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 2892 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2893 | else |
| 2894 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2895 | #line 2896 "configure" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2896 | #include "confdefs.h" |
| 2897 | #include <mach/cthreads.h> |
| 2898 | EOF |
| 2899 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2900 | { (eval echo configure:2901: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2901 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2902 | if test -z "$ac_err"; then |
| 2903 | rm -rf conftest* |
| 2904 | eval "ac_cv_header_$ac_safe=yes" |
| 2905 | else |
| 2906 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2907 | echo "configure: failed program was:" >&5 |
| 2908 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2909 | rm -rf conftest* |
| 2910 | eval "ac_cv_header_$ac_safe=no" |
| 2911 | fi |
| 2912 | rm -f conftest* |
| 2913 | fi |
| 2914 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 2915 | echo "$ac_t""yes" 1>&6 |
| 2916 | cat >> confdefs.h <<\EOF |
| 2917 | #define WITH_THREAD 1 |
| 2918 | EOF |
| 2919 | |
| 2920 | cat >> confdefs.h <<\EOF |
| 2921 | #define C_THREADS 1 |
| 2922 | EOF |
| 2923 | |
| 2924 | LIBOBJS="$LIBOBJS thread.o" |
| 2925 | else |
| 2926 | echo "$ac_t""no" 1>&6 |
| 2927 | |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 2928 | echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2929 | echo "configure:2930: checking for pthread_create in -lpthread" >&5 |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 2930 | ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'` |
| 2931 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 2932 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2933 | else |
| 2934 | ac_save_LIBS="$LIBS" |
| 2935 | LIBS="-lpthread $LIBS" |
| 2936 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2937 | #line 2938 "configure" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 2938 | #include "confdefs.h" |
| 2939 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2940 | /* We use char because int might match the return type of a gcc2 |
| 2941 | builtin and then its argument prototype would still apply. */ |
| 2942 | char pthread_create(); |
| 2943 | |
| 2944 | int main() { |
| 2945 | pthread_create() |
| 2946 | ; return 0; } |
| 2947 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2948 | if { (eval echo configure:2949: \"$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] | 2949 | rm -rf conftest* |
| 2950 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2951 | else |
| 2952 | echo "configure: failed program was:" >&5 |
| 2953 | cat conftest.$ac_ext >&5 |
| 2954 | rm -rf conftest* |
| 2955 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2956 | fi |
| 2957 | rm -f conftest* |
| 2958 | LIBS="$ac_save_LIBS" |
| 2959 | |
| 2960 | fi |
| 2961 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2962 | echo "$ac_t""yes" 1>&6 |
| 2963 | cat >> confdefs.h <<\EOF |
| 2964 | #define WITH_THREAD 1 |
| 2965 | EOF |
| 2966 | |
| 2967 | cat >> confdefs.h <<\EOF |
| 2968 | #define _POSIX_THREADS 1 |
| 2969 | EOF |
| 2970 | |
| 2971 | LIBS="-lpthread $LIBS" |
| 2972 | LIBOBJS="$LIBOBJS thread.o" |
| 2973 | else |
| 2974 | echo "$ac_t""no" 1>&6 |
| 2975 | |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2976 | echo $ac_n "checking for pthread_detach""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2977 | echo "configure:2978: checking for pthread_detach" >&5 |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2978 | 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] | 2979 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2980 | else |
| 2981 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 2982 | #line 2983 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2983 | #include "confdefs.h" |
| 2984 | /* System header to define __stub macros and hopefully few prototypes, |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2985 | which can conflict with char pthread_detach(); below. */ |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2986 | #include <assert.h> |
| 2987 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2988 | /* We use char because int might match the return type of a gcc2 |
| 2989 | builtin and then its argument prototype would still apply. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2990 | char pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2991 | |
| 2992 | int main() { |
| 2993 | |
| 2994 | /* The GNU C library defines this for functions which it implements |
| 2995 | to always fail with ENOSYS. Some functions are actually named |
| 2996 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2997 | #if defined (__stub_pthread_detach) || defined (__stub___pthread_detach) |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2998 | choke me |
| 2999 | #else |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3000 | pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3001 | #endif |
| 3002 | |
| 3003 | ; return 0; } |
| 3004 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3005 | if { (eval echo configure:3006: \"$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] | 3006 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3007 | eval "ac_cv_func_pthread_detach=yes" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3008 | else |
| 3009 | echo "configure: failed program was:" >&5 |
| 3010 | cat conftest.$ac_ext >&5 |
| 3011 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3012 | eval "ac_cv_func_pthread_detach=no" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3013 | fi |
| 3014 | rm -f conftest* |
| 3015 | fi |
| 3016 | |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3017 | if eval "test \"`echo '$ac_cv_func_'pthread_detach`\" = yes"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3018 | echo "$ac_t""yes" 1>&6 |
| 3019 | cat >> confdefs.h <<\EOF |
| 3020 | #define WITH_THREAD 1 |
| 3021 | EOF |
| 3022 | |
| 3023 | cat >> confdefs.h <<\EOF |
| 3024 | #define _POSIX_THREADS 1 |
| 3025 | EOF |
| 3026 | |
| 3027 | LIBOBJS="$LIBOBJS thread.o" |
| 3028 | else |
| 3029 | echo "$ac_t""no" 1>&6 |
| 3030 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3031 | ac_safe=`echo "kernel/OS.h" | sed 'y%./+-%__p_%'` |
| 3032 | echo $ac_n "checking for kernel/OS.h""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3033 | echo "configure:3034: checking for kernel/OS.h" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3034 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 3035 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3036 | else |
| 3037 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3038 | #line 3039 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3039 | #include "confdefs.h" |
| 3040 | #include <kernel/OS.h> |
| 3041 | EOF |
| 3042 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3043 | { (eval echo configure:3044: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3044 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3045 | if test -z "$ac_err"; then |
| 3046 | rm -rf conftest* |
| 3047 | eval "ac_cv_header_$ac_safe=yes" |
| 3048 | else |
| 3049 | echo "$ac_err" >&5 |
| 3050 | echo "configure: failed program was:" >&5 |
| 3051 | cat conftest.$ac_ext >&5 |
| 3052 | rm -rf conftest* |
| 3053 | eval "ac_cv_header_$ac_safe=no" |
| 3054 | fi |
| 3055 | rm -f conftest* |
| 3056 | fi |
| 3057 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 3058 | echo "$ac_t""yes" 1>&6 |
| 3059 | cat >> confdefs.h <<\EOF |
| 3060 | #define WITH_THREAD 1 |
| 3061 | EOF |
| 3062 | |
| 3063 | cat >> confdefs.h <<\EOF |
| 3064 | #define BEOS_THREADS 1 |
| 3065 | EOF |
| 3066 | |
| 3067 | LIBOBJS="$LIBOBJS thread.o" |
| 3068 | else |
| 3069 | echo "$ac_t""no" 1>&6 |
| 3070 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3071 | echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3072 | echo "configure:3073: checking for pthread_create in -lpthreads" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3073 | ac_lib_var=`echo pthreads'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3074 | 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] | 3075 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3076 | else |
| 3077 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3078 | LIBS="-lpthreads $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3079 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3080 | #line 3081 "configure" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3081 | #include "confdefs.h" |
| 3082 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3083 | /* We use char because int might match the return type of a gcc2 |
| 3084 | builtin and then its argument prototype would still apply. */ |
| 3085 | char pthread_create(); |
| 3086 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3087 | int main() { |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3088 | pthread_create() |
| 3089 | ; return 0; } |
| 3090 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3091 | if { (eval echo configure:3092: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3092 | rm -rf conftest* |
| 3093 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3094 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3095 | echo "configure: failed program was:" >&5 |
| 3096 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3097 | rm -rf conftest* |
| 3098 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3099 | fi |
| 3100 | rm -f conftest* |
| 3101 | LIBS="$ac_save_LIBS" |
| 3102 | |
| 3103 | fi |
| 3104 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3105 | echo "$ac_t""yes" 1>&6 |
| 3106 | cat >> confdefs.h <<\EOF |
| 3107 | #define WITH_THREAD 1 |
| 3108 | EOF |
| 3109 | |
| 3110 | cat >> confdefs.h <<\EOF |
| 3111 | #define _POSIX_THREADS 1 |
| 3112 | EOF |
| 3113 | |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3114 | LIBS="$LIBS -lpthreads" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3115 | LIBOBJS="$LIBOBJS thread.o" |
| 3116 | else |
| 3117 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3118 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3119 | echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3120 | echo "configure:3121: checking for pthread_create in -lc_r" >&5 |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3121 | ac_lib_var=`echo c_r'_'pthread_create | sed 'y%./+-%__p_%'` |
| 3122 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3123 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3124 | else |
| 3125 | ac_save_LIBS="$LIBS" |
| 3126 | LIBS="-lc_r $LIBS" |
| 3127 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3128 | #line 3129 "configure" |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3129 | #include "confdefs.h" |
| 3130 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3131 | /* We use char because int might match the return type of a gcc2 |
| 3132 | builtin and then its argument prototype would still apply. */ |
| 3133 | char pthread_create(); |
| 3134 | |
| 3135 | int main() { |
| 3136 | pthread_create() |
| 3137 | ; return 0; } |
| 3138 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3139 | if { (eval echo configure:3140: \"$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] | 3140 | rm -rf conftest* |
| 3141 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3142 | else |
| 3143 | echo "configure: failed program was:" >&5 |
| 3144 | cat conftest.$ac_ext >&5 |
| 3145 | rm -rf conftest* |
| 3146 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3147 | fi |
| 3148 | rm -f conftest* |
| 3149 | LIBS="$ac_save_LIBS" |
| 3150 | |
| 3151 | fi |
| 3152 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3153 | echo "$ac_t""yes" 1>&6 |
| 3154 | cat >> confdefs.h <<\EOF |
| 3155 | #define WITH_THREAD 1 |
| 3156 | EOF |
| 3157 | |
| 3158 | cat >> confdefs.h <<\EOF |
| 3159 | #define _POSIX_THREADS 1 |
| 3160 | EOF |
| 3161 | |
| 3162 | LIBS="$LIBS -lc_r" |
| 3163 | LIBOBJS="$LIBOBJS thread.o" |
| 3164 | else |
| 3165 | echo "$ac_t""no" 1>&6 |
| 3166 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3167 | echo $ac_n "checking for __d6_pthread_create in -lthread""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3168 | echo "configure:3169: checking for __d6_pthread_create in -lthread" >&5 |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3169 | ac_lib_var=`echo thread'_'__d6_pthread_create | sed 'y%./+-%__p_%'` |
| 3170 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3171 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3172 | else |
| 3173 | ac_save_LIBS="$LIBS" |
| 3174 | LIBS="-lthread $LIBS" |
| 3175 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3176 | #line 3177 "configure" |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3177 | #include "confdefs.h" |
| 3178 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3179 | /* We use char because int might match the return type of a gcc2 |
| 3180 | builtin and then its argument prototype would still apply. */ |
| 3181 | char __d6_pthread_create(); |
| 3182 | |
| 3183 | int main() { |
| 3184 | __d6_pthread_create() |
| 3185 | ; return 0; } |
| 3186 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3187 | if { (eval echo configure:3188: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3188 | rm -rf conftest* |
| 3189 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3190 | else |
| 3191 | echo "configure: failed program was:" >&5 |
| 3192 | cat conftest.$ac_ext >&5 |
| 3193 | rm -rf conftest* |
| 3194 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3195 | fi |
| 3196 | rm -f conftest* |
| 3197 | LIBS="$ac_save_LIBS" |
| 3198 | |
| 3199 | fi |
| 3200 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3201 | echo "$ac_t""yes" 1>&6 |
| 3202 | cat >> confdefs.h <<\EOF |
| 3203 | #define WITH_THREAD 1 |
| 3204 | EOF |
| 3205 | |
| 3206 | cat >> confdefs.h <<\EOF |
| 3207 | #define _POSIX_THREADS 1 |
| 3208 | EOF |
| 3209 | |
| 3210 | LIBS="$LIBS -lthread" |
| 3211 | LIBOBJS="$LIBOBJS thread.o" |
| 3212 | else |
| 3213 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3214 | |
| 3215 | echo $ac_n "checking for pthread_create in -lcma""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3216 | echo "configure:3217: checking for pthread_create in -lcma" >&5 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3217 | ac_lib_var=`echo cma'_'pthread_create | sed 'y%./+-%__p_%'` |
| 3218 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3219 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3220 | else |
| 3221 | ac_save_LIBS="$LIBS" |
| 3222 | LIBS="-lcma $LIBS" |
| 3223 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3224 | #line 3225 "configure" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3225 | #include "confdefs.h" |
| 3226 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3227 | /* We use char because int might match the return type of a gcc2 |
| 3228 | builtin and then its argument prototype would still apply. */ |
| 3229 | char pthread_create(); |
| 3230 | |
| 3231 | int main() { |
| 3232 | pthread_create() |
| 3233 | ; return 0; } |
| 3234 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3235 | if { (eval echo configure:3236: \"$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] | 3236 | rm -rf conftest* |
| 3237 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3238 | else |
| 3239 | echo "configure: failed program was:" >&5 |
| 3240 | cat conftest.$ac_ext >&5 |
| 3241 | rm -rf conftest* |
| 3242 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3243 | fi |
| 3244 | rm -f conftest* |
| 3245 | LIBS="$ac_save_LIBS" |
| 3246 | |
| 3247 | fi |
| 3248 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3249 | echo "$ac_t""yes" 1>&6 |
| 3250 | cat >> confdefs.h <<\EOF |
| 3251 | #define WITH_THREAD 1 |
| 3252 | EOF |
| 3253 | |
| 3254 | cat >> confdefs.h <<\EOF |
| 3255 | #define _POSIX_THREADS 1 |
| 3256 | EOF |
| 3257 | |
| 3258 | LIBS="$LIBS -lcma" |
| 3259 | LIBOBJS="$LIBOBJS thread.o" |
| 3260 | else |
| 3261 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3262 | fi |
| 3263 | |
| 3264 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3265 | fi |
| 3266 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3267 | fi |
| 3268 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3269 | fi |
| 3270 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3271 | fi |
| 3272 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3273 | fi |
| 3274 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3275 | fi |
| 3276 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3277 | fi |
| 3278 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3279 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3280 | echo $ac_n "checking for usconfig in -lmpc""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3281 | echo "configure:3282: checking for usconfig in -lmpc" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3282 | ac_lib_var=`echo mpc'_'usconfig | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3283 | 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] | 3284 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3285 | else |
| 3286 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3287 | LIBS="-lmpc $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3288 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3289 | #line 3290 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3290 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3291 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3292 | /* We use char because int might match the return type of a gcc2 |
| 3293 | builtin and then its argument prototype would still apply. */ |
| 3294 | char usconfig(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3295 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3296 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3297 | usconfig() |
| 3298 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3299 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3300 | if { (eval echo configure:3301: \"$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] | 3301 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3302 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3303 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3304 | echo "configure: failed program was:" >&5 |
| 3305 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3306 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3307 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3308 | fi |
| 3309 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3310 | LIBS="$ac_save_LIBS" |
| 3311 | |
| 3312 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3313 | 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] | 3314 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3315 | cat >> confdefs.h <<\EOF |
| 3316 | #define WITH_THREAD 1 |
| 3317 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3318 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3319 | LIBS="$LIBS -lmpc" |
| 3320 | LIBOBJS="$LIBOBJS thread.o" |
| 3321 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3322 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3323 | fi |
| 3324 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3325 | echo $ac_n "checking for thr_create in -lthread""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3326 | echo "configure:3327: checking for thr_create in -lthread" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3327 | ac_lib_var=`echo thread'_'thr_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3328 | 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] | 3329 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3330 | else |
| 3331 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3332 | LIBS="-lthread $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3333 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3334 | #line 3335 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3335 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3336 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3337 | /* We use char because int might match the return type of a gcc2 |
| 3338 | builtin and then its argument prototype would still apply. */ |
| 3339 | char thr_create(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3340 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3341 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3342 | thr_create() |
| 3343 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3344 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3345 | if { (eval echo configure:3346: \"$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] | 3346 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3347 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3348 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3349 | echo "configure: failed program was:" >&5 |
| 3350 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3351 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3352 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3353 | fi |
| 3354 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3355 | LIBS="$ac_save_LIBS" |
| 3356 | |
| 3357 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3358 | 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] | 3359 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3360 | cat >> confdefs.h <<\EOF |
| 3361 | #define WITH_THREAD 1 |
| 3362 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3363 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3364 | LIBS="$LIBS -lthread" |
| 3365 | LIBOBJS="$LIBOBJS thread.o" |
| 3366 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3367 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3368 | fi |
| 3369 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3370 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3371 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3372 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3373 | fi |
| 3374 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3375 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3376 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3377 | |
| 3378 | DLINCLDIR=/ |
| 3379 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3380 | echo $ac_n "checking for --with-sgi-dl""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3381 | echo "configure:3382: checking for --with-sgi-dl" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3382 | # Check whether --with-sgi-dl or --without-sgi-dl was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3383 | if test "${with_sgi_dl+set}" = set; then |
| 3384 | withval="$with_sgi_dl" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3385 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3386 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3387 | cat >> confdefs.h <<\EOF |
| 3388 | #define WITH_SGI_DL 1 |
| 3389 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3390 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3391 | DYNLOADFILE="dynload_dl.o" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3392 | dldir=$withval |
| 3393 | if test -d "$dldir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 3394 | then LDFLAGS="$LDFLAGS -L$dldir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3395 | 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] | 3396 | fi |
| 3397 | DLINCLDIR=${dldir} |
| 3398 | LIBS="$LIBS -ldl -lmld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3399 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3400 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3401 | fi |
| 3402 | |
| 3403 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3404 | echo $ac_n "checking for --with-dl-dld""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3405 | echo "configure:3406: checking for --with-dl-dld" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3406 | # Check whether --with-dl-dld or --without-dl-dld was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3407 | if test "${with_dl_dld+set}" = set; then |
| 3408 | withval="$with_dl_dld" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3409 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3410 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3411 | cat >> confdefs.h <<\EOF |
| 3412 | #define WITH_DL_DLD 1 |
| 3413 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3414 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3415 | DYNLOADFILE="dynload_dl.o" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3416 | dldir=`echo "$withval" | sed 's/,.*//'` |
| 3417 | dlddir=`echo "$withval" | sed 's/.*,//'` |
| 3418 | if test -d "$dldir" -a -d "$dlddir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 3419 | then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3420 | 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] | 3421 | fi |
| 3422 | DLINCLDIR=${dldir} |
| 3423 | LIBS="$LIBS -ldl -ldld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3424 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3425 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3426 | fi |
| 3427 | |
| 3428 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3429 | # the dlopen() function means we might want to use dynload_shlib.o. some |
| 3430 | # platforms, such as AIX, have dlopen(), but don't want to use it. |
| 3431 | echo $ac_n "checking for dlopen""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3432 | echo "configure:3433: checking for dlopen" >&5 |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3433 | if eval "test \"`echo '$''{'ac_cv_func_dlopen'+set}'`\" = set"; then |
| 3434 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3435 | else |
| 3436 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3437 | #line 3438 "configure" |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3438 | #include "confdefs.h" |
| 3439 | /* System header to define __stub macros and hopefully few prototypes, |
| 3440 | which can conflict with char dlopen(); below. */ |
| 3441 | #include <assert.h> |
| 3442 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3443 | /* We use char because int might match the return type of a gcc2 |
| 3444 | builtin and then its argument prototype would still apply. */ |
| 3445 | char dlopen(); |
| 3446 | |
| 3447 | int main() { |
| 3448 | |
| 3449 | /* The GNU C library defines this for functions which it implements |
| 3450 | to always fail with ENOSYS. Some functions are actually named |
| 3451 | something starting with __ and the normal name is an alias. */ |
| 3452 | #if defined (__stub_dlopen) || defined (__stub___dlopen) |
| 3453 | choke me |
| 3454 | #else |
| 3455 | dlopen(); |
| 3456 | #endif |
| 3457 | |
| 3458 | ; return 0; } |
| 3459 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3460 | if { (eval echo configure:3461: \"$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] | 3461 | rm -rf conftest* |
| 3462 | eval "ac_cv_func_dlopen=yes" |
| 3463 | else |
| 3464 | echo "configure: failed program was:" >&5 |
| 3465 | cat conftest.$ac_ext >&5 |
| 3466 | rm -rf conftest* |
| 3467 | eval "ac_cv_func_dlopen=no" |
| 3468 | fi |
| 3469 | rm -f conftest* |
| 3470 | fi |
| 3471 | |
| 3472 | if eval "test \"`echo '$ac_cv_func_'dlopen`\" = yes"; then |
| 3473 | echo "$ac_t""yes" 1>&6 |
| 3474 | : |
| 3475 | else |
| 3476 | echo "$ac_t""no" 1>&6 |
| 3477 | fi |
| 3478 | |
| 3479 | |
| 3480 | # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic |
| 3481 | # loading of modules. |
| 3482 | |
| 3483 | echo $ac_n "checking DYNLOADFILE""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3484 | echo "configure:3485: checking DYNLOADFILE" >&5 |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3485 | if test -z "$DYNLOADFILE" |
| 3486 | then |
| 3487 | case $ac_sys_system/$ac_sys_release in |
| 3488 | AIX*) DYNLOADFILE="dynload_aix.o";; |
| 3489 | BeOS*) DYNLOADFILE="dynload_beos.o";; |
| 3490 | hp*|HP*) DYNLOADFILE="dynload_hpux.o";; |
| 3491 | next/*) DYNLOADFILE="dynload_next.o";; |
| 3492 | *) |
| 3493 | # use dynload_shlib.c and dlopen() if we have it; otherwise stub |
| 3494 | # out any dynamic loading |
| 3495 | if test "$ac_cv_func_dlopen" = yes |
| 3496 | then DYNLOADFILE="dynload_shlib.o" |
| 3497 | else DYNLOADFILE="dynload_stub.o" |
| 3498 | fi |
| 3499 | ;; |
| 3500 | esac |
| 3501 | fi |
| 3502 | echo "$ac_t""$DYNLOADFILE" 1>&6 |
| 3503 | if test "$DYNLOADFILE" != "dynload_stub.o" |
| 3504 | then |
| 3505 | cat >> confdefs.h <<\EOF |
| 3506 | #define HAVE_DYNAMIC_LOADING 1 |
| 3507 | EOF |
| 3508 | |
| 3509 | fi |
| 3510 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3511 | # checks for library functions |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 3512 | for ac_func in alarm chown clock confstr ctermid ctermid_r dlopen execv \ |
| 3513 | flock fork fsync fdatasync fpathconf ftime ftruncate \ |
Fred Drake | f581db1 | 1999-12-14 21:11:47 +0000 | [diff] [blame] | 3514 | getgroups getlogin getpeername getpgrp getpid getpwent gettimeofday getwd \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 3515 | kill link lstat mkfifo mktime nice pathconf pause plock pthread_init \ |
| 3516 | putenv readlink \ |
Guido van Rossum | 9601315 | 1997-10-08 22:47:52 +0000 | [diff] [blame] | 3517 | select setgid setlocale setuid setsid setpgid setpgrp setvbuf \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 3518 | sigaction siginterrupt sigrelse strftime strptime symlink sysconf \ |
Fred Drake | 89143df | 1999-12-09 22:03:25 +0000 | [diff] [blame] | 3519 | tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ |
| 3520 | truncate uname waitpid |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3521 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3522 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3523 | echo "configure:3524: checking for $ac_func" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3524 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 3525 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3526 | else |
| 3527 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3528 | #line 3529 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3529 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3530 | /* System header to define __stub macros and hopefully few prototypes, |
| 3531 | which can conflict with char $ac_func(); below. */ |
| 3532 | #include <assert.h> |
| 3533 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3534 | /* We use char because int might match the return type of a gcc2 |
| 3535 | builtin and then its argument prototype would still apply. */ |
| 3536 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3537 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3538 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3539 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3540 | /* The GNU C library defines this for functions which it implements |
| 3541 | to always fail with ENOSYS. Some functions are actually named |
| 3542 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3543 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3544 | choke me |
| 3545 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3546 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3547 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3548 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3549 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3550 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3551 | if { (eval echo configure:3552: \"$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] | 3552 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3553 | eval "ac_cv_func_$ac_func=yes" |
| 3554 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3555 | echo "configure: failed program was:" >&5 |
| 3556 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3557 | rm -rf conftest* |
| 3558 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3559 | fi |
| 3560 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3561 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3562 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3563 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3564 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3565 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3566 | cat >> confdefs.h <<EOF |
| 3567 | #define $ac_tr_func 1 |
| 3568 | EOF |
| 3569 | |
| 3570 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3571 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3572 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3573 | done |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3574 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 3575 | |
| 3576 | # check for long file support functions |
| 3577 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3578 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3579 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3580 | echo "configure:3581: checking for $ac_func" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3581 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 3582 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3583 | else |
| 3584 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3585 | #line 3586 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3586 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3587 | /* System header to define __stub macros and hopefully few prototypes, |
| 3588 | which can conflict with char $ac_func(); below. */ |
| 3589 | #include <assert.h> |
| 3590 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3591 | /* We use char because int might match the return type of a gcc2 |
| 3592 | builtin and then its argument prototype would still apply. */ |
| 3593 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3594 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3595 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3596 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3597 | /* The GNU C library defines this for functions which it implements |
| 3598 | to always fail with ENOSYS. Some functions are actually named |
| 3599 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3600 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3601 | choke me |
| 3602 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3603 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3604 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3605 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3606 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3607 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3608 | if { (eval echo configure:3609: \"$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] | 3609 | rm -rf conftest* |
| 3610 | eval "ac_cv_func_$ac_func=yes" |
| 3611 | else |
| 3612 | echo "configure: failed program was:" >&5 |
| 3613 | cat conftest.$ac_ext >&5 |
| 3614 | rm -rf conftest* |
| 3615 | eval "ac_cv_func_$ac_func=no" |
| 3616 | fi |
| 3617 | rm -f conftest* |
| 3618 | fi |
| 3619 | |
| 3620 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 3621 | echo "$ac_t""yes" 1>&6 |
| 3622 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 3623 | cat >> confdefs.h <<EOF |
| 3624 | #define $ac_tr_func 1 |
| 3625 | EOF |
| 3626 | |
| 3627 | else |
| 3628 | echo "$ac_t""no" 1>&6 |
| 3629 | fi |
| 3630 | done |
| 3631 | |
| 3632 | |
| 3633 | for ac_func in dup2 getcwd strdup strerror memmove |
| 3634 | do |
| 3635 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3636 | echo "configure:3637: checking for $ac_func" >&5 |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 3637 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 3638 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3639 | else |
| 3640 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3641 | #line 3642 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 3642 | #include "confdefs.h" |
| 3643 | /* System header to define __stub macros and hopefully few prototypes, |
| 3644 | which can conflict with char $ac_func(); below. */ |
| 3645 | #include <assert.h> |
| 3646 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3647 | /* We use char because int might match the return type of a gcc2 |
| 3648 | builtin and then its argument prototype would still apply. */ |
| 3649 | char $ac_func(); |
| 3650 | |
| 3651 | int main() { |
| 3652 | |
| 3653 | /* The GNU C library defines this for functions which it implements |
| 3654 | to always fail with ENOSYS. Some functions are actually named |
| 3655 | something starting with __ and the normal name is an alias. */ |
| 3656 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 3657 | choke me |
| 3658 | #else |
| 3659 | $ac_func(); |
| 3660 | #endif |
| 3661 | |
| 3662 | ; return 0; } |
| 3663 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3664 | if { (eval echo configure:3665: \"$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] | 3665 | rm -rf conftest* |
| 3666 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3667 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3668 | echo "configure: failed program was:" >&5 |
| 3669 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3670 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3671 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3672 | fi |
| 3673 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3674 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3675 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3676 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3677 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3678 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 3679 | cat >> confdefs.h <<EOF |
| 3680 | #define $ac_tr_func 1 |
| 3681 | EOF |
| 3682 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3683 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3684 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3685 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3686 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3687 | done |
| 3688 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3689 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3690 | echo $ac_n "checking for getpgrp""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3691 | echo "configure:3692: checking for getpgrp" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3692 | if eval "test \"`echo '$''{'ac_cv_func_getpgrp'+set}'`\" = set"; then |
| 3693 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3694 | else |
| 3695 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3696 | #line 3697 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3697 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3698 | /* System header to define __stub macros and hopefully few prototypes, |
| 3699 | which can conflict with char getpgrp(); below. */ |
| 3700 | #include <assert.h> |
| 3701 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3702 | /* We use char because int might match the return type of a gcc2 |
| 3703 | builtin and then its argument prototype would still apply. */ |
| 3704 | char getpgrp(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3705 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3706 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3707 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3708 | /* The GNU C library defines this for functions which it implements |
| 3709 | to always fail with ENOSYS. Some functions are actually named |
| 3710 | something starting with __ and the normal name is an alias. */ |
| 3711 | #if defined (__stub_getpgrp) || defined (__stub___getpgrp) |
| 3712 | choke me |
| 3713 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3714 | getpgrp(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3715 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3716 | |
| 3717 | ; return 0; } |
| 3718 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3719 | if { (eval echo configure:3720: \"$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] | 3720 | rm -rf conftest* |
| 3721 | eval "ac_cv_func_getpgrp=yes" |
| 3722 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3723 | echo "configure: failed program was:" >&5 |
| 3724 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3725 | rm -rf conftest* |
| 3726 | eval "ac_cv_func_getpgrp=no" |
| 3727 | fi |
| 3728 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3729 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3730 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3731 | if eval "test \"`echo '$ac_cv_func_'getpgrp`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3732 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3733 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3734 | #line 3735 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3735 | #include "confdefs.h" |
| 3736 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3737 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3738 | getpgrp(0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3739 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3740 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3741 | if { (eval echo configure:3742: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3742 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3743 | cat >> confdefs.h <<\EOF |
| 3744 | #define GETPGRP_HAVE_ARG 1 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3745 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3746 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3747 | else |
| 3748 | echo "configure: failed program was:" >&5 |
| 3749 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3750 | fi |
| 3751 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3752 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3753 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3754 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3755 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3756 | echo $ac_n "checking for setpgrp""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3757 | echo "configure:3758: checking for setpgrp" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3758 | if eval "test \"`echo '$''{'ac_cv_func_setpgrp'+set}'`\" = set"; then |
| 3759 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3760 | else |
| 3761 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3762 | #line 3763 "configure" |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3763 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3764 | /* System header to define __stub macros and hopefully few prototypes, |
| 3765 | which can conflict with char setpgrp(); below. */ |
| 3766 | #include <assert.h> |
| 3767 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3768 | /* We use char because int might match the return type of a gcc2 |
| 3769 | builtin and then its argument prototype would still apply. */ |
| 3770 | char setpgrp(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3771 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3772 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3773 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3774 | /* The GNU C library defines this for functions which it implements |
| 3775 | to always fail with ENOSYS. Some functions are actually named |
| 3776 | something starting with __ and the normal name is an alias. */ |
| 3777 | #if defined (__stub_setpgrp) || defined (__stub___setpgrp) |
| 3778 | choke me |
| 3779 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3780 | setpgrp(); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3781 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3782 | |
| 3783 | ; return 0; } |
| 3784 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3785 | if { (eval echo configure:3786: \"$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] | 3786 | rm -rf conftest* |
| 3787 | eval "ac_cv_func_setpgrp=yes" |
| 3788 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3789 | echo "configure: failed program was:" >&5 |
| 3790 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3791 | rm -rf conftest* |
| 3792 | eval "ac_cv_func_setpgrp=no" |
| 3793 | fi |
| 3794 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3795 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3796 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3797 | if eval "test \"`echo '$ac_cv_func_'setpgrp`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3798 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3799 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3800 | #line 3801 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3801 | #include "confdefs.h" |
| 3802 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3803 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3804 | setpgrp(0,0); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3805 | ; return 0; } |
| 3806 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3807 | if { (eval echo configure:3808: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3808 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3809 | cat >> confdefs.h <<\EOF |
| 3810 | #define SETPGRP_HAVE_ARG 1 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3811 | EOF |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3812 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3813 | else |
| 3814 | echo "configure: failed program was:" >&5 |
| 3815 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3816 | fi |
| 3817 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3818 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3819 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3820 | fi |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3821 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3822 | echo $ac_n "checking for gettimeofday""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3823 | echo "configure:3824: checking for gettimeofday" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3824 | if eval "test \"`echo '$''{'ac_cv_func_gettimeofday'+set}'`\" = set"; then |
| 3825 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3826 | else |
| 3827 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3828 | #line 3829 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3829 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3830 | /* System header to define __stub macros and hopefully few prototypes, |
| 3831 | which can conflict with char gettimeofday(); below. */ |
| 3832 | #include <assert.h> |
| 3833 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3834 | /* We use char because int might match the return type of a gcc2 |
| 3835 | builtin and then its argument prototype would still apply. */ |
| 3836 | char gettimeofday(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3837 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3838 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3839 | |
| 3840 | /* The GNU C library defines this for functions which it implements |
| 3841 | to always fail with ENOSYS. Some functions are actually named |
| 3842 | something starting with __ and the normal name is an alias. */ |
| 3843 | #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday) |
| 3844 | choke me |
| 3845 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3846 | gettimeofday(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3847 | #endif |
| 3848 | |
| 3849 | ; return 0; } |
| 3850 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3851 | if { (eval echo configure:3852: \"$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] | 3852 | rm -rf conftest* |
| 3853 | eval "ac_cv_func_gettimeofday=yes" |
| 3854 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3855 | echo "configure: failed program was:" >&5 |
| 3856 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3857 | rm -rf conftest* |
| 3858 | eval "ac_cv_func_gettimeofday=no" |
| 3859 | fi |
| 3860 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3861 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3862 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3863 | if eval "test \"`echo '$ac_cv_func_'gettimeofday`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3864 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3865 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3866 | #line 3867 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3867 | #include "confdefs.h" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3868 | #include <sys/time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3869 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3870 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
| 3871 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3872 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3873 | if { (eval echo configure:3874: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3874 | : |
| 3875 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3876 | echo "configure: failed program was:" >&5 |
| 3877 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3878 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3879 | cat >> confdefs.h <<\EOF |
| 3880 | #define GETTIMEOFDAY_NO_TZ 1 |
| 3881 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3882 | |
| 3883 | fi |
| 3884 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3885 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3886 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3887 | fi |
| 3888 | |
| 3889 | |
| 3890 | # checks for structures |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3891 | echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3892 | echo "configure:3893: checking whether time.h and sys/time.h may both be included" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3893 | if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then |
| 3894 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3895 | else |
| 3896 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3897 | #line 3898 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3898 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3899 | #include <sys/types.h> |
| 3900 | #include <sys/time.h> |
| 3901 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3902 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3903 | struct tm *tp; |
| 3904 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3905 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3906 | if { (eval echo configure:3907: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3907 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3908 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3909 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3910 | echo "configure: failed program was:" >&5 |
| 3911 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3912 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3913 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3914 | fi |
| 3915 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3916 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3917 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3918 | echo "$ac_t""$ac_cv_header_time" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3919 | if test $ac_cv_header_time = yes; then |
| 3920 | cat >> confdefs.h <<\EOF |
| 3921 | #define TIME_WITH_SYS_TIME 1 |
| 3922 | EOF |
| 3923 | |
| 3924 | fi |
| 3925 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3926 | echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3927 | echo "configure:3928: checking whether struct tm is in sys/time.h or time.h" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3928 | if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then |
| 3929 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3930 | else |
| 3931 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3932 | #line 3933 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3933 | #include "confdefs.h" |
| 3934 | #include <sys/types.h> |
| 3935 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3936 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3937 | struct tm *tp; tp->tm_sec; |
| 3938 | ; return 0; } |
| 3939 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3940 | if { (eval echo configure:3941: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3941 | rm -rf conftest* |
| 3942 | ac_cv_struct_tm=time.h |
| 3943 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3944 | echo "configure: failed program was:" >&5 |
| 3945 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3946 | rm -rf conftest* |
| 3947 | ac_cv_struct_tm=sys/time.h |
| 3948 | fi |
| 3949 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3950 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3951 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3952 | echo "$ac_t""$ac_cv_struct_tm" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3953 | if test $ac_cv_struct_tm = sys/time.h; then |
| 3954 | cat >> confdefs.h <<\EOF |
| 3955 | #define TM_IN_SYS_TIME 1 |
| 3956 | EOF |
| 3957 | |
| 3958 | fi |
| 3959 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3960 | echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3961 | echo "configure:3962: checking for tm_zone in struct tm" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3962 | if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then |
| 3963 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3964 | else |
| 3965 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3966 | #line 3967 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3967 | #include "confdefs.h" |
| 3968 | #include <sys/types.h> |
| 3969 | #include <$ac_cv_struct_tm> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3970 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3971 | struct tm tm; tm.tm_zone; |
| 3972 | ; return 0; } |
| 3973 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3974 | if { (eval echo configure:3975: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3975 | rm -rf conftest* |
| 3976 | ac_cv_struct_tm_zone=yes |
| 3977 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3978 | echo "configure: failed program was:" >&5 |
| 3979 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3980 | rm -rf conftest* |
| 3981 | ac_cv_struct_tm_zone=no |
| 3982 | fi |
| 3983 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3984 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3985 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3986 | echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3987 | if test "$ac_cv_struct_tm_zone" = yes; then |
| 3988 | cat >> confdefs.h <<\EOF |
| 3989 | #define HAVE_TM_ZONE 1 |
| 3990 | EOF |
| 3991 | |
| 3992 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3993 | echo $ac_n "checking for tzname""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3994 | echo "configure:3995: checking for tzname" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3995 | if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then |
| 3996 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3997 | else |
| 3998 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 3999 | #line 4000 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4000 | #include "confdefs.h" |
| 4001 | #include <time.h> |
| 4002 | #ifndef tzname /* For SGI. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4003 | extern char *tzname[]; /* RS6000 and others reject char **tzname. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4004 | #endif |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4005 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4006 | atoi(*tzname); |
| 4007 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4008 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4009 | if { (eval echo configure:4010: \"$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] | 4010 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4011 | ac_cv_var_tzname=yes |
| 4012 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4013 | echo "configure: failed program was:" >&5 |
| 4014 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4015 | rm -rf conftest* |
| 4016 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4017 | fi |
| 4018 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4019 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4020 | |
| 4021 | echo "$ac_t""$ac_cv_var_tzname" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4022 | if test $ac_cv_var_tzname = yes; then |
| 4023 | cat >> confdefs.h <<\EOF |
| 4024 | #define HAVE_TZNAME 1 |
| 4025 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4026 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4027 | fi |
| 4028 | fi |
| 4029 | |
| 4030 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4031 | echo $ac_n "checking for time.h that defines altzone""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4032 | echo "configure:4033: checking for time.h that defines altzone" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4033 | if eval "test \"`echo '$''{'ac_cv_header_time_altzone'+set}'`\" = set"; then |
| 4034 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4035 | else |
| 4036 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4037 | #line 4038 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4038 | #include "confdefs.h" |
| 4039 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4040 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4041 | return altzone; |
| 4042 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4043 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4044 | if { (eval echo configure:4045: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4045 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4046 | ac_cv_header_time_altzone=yes |
| 4047 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4048 | echo "configure: failed program was:" >&5 |
| 4049 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4050 | rm -rf conftest* |
| 4051 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4052 | fi |
| 4053 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4054 | fi |
| 4055 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4056 | echo "$ac_t""$ac_cv_header_time_altzone" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4057 | if test $ac_cv_header_time_altzone = yes; then |
| 4058 | cat >> confdefs.h <<\EOF |
| 4059 | #define HAVE_ALTZONE 1 |
| 4060 | EOF |
| 4061 | |
| 4062 | fi |
| 4063 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4064 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4065 | echo $ac_n "checking whether sys/select.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4066 | echo "configure:4067: 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] | 4067 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4068 | #line 4069 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4069 | #include "confdefs.h" |
| 4070 | |
| 4071 | #include <sys/types.h> |
| 4072 | #include <sys/select.h> |
| 4073 | #include <sys/time.h> |
| 4074 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4075 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4076 | ; |
| 4077 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4078 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4079 | if { (eval echo configure:4080: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4080 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4081 | cat >> confdefs.h <<\EOF |
| 4082 | #define SYS_SELECT_WITH_SYS_TIME 1 |
| 4083 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4084 | was_it_defined=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4085 | else |
| 4086 | echo "configure: failed program was:" >&5 |
| 4087 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4088 | fi |
| 4089 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4090 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4091 | |
| 4092 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4093 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4094 | echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4095 | echo "configure:4096: checking whether char is unsigned" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4096 | if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then |
| 4097 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4098 | else |
| 4099 | if test "$GCC" = yes; then |
| 4100 | # GCC predefines this symbol on systems where it applies. |
| 4101 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4102 | #line 4103 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4103 | #include "confdefs.h" |
| 4104 | #ifdef __CHAR_UNSIGNED__ |
| 4105 | yes |
| 4106 | #endif |
| 4107 | |
| 4108 | EOF |
| 4109 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 4110 | egrep "yes" >/dev/null 2>&1; then |
| 4111 | rm -rf conftest* |
| 4112 | ac_cv_c_char_unsigned=yes |
| 4113 | else |
| 4114 | rm -rf conftest* |
| 4115 | ac_cv_c_char_unsigned=no |
| 4116 | fi |
| 4117 | rm -f conftest* |
| 4118 | |
| 4119 | else |
| 4120 | if test "$cross_compiling" = yes; then |
| 4121 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 4122 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4123 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4124 | #line 4125 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4125 | #include "confdefs.h" |
| 4126 | /* volatile prevents gcc2 from optimizing the test away on sparcs. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4127 | #if !defined(__STDC__) || __STDC__ != 1 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4128 | #define volatile |
| 4129 | #endif |
| 4130 | main() { |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4131 | volatile char c = 255; exit(c < 0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4132 | } |
| 4133 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4134 | if { (eval echo configure:4135: \"$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] | 4135 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4136 | ac_cv_c_char_unsigned=yes |
| 4137 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4138 | echo "configure: failed program was:" >&5 |
| 4139 | cat conftest.$ac_ext >&5 |
| 4140 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4141 | ac_cv_c_char_unsigned=no |
| 4142 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4143 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4144 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4145 | |
| 4146 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4147 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4148 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4149 | echo "$ac_t""$ac_cv_c_char_unsigned" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4150 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
| 4151 | cat >> confdefs.h <<\EOF |
| 4152 | #define __CHAR_UNSIGNED__ 1 |
| 4153 | EOF |
| 4154 | |
| 4155 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4156 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4157 | echo $ac_n "checking for working const""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4158 | echo "configure:4159: checking for working const" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4159 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
| 4160 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4161 | else |
| 4162 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4163 | #line 4164 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4164 | #include "confdefs.h" |
| 4165 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4166 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4167 | |
| 4168 | /* Ultrix mips cc rejects this. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4169 | typedef int charset[2]; const charset x; |
| 4170 | /* SunOS 4.1.1 cc rejects this. */ |
| 4171 | char const *const *ccp; |
| 4172 | char **p; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4173 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 4174 | struct point {int x, y;}; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4175 | static struct point const zero = {0,0}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4176 | /* AIX XL C 1.02.0.0 rejects this. |
| 4177 | It does not let you subtract one const X* pointer from another in an arm |
| 4178 | of an if-expression whose if-part is not a constant expression */ |
| 4179 | const char *g = "string"; |
| 4180 | ccp = &g + (g ? g-g : 0); |
| 4181 | /* HPUX 7.0 cc rejects these. */ |
| 4182 | ++ccp; |
| 4183 | p = (char**) ccp; |
| 4184 | ccp = (char const *const *) p; |
| 4185 | { /* SCO 3.2v4 cc rejects this. */ |
| 4186 | char *t; |
| 4187 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
| 4188 | |
| 4189 | *t++ = 0; |
| 4190 | } |
| 4191 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4192 | int x[] = {25, 17}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4193 | const int *foo = &x[0]; |
| 4194 | ++foo; |
| 4195 | } |
| 4196 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 4197 | typedef const int *iptr; |
| 4198 | iptr p = 0; |
| 4199 | ++p; |
| 4200 | } |
| 4201 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 4202 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 4203 | struct s { int j; const int *ap[3]; }; |
| 4204 | struct s *b; b->j = 5; |
| 4205 | } |
| 4206 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 4207 | const int foo = 10; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4208 | } |
| 4209 | |
| 4210 | ; return 0; } |
| 4211 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4212 | if { (eval echo configure:4213: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4213 | rm -rf conftest* |
| 4214 | ac_cv_c_const=yes |
| 4215 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4216 | echo "configure: failed program was:" >&5 |
| 4217 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4218 | rm -rf conftest* |
| 4219 | ac_cv_c_const=no |
| 4220 | fi |
| 4221 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4222 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4223 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4224 | echo "$ac_t""$ac_cv_c_const" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4225 | if test $ac_cv_c_const = no; then |
| 4226 | cat >> confdefs.h <<\EOF |
| 4227 | #define const |
| 4228 | EOF |
| 4229 | |
| 4230 | fi |
| 4231 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4232 | echo $ac_n "checking for inline""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4233 | echo "configure:4234: checking for inline" >&5 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4234 | if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then |
| 4235 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4236 | else |
| 4237 | ac_cv_c_inline=no |
| 4238 | for ac_kw in inline __inline__ __inline; do |
| 4239 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4240 | #line 4241 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4241 | #include "confdefs.h" |
| 4242 | |
| 4243 | int main() { |
| 4244 | } $ac_kw foo() { |
| 4245 | ; return 0; } |
| 4246 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4247 | if { (eval echo configure:4248: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4248 | rm -rf conftest* |
| 4249 | ac_cv_c_inline=$ac_kw; break |
| 4250 | else |
| 4251 | echo "configure: failed program was:" >&5 |
| 4252 | cat conftest.$ac_ext >&5 |
| 4253 | fi |
| 4254 | rm -f conftest* |
| 4255 | done |
| 4256 | |
| 4257 | fi |
| 4258 | |
| 4259 | echo "$ac_t""$ac_cv_c_inline" 1>&6 |
| 4260 | case "$ac_cv_c_inline" in |
| 4261 | inline | yes) ;; |
| 4262 | no) cat >> confdefs.h <<\EOF |
| 4263 | #define inline |
| 4264 | EOF |
| 4265 | ;; |
| 4266 | *) cat >> confdefs.h <<EOF |
| 4267 | #define inline $ac_cv_c_inline |
| 4268 | EOF |
| 4269 | ;; |
| 4270 | esac |
| 4271 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4272 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4273 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4274 | echo $ac_n "checking for working volatile""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4275 | echo "configure:4276: checking for working volatile" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4276 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4277 | #line 4278 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4278 | #include "confdefs.h" |
| 4279 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4280 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4281 | volatile int x; x = 0; |
| 4282 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4283 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4284 | if { (eval echo configure:4285: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4285 | rm -rf conftest* |
| 4286 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4287 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4288 | echo "configure: failed program was:" >&5 |
| 4289 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4290 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4291 | cat >> confdefs.h <<\EOF |
| 4292 | #define volatile |
| 4293 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4294 | |
| 4295 | fi |
| 4296 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4297 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4298 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4299 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4300 | echo $ac_n "checking for working signed char""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4301 | echo "configure:4302: checking for working signed char" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4302 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4303 | #line 4304 "configure" |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4304 | #include "confdefs.h" |
| 4305 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4306 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4307 | signed char c; |
| 4308 | ; return 0; } |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4309 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4310 | if { (eval echo configure:4311: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4311 | rm -rf conftest* |
| 4312 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4313 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4314 | echo "configure: failed program was:" >&5 |
| 4315 | cat conftest.$ac_ext >&5 |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4316 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4317 | cat >> confdefs.h <<\EOF |
| 4318 | #define signed |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4319 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4320 | |
| 4321 | fi |
| 4322 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4323 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4324 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4325 | have_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4326 | echo $ac_n "checking for prototypes""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4327 | echo "configure:4328: checking for prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4328 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4329 | #line 4330 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4330 | #include "confdefs.h" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4331 | int foo(int x) { return 0; } |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4332 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4333 | return foo(10); |
| 4334 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4335 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4336 | if { (eval echo configure:4337: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4337 | rm -rf conftest* |
| 4338 | cat >> confdefs.h <<\EOF |
| 4339 | #define HAVE_PROTOTYPES 1 |
| 4340 | EOF |
| 4341 | have_prototypes=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4342 | else |
| 4343 | echo "configure: failed program was:" >&5 |
| 4344 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4345 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4346 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4347 | echo "$ac_t""$have_prototypes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4348 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4349 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4350 | echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4351 | echo "configure:4352: checking for variable length prototypes and stdarg.h" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4352 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4353 | #line 4354 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4354 | #include "confdefs.h" |
| 4355 | |
| 4356 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 4357 | int foo(int x, ...) { |
| 4358 | va_list va; |
| 4359 | va_start(va, x); |
| 4360 | va_arg(va, int); |
| 4361 | va_arg(va, char *); |
| 4362 | va_arg(va, double); |
| 4363 | return 0; |
| 4364 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4365 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4366 | int main() { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 4367 | return foo(10, "", 3.14); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4368 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4369 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4370 | if { (eval echo configure:4371: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4371 | rm -rf conftest* |
| 4372 | cat >> confdefs.h <<\EOF |
| 4373 | #define HAVE_STDARG_PROTOTYPES 1 |
| 4374 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4375 | works=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4376 | else |
| 4377 | echo "configure: failed program was:" >&5 |
| 4378 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4379 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4380 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4381 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4382 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4383 | if test "$have_prototypes" = yes; then |
| 4384 | bad_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4385 | echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4386 | echo "configure:4387: checking for bad exec* prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4387 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4388 | #line 4389 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4389 | #include "confdefs.h" |
| 4390 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4391 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4392 | char **t;execve("@",t,t); |
| 4393 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4394 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4395 | if { (eval echo configure:4396: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4396 | : |
| 4397 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4398 | echo "configure: failed program was:" >&5 |
| 4399 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4400 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4401 | cat >> confdefs.h <<\EOF |
| 4402 | #define BAD_EXEC_PROTOTYPES 1 |
| 4403 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4404 | bad_prototypes=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4405 | fi |
| 4406 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4407 | echo "$ac_t""$bad_prototypes" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4408 | fi |
| 4409 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4410 | bad_forward=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4411 | echo $ac_n "checking for bad static forward""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4412 | echo "configure:4413: checking for bad static forward" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4413 | if test "$cross_compiling" = yes; then |
| 4414 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 4415 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4416 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4417 | #line 4418 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4418 | #include "confdefs.h" |
| 4419 | |
| 4420 | struct s { int a; int b; }; |
| 4421 | static struct s foo; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4422 | int foobar() { |
| 4423 | static int random; |
| 4424 | random = (int) &foo; |
| 4425 | return random; |
| 4426 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4427 | static struct s foo = { 1, 2 }; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4428 | main() { |
| 4429 | exit(!((int)&foo == foobar())); |
| 4430 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4431 | |
| 4432 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4433 | if { (eval echo configure:4434: \"$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] | 4434 | then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4435 | : |
| 4436 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4437 | echo "configure: failed program was:" >&5 |
| 4438 | cat conftest.$ac_ext >&5 |
| 4439 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4440 | cat >> confdefs.h <<\EOF |
| 4441 | #define BAD_STATIC_FORWARD 1 |
| 4442 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4443 | bad_forward=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4444 | fi |
| 4445 | rm -fr conftest* |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4446 | fi |
| 4447 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4448 | echo "$ac_t""$bad_forward" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4449 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4450 | va_list_is_array=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4451 | echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4452 | echo "configure:4453: checking whether va_list is an array" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4453 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4454 | #line 4455 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4455 | #include "confdefs.h" |
| 4456 | |
| 4457 | #ifdef HAVE_STDARG_PROTOTYPES |
| 4458 | #include <stdarg.h> |
| 4459 | #else |
| 4460 | #include <varargs.h> |
| 4461 | #endif |
| 4462 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4463 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4464 | va_list list1, list2; list1 = list2; |
| 4465 | ; return 0; } |
| 4466 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4467 | if { (eval echo configure:4468: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4468 | : |
| 4469 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4470 | echo "configure: failed program was:" >&5 |
| 4471 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4472 | rm -rf conftest* |
| 4473 | cat >> confdefs.h <<\EOF |
| 4474 | #define VA_LIST_IS_ARRAY 1 |
| 4475 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4476 | va_list_is_array=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4477 | fi |
| 4478 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4479 | echo "$ac_t""$va_list_is_array" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4480 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4481 | # sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-( |
| 4482 | echo $ac_n "checking for gethostbyname_r""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4483 | echo "configure:4484: checking for gethostbyname_r" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4484 | if eval "test \"`echo '$''{'ac_cv_func_gethostbyname_r'+set}'`\" = set"; then |
| 4485 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4486 | else |
| 4487 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4488 | #line 4489 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4489 | #include "confdefs.h" |
| 4490 | /* System header to define __stub macros and hopefully few prototypes, |
| 4491 | which can conflict with char gethostbyname_r(); below. */ |
| 4492 | #include <assert.h> |
| 4493 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4494 | /* We use char because int might match the return type of a gcc2 |
| 4495 | builtin and then its argument prototype would still apply. */ |
| 4496 | char gethostbyname_r(); |
| 4497 | |
| 4498 | int main() { |
| 4499 | |
| 4500 | /* The GNU C library defines this for functions which it implements |
| 4501 | to always fail with ENOSYS. Some functions are actually named |
| 4502 | something starting with __ and the normal name is an alias. */ |
| 4503 | #if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r) |
| 4504 | choke me |
| 4505 | #else |
| 4506 | gethostbyname_r(); |
| 4507 | #endif |
| 4508 | |
| 4509 | ; return 0; } |
| 4510 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4511 | if { (eval echo configure:4512: \"$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] | 4512 | rm -rf conftest* |
| 4513 | eval "ac_cv_func_gethostbyname_r=yes" |
| 4514 | else |
| 4515 | echo "configure: failed program was:" >&5 |
| 4516 | cat conftest.$ac_ext >&5 |
| 4517 | rm -rf conftest* |
| 4518 | eval "ac_cv_func_gethostbyname_r=no" |
| 4519 | fi |
| 4520 | rm -f conftest* |
| 4521 | fi |
| 4522 | |
| 4523 | if eval "test \"`echo '$ac_cv_func_'gethostbyname_r`\" = yes"; then |
| 4524 | echo "$ac_t""yes" 1>&6 |
| 4525 | |
| 4526 | cat >> confdefs.h <<\EOF |
| 4527 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4528 | EOF |
| 4529 | |
| 4530 | echo $ac_n "checking gethostbyname_r with 6 args""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4531 | echo "configure:4532: checking gethostbyname_r with 6 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4532 | OLD_CFLAGS=$CFLAGS |
| 4533 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
| 4534 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4535 | #line 4536 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4536 | #include "confdefs.h" |
| 4537 | |
| 4538 | # include <netdb.h> |
| 4539 | |
| 4540 | int main() { |
| 4541 | |
| 4542 | char *name; |
| 4543 | struct hostent *he, *res; |
| 4544 | char buffer[2048]; |
| 4545 | int buflen = 2048; |
| 4546 | int h_errnop; |
| 4547 | |
| 4548 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
| 4549 | |
| 4550 | ; return 0; } |
| 4551 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4552 | if { (eval echo configure:4553: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4553 | rm -rf conftest* |
| 4554 | |
| 4555 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4556 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4557 | EOF |
| 4558 | |
| 4559 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4560 | #define HAVE_GETHOSTBYNAME_R_6_ARG 1 |
| 4561 | EOF |
| 4562 | |
| 4563 | echo "$ac_t""yes" 1>&6 |
| 4564 | |
| 4565 | else |
| 4566 | echo "configure: failed program was:" >&5 |
| 4567 | cat conftest.$ac_ext >&5 |
| 4568 | rm -rf conftest* |
| 4569 | |
| 4570 | echo "$ac_t""no" 1>&6 |
| 4571 | echo $ac_n "checking gethostbyname_r with 5 args""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4572 | echo "configure:4573: checking gethostbyname_r with 5 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4573 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4574 | #line 4575 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4575 | #include "confdefs.h" |
| 4576 | |
| 4577 | # include <netdb.h> |
| 4578 | |
| 4579 | int main() { |
| 4580 | |
| 4581 | char *name; |
| 4582 | struct hostent *he; |
| 4583 | char buffer[2048]; |
| 4584 | int buflen = 2048; |
| 4585 | int h_errnop; |
| 4586 | |
| 4587 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
| 4588 | |
| 4589 | ; return 0; } |
| 4590 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4591 | if { (eval echo configure:4592: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4592 | rm -rf conftest* |
| 4593 | |
| 4594 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4595 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4596 | EOF |
| 4597 | |
| 4598 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4599 | #define HAVE_GETHOSTBYNAME_R_5_ARG 1 |
| 4600 | EOF |
| 4601 | |
| 4602 | echo "$ac_t""yes" 1>&6 |
| 4603 | |
| 4604 | else |
| 4605 | echo "configure: failed program was:" >&5 |
| 4606 | cat conftest.$ac_ext >&5 |
| 4607 | rm -rf conftest* |
| 4608 | |
| 4609 | echo "$ac_t""no" 1>&6 |
| 4610 | echo $ac_n "checking gethostbyname_r with 3 args""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4611 | echo "configure:4612: checking gethostbyname_r with 3 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4612 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4613 | #line 4614 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4614 | #include "confdefs.h" |
| 4615 | |
| 4616 | # include <netdb.h> |
| 4617 | |
| 4618 | int main() { |
| 4619 | |
| 4620 | char *name; |
| 4621 | struct hostent *he; |
| 4622 | struct hostent_data data; |
| 4623 | |
| 4624 | (void) gethostbyname_r(name, he, &data); |
| 4625 | |
| 4626 | ; return 0; } |
| 4627 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4628 | if { (eval echo configure:4629: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4629 | rm -rf conftest* |
| 4630 | |
| 4631 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4632 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4633 | EOF |
| 4634 | |
| 4635 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4636 | #define HAVE_GETHOSTBYNAME_R_3_ARG 1 |
| 4637 | EOF |
| 4638 | |
| 4639 | echo "$ac_t""yes" 1>&6 |
| 4640 | |
| 4641 | else |
| 4642 | echo "configure: failed program was:" >&5 |
| 4643 | cat conftest.$ac_ext >&5 |
| 4644 | rm -rf conftest* |
| 4645 | |
| 4646 | echo "$ac_t""no" 1>&6 |
| 4647 | |
| 4648 | fi |
| 4649 | rm -f conftest* |
| 4650 | |
| 4651 | fi |
| 4652 | rm -f conftest* |
| 4653 | |
| 4654 | fi |
| 4655 | rm -f conftest* |
| 4656 | CFLAGS=$OLD_CFLAGS |
| 4657 | |
| 4658 | else |
| 4659 | echo "$ac_t""no" 1>&6 |
| 4660 | |
| 4661 | echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4662 | echo "configure:4663: checking for gethostbyname" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4663 | if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then |
| 4664 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4665 | else |
| 4666 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4667 | #line 4668 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4668 | #include "confdefs.h" |
| 4669 | /* System header to define __stub macros and hopefully few prototypes, |
| 4670 | which can conflict with char gethostbyname(); below. */ |
| 4671 | #include <assert.h> |
| 4672 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4673 | /* We use char because int might match the return type of a gcc2 |
| 4674 | builtin and then its argument prototype would still apply. */ |
| 4675 | char gethostbyname(); |
| 4676 | |
| 4677 | int main() { |
| 4678 | |
| 4679 | /* The GNU C library defines this for functions which it implements |
| 4680 | to always fail with ENOSYS. Some functions are actually named |
| 4681 | something starting with __ and the normal name is an alias. */ |
| 4682 | #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) |
| 4683 | choke me |
| 4684 | #else |
| 4685 | gethostbyname(); |
| 4686 | #endif |
| 4687 | |
| 4688 | ; return 0; } |
| 4689 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4690 | if { (eval echo configure:4691: \"$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] | 4691 | rm -rf conftest* |
| 4692 | eval "ac_cv_func_gethostbyname=yes" |
| 4693 | else |
| 4694 | echo "configure: failed program was:" >&5 |
| 4695 | cat conftest.$ac_ext >&5 |
| 4696 | rm -rf conftest* |
| 4697 | eval "ac_cv_func_gethostbyname=no" |
| 4698 | fi |
| 4699 | rm -f conftest* |
| 4700 | fi |
| 4701 | |
| 4702 | if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then |
| 4703 | echo "$ac_t""yes" 1>&6 |
| 4704 | cat >> confdefs.h <<\EOF |
| 4705 | #define HAVE_GETHOSTBYNAME 1 |
| 4706 | EOF |
| 4707 | |
| 4708 | else |
| 4709 | echo "$ac_t""no" 1>&6 |
| 4710 | fi |
| 4711 | |
| 4712 | |
| 4713 | fi |
| 4714 | |
| 4715 | |
| 4716 | |
| 4717 | |
| 4718 | |
| 4719 | |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4720 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4721 | # checks for system services |
| 4722 | # (none yet) |
| 4723 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4724 | # Linux requires this for correct f.p. operations |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4725 | echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4726 | echo "configure:4727: checking for __fpu_control in -lieee" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4727 | ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4728 | 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] | 4729 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4730 | else |
| 4731 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4732 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4733 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4734 | #line 4735 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4735 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4736 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4737 | /* We use char because int might match the return type of a gcc2 |
| 4738 | builtin and then its argument prototype would still apply. */ |
| 4739 | char __fpu_control(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4740 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4741 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4742 | __fpu_control() |
| 4743 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4744 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4745 | if { (eval echo configure:4746: \"$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] | 4746 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4747 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4748 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4749 | echo "configure: failed program was:" >&5 |
| 4750 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4751 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4752 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4753 | fi |
| 4754 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4755 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4756 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4757 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4758 | 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] | 4759 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4760 | ac_tr_lib=HAVE_LIB`echo ieee | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 4761 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4762 | cat >> confdefs.h <<EOF |
| 4763 | #define $ac_tr_lib 1 |
| 4764 | EOF |
| 4765 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4766 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4767 | |
| 4768 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4769 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4770 | fi |
| 4771 | |
| 4772 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4773 | # Check for --with-fpectl |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4774 | echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4775 | echo "configure:4776: checking for --with-fpectl" >&5 |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4776 | # Check whether --with-fpectl or --without-fpectl was given. |
| 4777 | if test "${with_fpectl+set}" = set; then |
| 4778 | withval="$with_fpectl" |
| 4779 | |
| 4780 | if test "$withval" != no |
| 4781 | then cat >> confdefs.h <<\EOF |
| 4782 | #define WANT_SIGFPE_HANDLER 1 |
| 4783 | EOF |
| 4784 | echo "$ac_t""yes" 1>&6 |
| 4785 | else echo "$ac_t""no" 1>&6 |
| 4786 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4787 | else |
| 4788 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4789 | fi |
| 4790 | |
| 4791 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4792 | # check for --with-libm=... |
| 4793 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 4794 | case $ac_sys_system in |
| 4795 | next) ;; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 4796 | BeOS) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 4797 | *) LIBM=-lm |
| 4798 | esac |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4799 | echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4800 | echo "configure:4801: checking for --with-libm=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4801 | # Check whether --with-libm or --without-libm was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4802 | if test "${with_libm+set}" = set; then |
| 4803 | withval="$with_libm" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4804 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4805 | if test "$withval" = no |
| 4806 | then LIBM= |
| 4807 | echo "$ac_t""force LIBM empty" 1>&6 |
| 4808 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4809 | then LIBM=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4810 | echo "$ac_t""set LIBM=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4811 | 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] | 4812 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4813 | else |
| 4814 | echo "$ac_t""default LIBM=\"$LIBM\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4815 | fi |
| 4816 | |
| 4817 | |
| 4818 | # check for --with-libc=... |
| 4819 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4820 | echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4821 | echo "configure:4822: checking for --with-libc=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4822 | # Check whether --with-libc or --without-libc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4823 | if test "${with_libc+set}" = set; then |
| 4824 | withval="$with_libc" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4825 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4826 | if test "$withval" = no |
| 4827 | then LIBC= |
| 4828 | echo "$ac_t""force LIBC empty" 1>&6 |
| 4829 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4830 | then LIBC=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4831 | echo "$ac_t""set LIBC=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4832 | 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] | 4833 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4834 | else |
| 4835 | echo "$ac_t""default LIBC=\"$LIBC\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4836 | fi |
| 4837 | |
| 4838 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4839 | # check for hypot() in math library |
| 4840 | LIBS_SAVE=$LIBS |
| 4841 | LIBS="$LIBS $LIBM" |
| 4842 | for ac_func in hypot |
| 4843 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4844 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4845 | echo "configure:4846: checking for $ac_func" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4846 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 4847 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4848 | else |
| 4849 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4850 | #line 4851 "configure" |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4851 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4852 | /* System header to define __stub macros and hopefully few prototypes, |
| 4853 | which can conflict with char $ac_func(); below. */ |
| 4854 | #include <assert.h> |
| 4855 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4856 | /* We use char because int might match the return type of a gcc2 |
| 4857 | builtin and then its argument prototype would still apply. */ |
| 4858 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4859 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4860 | int main() { |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4861 | |
| 4862 | /* The GNU C library defines this for functions which it implements |
| 4863 | to always fail with ENOSYS. Some functions are actually named |
| 4864 | something starting with __ and the normal name is an alias. */ |
| 4865 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4866 | choke me |
| 4867 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4868 | $ac_func(); |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4869 | #endif |
| 4870 | |
| 4871 | ; return 0; } |
| 4872 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4873 | if { (eval echo configure:4874: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4874 | rm -rf conftest* |
| 4875 | eval "ac_cv_func_$ac_func=yes" |
| 4876 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4877 | echo "configure: failed program was:" >&5 |
| 4878 | cat conftest.$ac_ext >&5 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4879 | rm -rf conftest* |
| 4880 | eval "ac_cv_func_$ac_func=no" |
| 4881 | fi |
| 4882 | rm -f conftest* |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4883 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4884 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4885 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4886 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4887 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4888 | cat >> confdefs.h <<EOF |
| 4889 | #define $ac_tr_func 1 |
| 4890 | EOF |
| 4891 | |
| 4892 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4893 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4894 | fi |
| 4895 | done |
| 4896 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4897 | for ac_func in hypot |
| 4898 | do |
| 4899 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4900 | echo "configure:4901: checking for $ac_func" >&5 |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4901 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 4902 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4903 | else |
| 4904 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4905 | #line 4906 "configure" |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4906 | #include "confdefs.h" |
| 4907 | /* System header to define __stub macros and hopefully few prototypes, |
| 4908 | which can conflict with char $ac_func(); below. */ |
| 4909 | #include <assert.h> |
| 4910 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4911 | /* We use char because int might match the return type of a gcc2 |
| 4912 | builtin and then its argument prototype would still apply. */ |
| 4913 | char $ac_func(); |
| 4914 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4915 | int main() { |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4916 | |
| 4917 | /* The GNU C library defines this for functions which it implements |
| 4918 | to always fail with ENOSYS. Some functions are actually named |
| 4919 | something starting with __ and the normal name is an alias. */ |
| 4920 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4921 | choke me |
| 4922 | #else |
| 4923 | $ac_func(); |
| 4924 | #endif |
| 4925 | |
| 4926 | ; return 0; } |
| 4927 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4928 | if { (eval echo configure:4929: \"$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] | 4929 | rm -rf conftest* |
| 4930 | eval "ac_cv_func_$ac_func=yes" |
| 4931 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4932 | echo "configure: failed program was:" >&5 |
| 4933 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4934 | rm -rf conftest* |
| 4935 | eval "ac_cv_func_$ac_func=no" |
| 4936 | fi |
| 4937 | rm -f conftest* |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4938 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4939 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4940 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4941 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4942 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4943 | cat >> confdefs.h <<EOF |
| 4944 | #define $ac_tr_func 1 |
| 4945 | EOF |
| 4946 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4947 | else |
| 4948 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4949 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4950 | fi |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4951 | done |
| 4952 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4953 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4954 | LIBS=$LIBS_SAVE |
| 4955 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4956 | # check for getopt |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4957 | echo $ac_n "checking for genuine getopt""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4958 | echo "configure:4959: checking for genuine getopt" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4959 | if eval "test \"`echo '$''{'ac_cv_func_getopt'+set}'`\" = set"; then |
| 4960 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4961 | else |
| 4962 | if test "$cross_compiling" = yes; then |
| 4963 | ac_cv_func_getopt=no |
| 4964 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4965 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4966 | #line 4967 "configure" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4967 | #include "confdefs.h" |
| 4968 | #include <stdio.h> |
| 4969 | extern int optind, opterr, getopt(); |
| 4970 | extern char* optarg; |
| 4971 | int main() { |
| 4972 | char* av[] = { "testprog", "parameter", "-fFlag", NULL }; |
| 4973 | opterr = 0; |
| 4974 | if (getopt(3, av, "f:") == 'f') { exit(1); } |
| 4975 | exit(0); |
| 4976 | } |
| 4977 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4978 | if { (eval echo configure:4979: \"$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] | 4979 | then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4980 | ac_cv_func_getopt=yes |
| 4981 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4982 | echo "configure: failed program was:" >&5 |
| 4983 | cat conftest.$ac_ext >&5 |
| 4984 | rm -fr conftest* |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4985 | ac_cv_func_getopt=no |
| 4986 | fi |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4987 | rm -fr conftest* |
| 4988 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4989 | |
| 4990 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4991 | echo "$ac_t""$ac_cv_func_getopt" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4992 | test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o" |
| 4993 | |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 4994 | # check whether malloc(0) returns NULL or not |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 4995 | echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 4996 | echo "configure:4997: checking what malloc(0) returns" >&5 |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 4997 | if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then |
| 4998 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4999 | else |
| 5000 | if test "$cross_compiling" = yes; then |
| 5001 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5002 | else |
| 5003 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5004 | #line 5005 "configure" |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 5005 | #include "confdefs.h" |
| 5006 | #include <stdio.h> |
| 5007 | #ifdef HAVE_STDLIB |
| 5008 | #include <stdlib.h> |
| 5009 | #else |
| 5010 | char *malloc(), *realloc(); |
| 5011 | int *free(); |
| 5012 | #endif |
| 5013 | main() { |
| 5014 | char *p; |
| 5015 | p = malloc(0); |
| 5016 | if (p == NULL) exit(1); |
| 5017 | p = realloc(p, 0); |
| 5018 | if (p == NULL) exit(1); |
| 5019 | free(p); |
| 5020 | exit(0); |
| 5021 | } |
| 5022 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5023 | if { (eval echo configure:5024: \"$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] | 5024 | then |
| 5025 | ac_cv_malloc_zero=nonnull |
| 5026 | else |
| 5027 | echo "configure: failed program was:" >&5 |
| 5028 | cat conftest.$ac_ext >&5 |
| 5029 | rm -fr conftest* |
| 5030 | ac_cv_malloc_zero=null |
| 5031 | fi |
| 5032 | rm -fr conftest* |
| 5033 | fi |
| 5034 | |
| 5035 | fi |
| 5036 | |
| 5037 | echo "$ac_t""$ac_cv_malloc_zero" 1>&6 |
| 5038 | if test "$ac_cv_malloc_zero" = null |
| 5039 | then |
| 5040 | cat >> confdefs.h <<\EOF |
| 5041 | #define MALLOC_ZERO_RETURNS_NULL 1 |
| 5042 | EOF |
| 5043 | |
| 5044 | fi |
| 5045 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5046 | # check for wchar.h |
| 5047 | ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'` |
| 5048 | echo $ac_n "checking for wchar.h""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5049 | echo "configure:5050: checking for wchar.h" >&5 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5050 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 5051 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5052 | else |
| 5053 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5054 | #line 5055 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5055 | #include "confdefs.h" |
| 5056 | #include <wchar.h> |
| 5057 | EOF |
| 5058 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5059 | { (eval echo configure:5060: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5060 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 5061 | if test -z "$ac_err"; then |
| 5062 | rm -rf conftest* |
| 5063 | eval "ac_cv_header_$ac_safe=yes" |
| 5064 | else |
| 5065 | echo "$ac_err" >&5 |
| 5066 | echo "configure: failed program was:" >&5 |
| 5067 | cat conftest.$ac_ext >&5 |
| 5068 | rm -rf conftest* |
| 5069 | eval "ac_cv_header_$ac_safe=no" |
| 5070 | fi |
| 5071 | rm -f conftest* |
| 5072 | fi |
| 5073 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 5074 | echo "$ac_t""yes" 1>&6 |
| 5075 | cat >> confdefs.h <<\EOF |
| 5076 | #define HAVE_WCHAR_H 1 |
| 5077 | EOF |
| 5078 | wchar_h="yes" |
| 5079 | else |
| 5080 | echo "$ac_t""no" 1>&6 |
| 5081 | wchar_h="no" |
| 5082 | |
| 5083 | fi |
| 5084 | |
| 5085 | |
| 5086 | # check for usable wchar_t |
| 5087 | usable_wchar_t="unkown" |
| 5088 | echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5089 | echo "configure:5090: checking for usable wchar_t" >&5 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5090 | if test "$cross_compiling" = yes; then |
| 5091 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5092 | else |
| 5093 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5094 | #line 5095 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5095 | #include "confdefs.h" |
| 5096 | |
| 5097 | #include "wchar.h" |
| 5098 | #include "wctype.h" |
| 5099 | main() { |
| 5100 | wchar_t s; |
| 5101 | if (sizeof(s) == 2) |
| 5102 | exit(0); |
| 5103 | else |
| 5104 | exit(1); |
| 5105 | } |
| 5106 | |
| 5107 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5108 | if { (eval echo configure:5109: \"$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] | 5109 | then |
| 5110 | cat >> confdefs.h <<\EOF |
| 5111 | #define HAVE_USABLE_WCHAR_T 1 |
| 5112 | EOF |
| 5113 | usable_wchar_t="yes" |
| 5114 | else |
| 5115 | echo "configure: failed program was:" >&5 |
| 5116 | cat conftest.$ac_ext >&5 |
| 5117 | rm -fr conftest* |
| 5118 | usable_wchar_t="no" |
| 5119 | fi |
| 5120 | rm -fr conftest* |
| 5121 | fi |
| 5122 | |
| 5123 | echo "$ac_t""$usable_wchar_t" 1>&6 |
| 5124 | |
| 5125 | # check for endianness |
| 5126 | echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5127 | echo "configure:5128: checking whether byte ordering is bigendian" >&5 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5128 | if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then |
| 5129 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5130 | else |
| 5131 | ac_cv_c_bigendian=unknown |
| 5132 | # See if sys/param.h defines the BYTE_ORDER macro. |
| 5133 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5134 | #line 5135 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5135 | #include "confdefs.h" |
| 5136 | #include <sys/types.h> |
| 5137 | #include <sys/param.h> |
| 5138 | int main() { |
| 5139 | |
| 5140 | #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN |
| 5141 | bogus endian macros |
| 5142 | #endif |
| 5143 | ; return 0; } |
| 5144 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5145 | if { (eval echo configure:5146: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5146 | rm -rf conftest* |
| 5147 | # It does; now see whether it defined to BIG_ENDIAN or not. |
| 5148 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5149 | #line 5150 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5150 | #include "confdefs.h" |
| 5151 | #include <sys/types.h> |
| 5152 | #include <sys/param.h> |
| 5153 | int main() { |
| 5154 | |
| 5155 | #if BYTE_ORDER != BIG_ENDIAN |
| 5156 | not big endian |
| 5157 | #endif |
| 5158 | ; return 0; } |
| 5159 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5160 | if { (eval echo configure:5161: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5161 | rm -rf conftest* |
| 5162 | ac_cv_c_bigendian=yes |
| 5163 | else |
| 5164 | echo "configure: failed program was:" >&5 |
| 5165 | cat conftest.$ac_ext >&5 |
| 5166 | rm -rf conftest* |
| 5167 | ac_cv_c_bigendian=no |
| 5168 | fi |
| 5169 | rm -f conftest* |
| 5170 | else |
| 5171 | echo "configure: failed program was:" >&5 |
| 5172 | cat conftest.$ac_ext >&5 |
| 5173 | fi |
| 5174 | rm -f conftest* |
| 5175 | if test $ac_cv_c_bigendian = unknown; then |
| 5176 | if test "$cross_compiling" = yes; then |
| 5177 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5178 | else |
| 5179 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5180 | #line 5181 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5181 | #include "confdefs.h" |
| 5182 | main () { |
| 5183 | /* Are we little or big endian? From Harbison&Steele. */ |
| 5184 | union |
| 5185 | { |
| 5186 | long l; |
| 5187 | char c[sizeof (long)]; |
| 5188 | } u; |
| 5189 | u.l = 1; |
| 5190 | exit (u.c[sizeof (long) - 1] == 1); |
| 5191 | } |
| 5192 | EOF |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5193 | if { (eval echo configure:5194: \"$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] | 5194 | then |
| 5195 | ac_cv_c_bigendian=no |
| 5196 | else |
| 5197 | echo "configure: failed program was:" >&5 |
| 5198 | cat conftest.$ac_ext >&5 |
| 5199 | rm -fr conftest* |
| 5200 | ac_cv_c_bigendian=yes |
| 5201 | fi |
| 5202 | rm -fr conftest* |
| 5203 | fi |
| 5204 | |
| 5205 | fi |
| 5206 | fi |
| 5207 | |
| 5208 | echo "$ac_t""$ac_cv_c_bigendian" 1>&6 |
| 5209 | if test $ac_cv_c_bigendian = yes; then |
| 5210 | cat >> confdefs.h <<\EOF |
| 5211 | #define WORDS_BIGENDIAN 1 |
| 5212 | EOF |
| 5213 | |
| 5214 | fi |
| 5215 | |
| 5216 | |
| 5217 | # Check for --with-wctype-functions |
| 5218 | echo $ac_n "checking for --with-wctype-functions""... $ac_c" 1>&6 |
Guido van Rossum | 59903fe | 2000-04-24 15:12:04 +0000 | [diff] [blame^] | 5219 | echo "configure:5220: checking for --with-wctype-functions" >&5 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5220 | # Check whether --with-wctype-functions or --without-wctype-functions was given. |
| 5221 | if test "${with_wctype_functions+set}" = set; then |
| 5222 | withval="$with_wctype_functions" |
| 5223 | |
| 5224 | if test "$withval" != no |
| 5225 | then cat >> confdefs.h <<\EOF |
| 5226 | #define WANT_WCTYPE_FUNCTIONS 1 |
| 5227 | EOF |
| 5228 | echo "$ac_t""yes" 1>&6 |
| 5229 | else echo "$ac_t""no" 1>&6 |
| 5230 | fi |
| 5231 | else |
| 5232 | echo "$ac_t""no" 1>&6 |
| 5233 | fi |
| 5234 | |
| 5235 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5236 | # generate output files |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5237 | trap '' 1 2 15 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5238 | cat > confcache <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5239 | # This file is a shell script that caches the results of configure |
| 5240 | # tests run on this system so they can be shared between configure |
| 5241 | # scripts and configure runs. It is not useful on other systems. |
| 5242 | # If it contains results you don't want to keep, you may remove or edit it. |
| 5243 | # |
| 5244 | # By default, configure uses ./config.cache as the cache file, |
| 5245 | # creating it if it does not exist already. You can give configure |
| 5246 | # the --cache-file=FILE option to use a different cache file; that is |
| 5247 | # what configure does when it calls configure scripts in |
| 5248 | # subdirectories, so they share the cache. |
| 5249 | # Giving --cache-file=/dev/null disables caching, for debugging configure. |
| 5250 | # config.status only pays attention to the cache file if you give it the |
| 5251 | # --recheck option to rerun configure. |
| 5252 | # |
| 5253 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5254 | # The following way of writing the cache mishandles newlines in values, |
| 5255 | # but we know of no workaround that is simple, portable, and efficient. |
| 5256 | # So, don't put newlines in cache variables' values. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5257 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 5258 | # 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] | 5259 | (set) 2>&1 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 5260 | case `(ac_space=' '; set | grep ac_space) 2>&1` in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5261 | *ac_space=\ *) |
| 5262 | # `set' does not quote correctly, so add quotes (double-quote substitution |
| 5263 | # turns \\\\ into \\, and sed turns \\ into \). |
| 5264 | sed -n \ |
| 5265 | -e "s/'/'\\\\''/g" \ |
| 5266 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" |
| 5267 | ;; |
| 5268 | *) |
| 5269 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
| 5270 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' |
| 5271 | ;; |
| 5272 | esac >> confcache |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5273 | if cmp -s $cache_file confcache; then |
| 5274 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5275 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5276 | if test -w $cache_file; then |
| 5277 | echo "updating cache $cache_file" |
| 5278 | cat confcache > $cache_file |
| 5279 | else |
| 5280 | echo "not updating unwritable cache $cache_file" |
| 5281 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5282 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5283 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 5284 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5285 | 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] | 5286 | |
| 5287 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 5288 | # Let make expand exec_prefix. |
| 5289 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 5290 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5291 | # Any assignment to VPATH causes Sun make to only execute |
| 5292 | # the first set of double-colon rules, so remove it if not needed. |
| 5293 | # If there is a colon in the path, we need to keep it. |
| 5294 | if test "x$srcdir" = x.; then |
| 5295 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
| 5296 | fi |
| 5297 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5298 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5299 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5300 | DEFS=-DHAVE_CONFIG_H |
| 5301 | |
| 5302 | # Without the "./", some shells look in PATH for config.status. |
| 5303 | : ${CONFIG_STATUS=./config.status} |
| 5304 | |
| 5305 | echo creating $CONFIG_STATUS |
| 5306 | rm -f $CONFIG_STATUS |
| 5307 | cat > $CONFIG_STATUS <<EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5308 | #! /bin/sh |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5309 | # Generated automatically by configure. |
| 5310 | # Run this file to recreate the current configuration. |
| 5311 | # This directory was configured as follows, |
| 5312 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
| 5313 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5314 | # $0 $ac_configure_args |
| 5315 | # |
| 5316 | # Compiler output produced by configure, useful for debugging |
| 5317 | # configure, is in ./config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5318 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5319 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5320 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5321 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5322 | case "\$ac_option" in |
| 5323 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5324 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
| 5325 | 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] | 5326 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 5327 | echo "$CONFIG_STATUS generated by autoconf version 2.13" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5328 | exit 0 ;; |
| 5329 | -help | --help | --hel | --he | --h) |
| 5330 | echo "\$ac_cs_usage"; exit 0 ;; |
| 5331 | *) echo "\$ac_cs_usage"; exit 1 ;; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5332 | esac |
| 5333 | done |
| 5334 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5335 | ac_given_srcdir=$srcdir |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5336 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 5337 | trap 'rm -fr `echo "Makefile \ |
| 5338 | Objects/Makefile \ |
| 5339 | Parser/Makefile \ |
| 5340 | Python/Makefile \ |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 5341 | Modules/Makefile.pre \ |
| 5342 | Modules/Setup.thread config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5343 | EOF |
| 5344 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5345 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5346 | # Protect against being on the right side of a sed subst in config.status. |
| 5347 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; |
| 5348 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5349 | $ac_vpsub |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5350 | $extrasub |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 5351 | s%@SHELL@%$SHELL%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5352 | s%@CFLAGS@%$CFLAGS%g |
| 5353 | s%@CPPFLAGS@%$CPPFLAGS%g |
| 5354 | s%@CXXFLAGS@%$CXXFLAGS%g |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 5355 | s%@FFLAGS@%$FFLAGS%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5356 | s%@DEFS@%$DEFS%g |
| 5357 | s%@LDFLAGS@%$LDFLAGS%g |
| 5358 | s%@LIBS@%$LIBS%g |
| 5359 | s%@exec_prefix@%$exec_prefix%g |
| 5360 | s%@prefix@%$prefix%g |
| 5361 | s%@program_transform_name@%$program_transform_name%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5362 | s%@bindir@%$bindir%g |
| 5363 | s%@sbindir@%$sbindir%g |
| 5364 | s%@libexecdir@%$libexecdir%g |
| 5365 | s%@datadir@%$datadir%g |
| 5366 | s%@sysconfdir@%$sysconfdir%g |
| 5367 | s%@sharedstatedir@%$sharedstatedir%g |
| 5368 | s%@localstatedir@%$localstatedir%g |
| 5369 | s%@libdir@%$libdir%g |
| 5370 | s%@includedir@%$includedir%g |
| 5371 | s%@oldincludedir@%$oldincludedir%g |
| 5372 | s%@infodir@%$infodir%g |
| 5373 | s%@mandir@%$mandir%g |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 5374 | s%@VERSION@%$VERSION%g |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 5375 | s%@MACHDEP@%$MACHDEP%g |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 5376 | s%@SGI_ABI@%$SGI_ABI%g |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 5377 | s%@SET_CXX@%$SET_CXX%g |
| 5378 | s%@MAINOBJ@%$MAINOBJ%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5379 | s%@CC@%$CC%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 5380 | s%@MAKE_LDLIBRARY@%$MAKE_LDLIBRARY%g |
| 5381 | s%@LDLIBRARY@%$LDLIBRARY%g |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 5382 | s%@LINKCC@%$LINKCC%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5383 | s%@RANLIB@%$RANLIB%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5384 | s%@AR@%$AR%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 5385 | s%@INSTALL@%$INSTALL%g |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5386 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
| 5387 | s%@INSTALL_DATA@%$INSTALL_DATA%g |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 5388 | s%@LN@%$LN%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 5389 | s%@OPT@%$OPT%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5390 | s%@CPP@%$CPP%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 5391 | s%@LIBTOOL_CRUFT@%$LIBTOOL_CRUFT%g |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 5392 | s%@SO@%$SO%g |
| 5393 | s%@LDSHARED@%$LDSHARED%g |
| 5394 | s%@CCSHARED@%$CCSHARED%g |
| 5395 | s%@LINKFORSHARED@%$LINKFORSHARED%g |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 5396 | s%@USE_THREAD_MODULE@%$USE_THREAD_MODULE%g |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 5397 | s%@LDLAST@%$LDLAST%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5398 | s%@DLINCLDIR@%$DLINCLDIR%g |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 5399 | s%@DYNLOADFILE@%$DYNLOADFILE%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5400 | s%@LIBOBJS@%$LIBOBJS%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5401 | s%@HAVE_GETHOSTBYNAME_R_6_ARG@%$HAVE_GETHOSTBYNAME_R_6_ARG%g |
| 5402 | s%@HAVE_GETHOSTBYNAME_R_5_ARG@%$HAVE_GETHOSTBYNAME_R_5_ARG%g |
| 5403 | 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] | 5404 | s%@HAVE_GETHOSTBYNAME_R@%$HAVE_GETHOSTBYNAME_R%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5405 | s%@HAVE_GETHOSTBYNAME@%$HAVE_GETHOSTBYNAME%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5406 | s%@LIBM@%$LIBM%g |
| 5407 | s%@LIBC@%$LIBC%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5408 | |
| 5409 | CEOF |
| 5410 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5411 | |
| 5412 | cat >> $CONFIG_STATUS <<\EOF |
| 5413 | |
| 5414 | # Split the substitutions into bite-sized pieces for seds with |
| 5415 | # small command number limits, like on Digital OSF/1 and HP-UX. |
| 5416 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. |
| 5417 | ac_file=1 # Number of current file. |
| 5418 | ac_beg=1 # First line for current file. |
| 5419 | ac_end=$ac_max_sed_cmds # Line after last line for current file. |
| 5420 | ac_more_lines=: |
| 5421 | ac_sed_cmds="" |
| 5422 | while $ac_more_lines; do |
| 5423 | if test $ac_beg -gt 1; then |
| 5424 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file |
| 5425 | else |
| 5426 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file |
| 5427 | fi |
| 5428 | if test ! -s conftest.s$ac_file; then |
| 5429 | ac_more_lines=false |
| 5430 | rm -f conftest.s$ac_file |
| 5431 | else |
| 5432 | if test -z "$ac_sed_cmds"; then |
| 5433 | ac_sed_cmds="sed -f conftest.s$ac_file" |
| 5434 | else |
| 5435 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" |
| 5436 | fi |
| 5437 | ac_file=`expr $ac_file + 1` |
| 5438 | ac_beg=$ac_end |
| 5439 | ac_end=`expr $ac_end + $ac_max_sed_cmds` |
| 5440 | fi |
| 5441 | done |
| 5442 | if test -z "$ac_sed_cmds"; then |
| 5443 | ac_sed_cmds=cat |
| 5444 | fi |
| 5445 | EOF |
| 5446 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5447 | cat >> $CONFIG_STATUS <<EOF |
| 5448 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 5449 | CONFIG_FILES=\${CONFIG_FILES-"Makefile \ |
| 5450 | Objects/Makefile \ |
| 5451 | Parser/Makefile \ |
| 5452 | Python/Makefile \ |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 5453 | Modules/Makefile.pre \ |
| 5454 | Modules/Setup.thread"} |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5455 | EOF |
| 5456 | cat >> $CONFIG_STATUS <<\EOF |
| 5457 | 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] | 5458 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5459 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5460 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5461 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 5462 | *) ac_file_in="${ac_file}.in" ;; |
| 5463 | esac |
| 5464 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5465 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5466 | |
| 5467 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 5468 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 5469 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 5470 | # The file is in a subdirectory. |
| 5471 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5472 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5473 | # A "../" for each directory in $ac_dir_suffix. |
| 5474 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
| 5475 | else |
| 5476 | ac_dir_suffix= ac_dots= |
| 5477 | fi |
| 5478 | |
| 5479 | case "$ac_given_srcdir" in |
| 5480 | .) srcdir=. |
| 5481 | if test -z "$ac_dots"; then top_srcdir=. |
| 5482 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; |
| 5483 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; |
| 5484 | *) # Relative path. |
| 5485 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
| 5486 | top_srcdir="$ac_dots$ac_given_srcdir" ;; |
| 5487 | esac |
| 5488 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5489 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5490 | echo creating "$ac_file" |
| 5491 | rm -f "$ac_file" |
| 5492 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." |
| 5493 | case "$ac_file" in |
| 5494 | *Makefile*) ac_comsub="1i\\ |
| 5495 | # $configure_input" ;; |
| 5496 | *) ac_comsub= ;; |
| 5497 | esac |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5498 | |
| 5499 | 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] | 5500 | sed -e "$ac_comsub |
| 5501 | s%@configure_input@%$configure_input%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5502 | s%@srcdir@%$srcdir%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5503 | s%@top_srcdir@%$top_srcdir%g |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5504 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5505 | fi; done |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5506 | rm -f conftest.s* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5507 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5508 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
| 5509 | # 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] | 5510 | # |
| 5511 | # ac_d sets the value in "#define NAME VALUE" lines. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5512 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
| 5513 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5514 | ac_dC='\3' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5515 | ac_dD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5516 | # 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] | 5517 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 5518 | ac_uB='\([ ]\)%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5519 | ac_uC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5520 | ac_uD='\4%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5521 | # 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] | 5522 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 5523 | ac_eB='$%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5524 | ac_eC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5525 | ac_eD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5526 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5527 | if test "${CONFIG_HEADERS+set}" != set; then |
| 5528 | EOF |
| 5529 | cat >> $CONFIG_STATUS <<EOF |
| 5530 | CONFIG_HEADERS="config.h" |
| 5531 | EOF |
| 5532 | cat >> $CONFIG_STATUS <<\EOF |
| 5533 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5534 | 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] | 5535 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5536 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5537 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5538 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 5539 | *) ac_file_in="${ac_file}.in" ;; |
| 5540 | esac |
| 5541 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5542 | echo creating $ac_file |
| 5543 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5544 | rm -f conftest.frag conftest.in conftest.out |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5545 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
| 5546 | cat $ac_file_inputs > conftest.in |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5547 | |
| 5548 | EOF |
| 5549 | |
| 5550 | # Transform confdefs.h into a sed script conftest.vals that substitutes |
| 5551 | # 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] | 5552 | # 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] | 5553 | # Protect against being in an unquoted here document in config.status. |
| 5554 | rm -f conftest.vals |
| 5555 | cat > conftest.hdr <<\EOF |
| 5556 | s/[\\&%]/\\&/g |
| 5557 | s%[\\$`]%\\&%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5558 | 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] | 5559 | s%ac_d%ac_u%gp |
| 5560 | s%ac_u%ac_e%gp |
| 5561 | EOF |
| 5562 | sed -n -f conftest.hdr confdefs.h > conftest.vals |
| 5563 | rm -f conftest.hdr |
| 5564 | |
| 5565 | # This sed command replaces #undef with comments. This is necessary, for |
| 5566 | # example, in the case of _POSIX_SOURCE, which is predefined and required |
| 5567 | # on some systems where configure will not decide to define it. |
| 5568 | cat >> conftest.vals <<\EOF |
| 5569 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% |
| 5570 | EOF |
| 5571 | |
| 5572 | # Break up conftest.vals because some shells have a limit on |
| 5573 | # 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] | 5574 | |
| 5575 | rm -f conftest.tail |
| 5576 | while : |
| 5577 | do |
| 5578 | ac_lines=`grep -c . conftest.vals` |
| 5579 | # grep -c gives empty output for an empty file on some AIX systems. |
| 5580 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi |
| 5581 | # Write a limited-size here document to conftest.frag. |
| 5582 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS |
| 5583 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS |
| 5584 | echo 'CEOF |
| 5585 | sed -f conftest.frag conftest.in > conftest.out |
| 5586 | rm -f conftest.in |
| 5587 | mv conftest.out conftest.in |
| 5588 | ' >> $CONFIG_STATUS |
| 5589 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
| 5590 | rm -f conftest.vals |
| 5591 | mv conftest.tail conftest.vals |
| 5592 | done |
| 5593 | rm -f conftest.vals |
| 5594 | |
| 5595 | cat >> $CONFIG_STATUS <<\EOF |
| 5596 | rm -f conftest.frag conftest.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5597 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5598 | cat conftest.in >> conftest.h |
| 5599 | rm -f conftest.in |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5600 | if cmp -s $ac_file conftest.h 2>/dev/null; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5601 | echo "$ac_file is unchanged" |
| 5602 | rm -f conftest.h |
| 5603 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5604 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 5605 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 5606 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 5607 | # The file is in a subdirectory. |
| 5608 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
| 5609 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5610 | rm -f $ac_file |
| 5611 | mv conftest.h $ac_file |
| 5612 | fi |
| 5613 | fi; done |
| 5614 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5615 | EOF |
| 5616 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5617 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5618 | EOF |
| 5619 | cat >> $CONFIG_STATUS <<\EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5620 | |
| 5621 | exit 0 |
| 5622 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5623 | chmod +x $CONFIG_STATUS |
| 5624 | rm -fr confdefs* $ac_clean_files |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5625 | 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] | 5626 | |