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 | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3 | # From configure.in Revision: 1.117 |
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 | |
| 562 | VERSION=1.5 |
| 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 | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1961 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1962 | # Sizes of various common basic types |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1963 | echo $ac_n "checking size of int""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1964 | echo "configure:1965: checking size of int" >&5 |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1965 | if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then |
| 1966 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1967 | else |
| 1968 | if test "$cross_compiling" = yes; then |
| 1969 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1970 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1971 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1972 | #line 1973 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1973 | #include "confdefs.h" |
| 1974 | #include <stdio.h> |
| 1975 | main() |
| 1976 | { |
| 1977 | FILE *f=fopen("conftestval", "w"); |
| 1978 | if (!f) exit(1); |
| 1979 | fprintf(f, "%d\n", sizeof(int)); |
| 1980 | exit(0); |
| 1981 | } |
| 1982 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1983 | if { (eval echo configure:1984: \"$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] | 1984 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1985 | ac_cv_sizeof_int=`cat conftestval` |
| 1986 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1987 | echo "configure: failed program was:" >&5 |
| 1988 | cat conftest.$ac_ext >&5 |
| 1989 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1990 | ac_cv_sizeof_int=0 |
| 1991 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1992 | rm -fr conftest* |
| 1993 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1994 | |
| 1995 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1996 | echo "$ac_t""$ac_cv_sizeof_int" 1>&6 |
| 1997 | cat >> confdefs.h <<EOF |
| 1998 | #define SIZEOF_INT $ac_cv_sizeof_int |
| 1999 | EOF |
| 2000 | |
| 2001 | |
| 2002 | echo $ac_n "checking size of long""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2003 | echo "configure:2004: checking size of long" >&5 |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2004 | if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then |
| 2005 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2006 | else |
| 2007 | if test "$cross_compiling" = yes; then |
| 2008 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2009 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2010 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2011 | #line 2012 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2012 | #include "confdefs.h" |
| 2013 | #include <stdio.h> |
| 2014 | main() |
| 2015 | { |
| 2016 | FILE *f=fopen("conftestval", "w"); |
| 2017 | if (!f) exit(1); |
| 2018 | fprintf(f, "%d\n", sizeof(long)); |
| 2019 | exit(0); |
| 2020 | } |
| 2021 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2022 | if { (eval echo configure:2023: \"$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] | 2023 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2024 | ac_cv_sizeof_long=`cat conftestval` |
| 2025 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2026 | echo "configure: failed program was:" >&5 |
| 2027 | cat conftest.$ac_ext >&5 |
| 2028 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2029 | ac_cv_sizeof_long=0 |
| 2030 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2031 | rm -fr conftest* |
| 2032 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2033 | |
| 2034 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2035 | echo "$ac_t""$ac_cv_sizeof_long" 1>&6 |
| 2036 | cat >> confdefs.h <<EOF |
| 2037 | #define SIZEOF_LONG $ac_cv_sizeof_long |
| 2038 | EOF |
| 2039 | |
| 2040 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2041 | echo $ac_n "checking size of void *""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2042 | echo "configure:2043: checking size of void *" >&5 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2043 | if eval "test \"`echo '$''{'ac_cv_sizeof_void_p'+set}'`\" = set"; then |
| 2044 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2045 | else |
| 2046 | if test "$cross_compiling" = yes; then |
| 2047 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2048 | else |
| 2049 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2050 | #line 2051 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2051 | #include "confdefs.h" |
| 2052 | #include <stdio.h> |
| 2053 | main() |
| 2054 | { |
| 2055 | FILE *f=fopen("conftestval", "w"); |
| 2056 | if (!f) exit(1); |
| 2057 | fprintf(f, "%d\n", sizeof(void *)); |
| 2058 | exit(0); |
| 2059 | } |
| 2060 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2061 | if { (eval echo configure:2062: \"$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] | 2062 | then |
| 2063 | ac_cv_sizeof_void_p=`cat conftestval` |
| 2064 | else |
| 2065 | echo "configure: failed program was:" >&5 |
| 2066 | cat conftest.$ac_ext >&5 |
| 2067 | rm -fr conftest* |
| 2068 | ac_cv_sizeof_void_p=0 |
| 2069 | fi |
| 2070 | rm -fr conftest* |
| 2071 | fi |
| 2072 | |
| 2073 | fi |
| 2074 | echo "$ac_t""$ac_cv_sizeof_void_p" 1>&6 |
| 2075 | cat >> confdefs.h <<EOF |
| 2076 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
| 2077 | EOF |
| 2078 | |
| 2079 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2080 | echo $ac_n "checking size of char""... $ac_c" 1>&6 |
| 2081 | echo "configure:2082: checking size of char" >&5 |
| 2082 | if eval "test \"`echo '$''{'ac_cv_sizeof_char'+set}'`\" = set"; then |
| 2083 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2084 | else |
| 2085 | if test "$cross_compiling" = yes; then |
| 2086 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2087 | else |
| 2088 | cat > conftest.$ac_ext <<EOF |
| 2089 | #line 2090 "configure" |
| 2090 | #include "confdefs.h" |
| 2091 | #include <stdio.h> |
| 2092 | main() |
| 2093 | { |
| 2094 | FILE *f=fopen("conftestval", "w"); |
| 2095 | if (!f) exit(1); |
| 2096 | fprintf(f, "%d\n", sizeof(char)); |
| 2097 | exit(0); |
| 2098 | } |
| 2099 | EOF |
| 2100 | if { (eval echo configure:2101: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 2101 | then |
| 2102 | ac_cv_sizeof_char=`cat conftestval` |
| 2103 | else |
| 2104 | echo "configure: failed program was:" >&5 |
| 2105 | cat conftest.$ac_ext >&5 |
| 2106 | rm -fr conftest* |
| 2107 | ac_cv_sizeof_char=0 |
| 2108 | fi |
| 2109 | rm -fr conftest* |
| 2110 | fi |
| 2111 | |
| 2112 | fi |
| 2113 | echo "$ac_t""$ac_cv_sizeof_char" 1>&6 |
| 2114 | cat >> confdefs.h <<EOF |
| 2115 | #define SIZEOF_CHAR $ac_cv_sizeof_char |
| 2116 | EOF |
| 2117 | |
| 2118 | |
| 2119 | echo $ac_n "checking size of short""... $ac_c" 1>&6 |
| 2120 | echo "configure:2121: checking size of short" >&5 |
| 2121 | if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then |
| 2122 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2123 | else |
| 2124 | if test "$cross_compiling" = yes; then |
| 2125 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2126 | else |
| 2127 | cat > conftest.$ac_ext <<EOF |
| 2128 | #line 2129 "configure" |
| 2129 | #include "confdefs.h" |
| 2130 | #include <stdio.h> |
| 2131 | main() |
| 2132 | { |
| 2133 | FILE *f=fopen("conftestval", "w"); |
| 2134 | if (!f) exit(1); |
| 2135 | fprintf(f, "%d\n", sizeof(short)); |
| 2136 | exit(0); |
| 2137 | } |
| 2138 | EOF |
| 2139 | if { (eval echo configure:2140: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 2140 | then |
| 2141 | ac_cv_sizeof_short=`cat conftestval` |
| 2142 | else |
| 2143 | echo "configure: failed program was:" >&5 |
| 2144 | cat conftest.$ac_ext >&5 |
| 2145 | rm -fr conftest* |
| 2146 | ac_cv_sizeof_short=0 |
| 2147 | fi |
| 2148 | rm -fr conftest* |
| 2149 | fi |
| 2150 | |
| 2151 | fi |
| 2152 | echo "$ac_t""$ac_cv_sizeof_short" 1>&6 |
| 2153 | cat >> confdefs.h <<EOF |
| 2154 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
| 2155 | EOF |
| 2156 | |
| 2157 | |
| 2158 | echo $ac_n "checking size of float""... $ac_c" 1>&6 |
| 2159 | echo "configure:2160: checking size of float" >&5 |
| 2160 | if eval "test \"`echo '$''{'ac_cv_sizeof_float'+set}'`\" = set"; then |
| 2161 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2162 | else |
| 2163 | if test "$cross_compiling" = yes; then |
| 2164 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2165 | else |
| 2166 | cat > conftest.$ac_ext <<EOF |
| 2167 | #line 2168 "configure" |
| 2168 | #include "confdefs.h" |
| 2169 | #include <stdio.h> |
| 2170 | main() |
| 2171 | { |
| 2172 | FILE *f=fopen("conftestval", "w"); |
| 2173 | if (!f) exit(1); |
| 2174 | fprintf(f, "%d\n", sizeof(float)); |
| 2175 | exit(0); |
| 2176 | } |
| 2177 | EOF |
| 2178 | if { (eval echo configure:2179: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 2179 | then |
| 2180 | ac_cv_sizeof_float=`cat conftestval` |
| 2181 | else |
| 2182 | echo "configure: failed program was:" >&5 |
| 2183 | cat conftest.$ac_ext >&5 |
| 2184 | rm -fr conftest* |
| 2185 | ac_cv_sizeof_float=0 |
| 2186 | fi |
| 2187 | rm -fr conftest* |
| 2188 | fi |
| 2189 | |
| 2190 | fi |
| 2191 | echo "$ac_t""$ac_cv_sizeof_float" 1>&6 |
| 2192 | cat >> confdefs.h <<EOF |
| 2193 | #define SIZEOF_FLOAT $ac_cv_sizeof_float |
| 2194 | EOF |
| 2195 | |
| 2196 | |
| 2197 | echo $ac_n "checking size of double""... $ac_c" 1>&6 |
| 2198 | echo "configure:2199: checking size of double" >&5 |
| 2199 | if eval "test \"`echo '$''{'ac_cv_sizeof_double'+set}'`\" = set"; then |
| 2200 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2201 | else |
| 2202 | if test "$cross_compiling" = yes; then |
| 2203 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2204 | else |
| 2205 | cat > conftest.$ac_ext <<EOF |
| 2206 | #line 2207 "configure" |
| 2207 | #include "confdefs.h" |
| 2208 | #include <stdio.h> |
| 2209 | main() |
| 2210 | { |
| 2211 | FILE *f=fopen("conftestval", "w"); |
| 2212 | if (!f) exit(1); |
| 2213 | fprintf(f, "%d\n", sizeof(double)); |
| 2214 | exit(0); |
| 2215 | } |
| 2216 | EOF |
| 2217 | if { (eval echo configure:2218: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 2218 | then |
| 2219 | ac_cv_sizeof_double=`cat conftestval` |
| 2220 | else |
| 2221 | echo "configure: failed program was:" >&5 |
| 2222 | cat conftest.$ac_ext >&5 |
| 2223 | rm -fr conftest* |
| 2224 | ac_cv_sizeof_double=0 |
| 2225 | fi |
| 2226 | rm -fr conftest* |
| 2227 | fi |
| 2228 | |
| 2229 | fi |
| 2230 | echo "$ac_t""$ac_cv_sizeof_double" 1>&6 |
| 2231 | cat >> confdefs.h <<EOF |
| 2232 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
| 2233 | EOF |
| 2234 | |
| 2235 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2236 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2237 | echo $ac_n "checking for long long support""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2238 | echo "configure:2239: checking for long long support" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2239 | have_long_long=no |
| 2240 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2241 | #line 2242 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2242 | #include "confdefs.h" |
| 2243 | |
| 2244 | int main() { |
| 2245 | long long x; x = (long long)0; |
| 2246 | ; return 0; } |
| 2247 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2248 | if { (eval echo configure:2249: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2249 | rm -rf conftest* |
| 2250 | cat >> confdefs.h <<\EOF |
| 2251 | #define HAVE_LONG_LONG 1 |
| 2252 | EOF |
| 2253 | have_long_long=yes |
| 2254 | else |
| 2255 | echo "configure: failed program was:" >&5 |
| 2256 | cat conftest.$ac_ext >&5 |
| 2257 | fi |
| 2258 | rm -f conftest* |
| 2259 | echo "$ac_t""$have_long_long" 1>&6 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2260 | if test "$have_long_long" = yes ; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2261 | echo $ac_n "checking size of long long""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2262 | echo "configure:2263: checking size of long long" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2263 | if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then |
| 2264 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2265 | else |
| 2266 | if test "$cross_compiling" = yes; then |
| 2267 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2268 | else |
| 2269 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2270 | #line 2271 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2271 | #include "confdefs.h" |
| 2272 | #include <stdio.h> |
| 2273 | main() |
| 2274 | { |
| 2275 | FILE *f=fopen("conftestval", "w"); |
| 2276 | if (!f) exit(1); |
| 2277 | fprintf(f, "%d\n", sizeof(long long)); |
| 2278 | exit(0); |
| 2279 | } |
| 2280 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2281 | if { (eval echo configure:2282: \"$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] | 2282 | then |
| 2283 | ac_cv_sizeof_long_long=`cat conftestval` |
| 2284 | else |
| 2285 | echo "configure: failed program was:" >&5 |
| 2286 | cat conftest.$ac_ext >&5 |
| 2287 | rm -fr conftest* |
| 2288 | ac_cv_sizeof_long_long=0 |
| 2289 | fi |
| 2290 | rm -fr conftest* |
| 2291 | fi |
| 2292 | |
| 2293 | fi |
| 2294 | echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6 |
| 2295 | cat >> confdefs.h <<EOF |
| 2296 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
| 2297 | EOF |
| 2298 | |
| 2299 | |
| 2300 | fi |
| 2301 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2302 | # Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>. |
| 2303 | echo $ac_n "checking size of off_t""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2304 | echo "configure:2305: checking size of off_t" >&5 |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2305 | if eval "test \"`echo '$''{'ac_cv_sizeof_off_t'+set}'`\" = set"; then |
| 2306 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2307 | else |
| 2308 | if test "$cross_compiling" = yes; then |
| 2309 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2310 | else |
| 2311 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2312 | #line 2313 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2313 | #include "confdefs.h" |
| 2314 | #include <stdio.h> |
| 2315 | #include <sys/types.h> |
| 2316 | main() |
| 2317 | { |
| 2318 | FILE *f=fopen("conftestval", "w"); |
| 2319 | if (!f) exit(1); |
| 2320 | fprintf(f, "%d\n", sizeof(off_t)); |
| 2321 | exit(0); |
| 2322 | } |
| 2323 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2324 | if { (eval echo configure:2325: \"$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] | 2325 | then |
| 2326 | ac_cv_sizeof_off_t=`cat conftestval` |
| 2327 | else |
| 2328 | echo "configure: failed program was:" >&5 |
| 2329 | cat conftest.$ac_ext >&5 |
| 2330 | rm -fr conftest* |
| 2331 | ac_cv_sizeof_off_t=0 |
| 2332 | fi |
| 2333 | rm -fr conftest* |
| 2334 | fi |
| 2335 | |
| 2336 | |
| 2337 | fi |
| 2338 | |
| 2339 | echo "$ac_t""$ac_cv_sizeof_off_t" 1>&6 |
| 2340 | cat >> confdefs.h <<EOF |
| 2341 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
| 2342 | EOF |
| 2343 | |
| 2344 | |
| 2345 | echo $ac_n "checking whether to enable large file support""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2346 | echo "configure:2347: checking whether to enable large file support" >&5 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2347 | if test "$have_long_long" = yes -a \ |
| 2348 | "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \ |
| 2349 | "$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] | 2350 | cat >> confdefs.h <<\EOF |
| 2351 | #define HAVE_LARGEFILE_SUPPORT 1 |
| 2352 | EOF |
| 2353 | |
| 2354 | echo "$ac_t""yes" 1>&6 |
| 2355 | else |
| 2356 | echo "$ac_t""no" 1>&6 |
| 2357 | fi |
| 2358 | |
| 2359 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2360 | # Minor variations in building a framework between NextStep versions 4 and 5 |
| 2361 | |
| 2362 | case $ac_sys_system/$ac_sys_release in |
| 2363 | next/4*) |
| 2364 | ns_undef_sym='__environ' |
| 2365 | LIBTOOL_CRUFT="-U $ns_undef_sym" ;; |
| 2366 | next/5*) |
| 2367 | ns_undef_sym='_environ' |
| 2368 | LIBTOOL_CRUFT="-lcc_dynamic -U $ns_undef_sym" ;; |
| 2369 | esac |
| 2370 | |
| 2371 | echo $ac_n "checking for --with-next-framework""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2372 | echo "configure:2373: checking for --with-next-framework" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2373 | if test "$with_next_framework" |
| 2374 | then |
| 2375 | OPT="$OPT -fno-common" |
| 2376 | # -U __environ is needed since bundles don't have access |
| 2377 | # to crt0 when built but will always be linked against it |
| 2378 | LDFLAGS="$LDFLAGS -Wl,-U,$ns_undef_sym" |
| 2379 | cat >> confdefs.h <<\EOF |
| 2380 | #define WITH_NEXT_FRAMEWORK 1 |
| 2381 | EOF |
| 2382 | |
| 2383 | echo "$ac_t""yes" 1>&6 |
| 2384 | else |
| 2385 | echo "$ac_t""no" 1>&6 |
| 2386 | fi |
| 2387 | |
| 2388 | echo $ac_n "checking for --with-dyld""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2389 | echo "configure:2390: checking for --with-dyld" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2390 | if test "$with_next_framework" -o "$with_dyld" |
| 2391 | then |
| 2392 | if test "$with_dyld" |
| 2393 | then |
| 2394 | echo "$ac_t""yes" 1>&6 |
| 2395 | else |
| 2396 | echo "$ac_t""required for framework build" 1>&6 |
| 2397 | fi |
| 2398 | cat >> confdefs.h <<\EOF |
| 2399 | #define WITH_DYLD 1 |
| 2400 | EOF |
| 2401 | |
| 2402 | ns_dyld='set' |
| 2403 | else |
| 2404 | echo "$ac_t""no" 1>&6 |
| 2405 | fi |
| 2406 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2407 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2408 | |
| 2409 | |
| 2410 | |
| 2411 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2412 | # SO is the extension of shared libraries `(including the dot!) |
| 2413 | # -- usually .so, .sl on HP-UX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2414 | echo $ac_n "checking SO""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2415 | echo "configure:2416: checking SO" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2416 | if test -z "$SO" |
| 2417 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2418 | case $ac_sys_system in |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2419 | hp*|HP*) SO=.sl;; |
| 2420 | *) SO=.so;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2421 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2422 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2423 | echo "$ac_t""$SO" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2424 | # LDSHARED is the ld *command* used to create shared library |
| 2425 | # -- "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] | 2426 | # (Shared libraries in this instance are shared modules to be loaded into |
| 2427 | # Python, as opposed to building Python itself as a shared library.) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2428 | echo $ac_n "checking LDSHARED""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2429 | echo "configure:2430: checking LDSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2430 | if test -z "$LDSHARED" |
| 2431 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2432 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 45140f9 | 1997-08-29 18:44:06 +0000 | [diff] [blame] | 2433 | AIX*) LDSHARED="\$(srcdir)/ld_so_aix \$(CC)";; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2434 | BeOS*) LDSHARED="\$(srcdir)/../BeOS/linkmodule -L.. -lpython\$(VERSION)";; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2435 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 2436 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2437 | SunOS/4*) LDSHARED="ld";; |
| 2438 | SunOS/5*) LDSHARED="ld -G";; |
| 2439 | hp*|HP*) LDSHARED="ld -b";; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2440 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
| 2441 | DYNIX/ptx*) LDSHARED="ld -G";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2442 | next/*) |
| 2443 | if test "$ns_dyld" |
| 2444 | then LDSHARED='$(CC) $(LDFLAGS) -bundle -prebind' |
| 2445 | else LDSHARED='$(CC) $(CFLAGS) -nostdlib -r'; |
| 2446 | fi |
| 2447 | if test "$with_next_framework" ; then |
| 2448 | LDSHARED="$LDSHARED \$(LDLIBRARY)" |
| 2449 | fi ;; |
Guido van Rossum | 81652ab | 1996-07-21 02:53:27 +0000 | [diff] [blame] | 2450 | Linux*) LDSHARED="gcc -shared";; |
Guido van Rossum | 3c4bb80 | 1997-12-18 23:55:32 +0000 | [diff] [blame] | 2451 | dgux*) LDSHARED="ld -G";; |
Guido van Rossum | 458e7fa | 1999-09-17 15:40:40 +0000 | [diff] [blame] | 2452 | BSD/OS*/4*) LDSHARED="gcc -shared";; |
Guido van Rossum | a8acf72 | 1999-04-27 22:06:08 +0000 | [diff] [blame] | 2453 | FreeBSD*/[34]*) LDSHARED="gcc -shared";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2454 | FreeBSD*|OpenBSD*) LDSHARED="ld -Bshareable";; |
| 2455 | NetBSD*) |
| 2456 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 2457 | then |
| 2458 | LDSHARED="cc -shared" |
| 2459 | else |
| 2460 | LDSHARED="ld -Bshareable" |
| 2461 | fi;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2462 | SCO_SV*) LDSHARED="cc -G -KPIC -Ki486 -belf -Wl,-Bexport";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2463 | *) LDSHARED="ld";; |
| 2464 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2465 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2466 | echo "$ac_t""$LDSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2467 | # 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] | 2468 | # library (module) -- this is only needed for a few systems |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2469 | echo $ac_n "checking CCSHARED""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2470 | echo "configure:2471: checking CCSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2471 | if test -z "$CCSHARED" |
| 2472 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2473 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 2474 | hp*|HP*) if test "$GCC" = yes; |
| 2475 | then CCSHARED="-fpic"; |
| 2476 | else CCSHARED="+z"; |
| 2477 | fi;; |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2478 | Linux*) CCSHARED="-fpic";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2479 | BSD/OS*/4*) CCSHARED="-fpic";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2480 | FreeBSD*|OpenBSD*) CCSHARED="-fpic";; |
| 2481 | NetBSD*) CCSHARED="-fPIC";; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2482 | SCO_SV*) CCSHARED="-KPIC -dy -Bdynamic";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2483 | IRIX*/6*) case $CC in |
| 2484 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 2485 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2486 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2487 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2488 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2489 | echo "$ac_t""$CCSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2490 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2491 | # the python executable -- this is only needed for a few systems |
| 2492 | echo $ac_n "checking LINKFORSHARED""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2493 | echo "configure:2494: checking LINKFORSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2494 | if test -z "$LINKFORSHARED" |
| 2495 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2496 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 69f6580 | 1998-03-03 21:47:00 +0000 | [diff] [blame] | 2497 | AIX*) LINKFORSHARED='-Wl,-bE:python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2498 | hp*|HP*) |
Guido van Rossum | 304dd2d | 1997-10-20 23:10:56 +0000 | [diff] [blame] | 2499 | LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2500 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | a8acf72 | 1999-04-27 22:06:08 +0000 | [diff] [blame] | 2501 | FreeBSD/[34]*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 2d9feed | 1997-11-24 17:36:21 +0000 | [diff] [blame] | 2502 | Linux*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2503 | # -u libsys_s pulls in all symbols in libsys |
| 2504 | next/2*|next/3*) LINKFORSHARED="-u libsys_s";; |
| 2505 | # -u __dummy makes the linker aware of the objc runtime |
| 2506 | # in System.framework; otherwise, __objcInit (referenced in |
| 2507 | # crt1.o) gets erroneously defined as common, which breaks dynamic |
| 2508 | # loading of any modules which reference it in System.framework |
| 2509 | next/4*|next/5*) LINKFORSHARED="-u __dummy -framework System" ;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2510 | SCO_SV*) LINKFORSHARED="-Bdynamic -dy -Wl,-Bexport";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2511 | NetBSD*) |
| 2512 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 2513 | then |
| 2514 | LINKFORSHARED="-Wl,--export-dynamic" |
| 2515 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2516 | SunOS/5*) case $CC in |
| 2517 | *gcc*) |
Guido van Rossum | ff48418 | 2000-02-03 13:50:24 +0000 | [diff] [blame] | 2518 | if $CC -Xlinker -V 2>&1 | grep BFD >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 2519 | then |
| 2520 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2521 | fi;; |
| 2522 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2523 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2524 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2525 | echo "$ac_t""$LINKFORSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2526 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2527 | # checks for libraries |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2528 | echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2529 | echo "configure:2530: checking for dlopen in -ldl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2530 | ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2531 | 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] | 2532 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2533 | else |
| 2534 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2535 | LIBS="-ldl $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2536 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2537 | #line 2538 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2538 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2539 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2540 | /* We use char because int might match the return type of a gcc2 |
| 2541 | builtin and then its argument prototype would still apply. */ |
| 2542 | char dlopen(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2543 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2544 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2545 | dlopen() |
| 2546 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2547 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2548 | if { (eval echo configure:2549: \"$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] | 2549 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2550 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2551 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2552 | echo "configure: failed program was:" >&5 |
| 2553 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2554 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2555 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2556 | fi |
| 2557 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2558 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2559 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2560 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2561 | 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] | 2562 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2563 | ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 2564 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2565 | cat >> confdefs.h <<EOF |
| 2566 | #define $ac_tr_lib 1 |
| 2567 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2568 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2569 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2570 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2571 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2572 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2573 | fi |
| 2574 | # Dynamic linking for SunOS/Solaris and SYSV |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2575 | echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2576 | echo "configure:2577: checking for shl_load in -ldld" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2577 | ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2578 | 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] | 2579 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2580 | else |
| 2581 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2582 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2583 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2584 | #line 2585 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2585 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2586 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2587 | /* We use char because int might match the return type of a gcc2 |
| 2588 | builtin and then its argument prototype would still apply. */ |
| 2589 | char shl_load(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2590 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2591 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2592 | shl_load() |
| 2593 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2594 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2595 | if { (eval echo configure:2596: \"$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] | 2596 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2597 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2598 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2599 | echo "configure: failed program was:" >&5 |
| 2600 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2601 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2602 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2603 | fi |
| 2604 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2605 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2606 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2607 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2608 | 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] | 2609 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2610 | ac_tr_lib=HAVE_LIB`echo dld | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 2611 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2612 | cat >> confdefs.h <<EOF |
| 2613 | #define $ac_tr_lib 1 |
| 2614 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2615 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2616 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2617 | |
| 2618 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2619 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2620 | fi |
| 2621 | # Dynamic linking for HP-UX |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 2622 | |
| 2623 | # checks for system dependent C++ extensions support |
| 2624 | case "$ac_sys_system" in |
| 2625 | AIX*) echo $ac_n "checking for genuine AIX C++ extensions support""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2626 | echo "configure:2627: checking for genuine AIX C++ extensions support" >&5 |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 2627 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2628 | #line 2629 "configure" |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 2629 | #include "confdefs.h" |
| 2630 | #include "/usr/lpp/xlC/include/load.h" |
| 2631 | int main() { |
| 2632 | loadAndInit("", 0, "") |
| 2633 | ; return 0; } |
| 2634 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2635 | if { (eval echo configure:2636: \"$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] | 2636 | rm -rf conftest* |
| 2637 | cat >> confdefs.h <<\EOF |
| 2638 | #define AIX_GENUINE_CPLUSPLUS 1 |
| 2639 | EOF |
| 2640 | |
| 2641 | echo "$ac_t""yes" 1>&6 |
| 2642 | else |
| 2643 | echo "configure: failed program was:" >&5 |
| 2644 | cat conftest.$ac_ext >&5 |
| 2645 | rm -rf conftest* |
| 2646 | echo "$ac_t""no" 1>&6 |
| 2647 | fi |
| 2648 | rm -f conftest*;; |
| 2649 | *) ;; |
| 2650 | esac |
| 2651 | |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 2652 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
| 2653 | # However on SGI IRIX, these exist but are broken. |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2654 | # BeOS' sockets are stashed in libnet. |
| 2655 | case "$ac_sys_system" in |
| 2656 | IRIX*) ;; |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 2657 | *) |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2658 | echo $ac_n "checking for t_open in -lnsl""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2659 | echo "configure:2660: checking for t_open in -lnsl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2660 | ac_lib_var=`echo nsl'_'t_open | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2661 | 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] | 2662 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2663 | else |
| 2664 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2665 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2666 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2667 | #line 2668 "configure" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2668 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2669 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2670 | /* We use char because int might match the return type of a gcc2 |
| 2671 | builtin and then its argument prototype would still apply. */ |
| 2672 | char t_open(); |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2673 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2674 | int main() { |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 2675 | t_open() |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2676 | ; return 0; } |
| 2677 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2678 | if { (eval echo configure:2679: \"$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] | 2679 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2680 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2681 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2682 | echo "configure: failed program was:" >&5 |
| 2683 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2684 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2685 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2686 | fi |
| 2687 | rm -f conftest* |
| 2688 | LIBS="$ac_save_LIBS" |
| 2689 | |
| 2690 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2691 | 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] | 2692 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2693 | LIBS="-lnsl $LIBS" |
| 2694 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2695 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2696 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 2697 | # SVR4 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2698 | echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2699 | echo "configure:2700: checking for socket in -lsocket" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2700 | ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2701 | 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] | 2702 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2703 | else |
| 2704 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2705 | LIBS="-lsocket $LIBS $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2706 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2707 | #line 2708 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2708 | #include "confdefs.h" |
| 2709 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2710 | /* We use char because int might match the return type of a gcc2 |
| 2711 | builtin and then its argument prototype would still apply. */ |
| 2712 | char socket(); |
| 2713 | |
| 2714 | int main() { |
| 2715 | socket() |
| 2716 | ; return 0; } |
| 2717 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2718 | if { (eval echo configure:2719: \"$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] | 2719 | rm -rf conftest* |
| 2720 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2721 | else |
| 2722 | echo "configure: failed program was:" >&5 |
| 2723 | cat conftest.$ac_ext >&5 |
| 2724 | rm -rf conftest* |
| 2725 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2726 | fi |
| 2727 | rm -f conftest* |
| 2728 | LIBS="$ac_save_LIBS" |
| 2729 | |
| 2730 | fi |
| 2731 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2732 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2733 | LIBS="-lsocket $LIBS" |
| 2734 | else |
| 2735 | echo "$ac_t""no" 1>&6 |
| 2736 | fi |
| 2737 | # SVR4 sockets |
| 2738 | echo $ac_n "checking for socket in -lnet""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2739 | echo "configure:2740: checking for socket in -lnet" >&5 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2740 | ac_lib_var=`echo net'_'socket | sed 'y%./+-%__p_%'` |
| 2741 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 2742 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2743 | else |
| 2744 | ac_save_LIBS="$LIBS" |
| 2745 | LIBS="-lnet $LIBS $LIBS" |
| 2746 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2747 | #line 2748 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2748 | #include "confdefs.h" |
| 2749 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2750 | /* We use char because int might match the return type of a gcc2 |
| 2751 | builtin and then its argument prototype would still apply. */ |
| 2752 | char socket(); |
| 2753 | |
| 2754 | int main() { |
| 2755 | socket() |
| 2756 | ; return 0; } |
| 2757 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2758 | if { (eval echo configure:2759: \"$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] | 2759 | rm -rf conftest* |
| 2760 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2761 | else |
| 2762 | echo "configure: failed program was:" >&5 |
| 2763 | cat conftest.$ac_ext >&5 |
| 2764 | rm -rf conftest* |
| 2765 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2766 | fi |
| 2767 | rm -f conftest* |
| 2768 | LIBS="$ac_save_LIBS" |
| 2769 | |
| 2770 | fi |
| 2771 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2772 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2773 | LIBS="-lnet $LIBS" |
| 2774 | else |
| 2775 | echo "$ac_t""no" 1>&6 |
| 2776 | fi |
| 2777 | # BeOS |
| 2778 | ;; |
| 2779 | esac |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 2780 | |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 2781 | echo $ac_n "checking for --with-libs""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2782 | echo "configure:2783: checking for --with-libs" >&5 |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 2783 | # Check whether --with-libs or --without-libs was given. |
| 2784 | if test "${with_libs+set}" = set; then |
| 2785 | withval="$with_libs" |
| 2786 | |
| 2787 | echo "$ac_t""$withval" 1>&6 |
| 2788 | LIBS="$withval $LIBS" |
| 2789 | |
| 2790 | else |
| 2791 | echo "$ac_t""no" 1>&6 |
| 2792 | fi |
| 2793 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2794 | |
Guido van Rossum | 3c83bb4 | 1996-12-31 22:35:16 +0000 | [diff] [blame] | 2795 | echo $ac_n "checking for --with(out)-readline""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2796 | echo "configure:2797: checking for --with(out)-readline" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2797 | # Check whether --with-readline or --without-readline was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2798 | if test "${with_readline+set}" = set; then |
| 2799 | withval="$with_readline" |
Guido van Rossum | b06df27 | 1997-08-05 21:50:20 +0000 | [diff] [blame] | 2800 | echo "$ac_t""$withval" 1>&6 |
| 2801 | { 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] | 2802 | else |
Guido van Rossum | b06df27 | 1997-08-05 21:50:20 +0000 | [diff] [blame] | 2803 | echo "$ac_t""not specified." 1>&6 |
Guido van Rossum | 3c83bb4 | 1996-12-31 22:35:16 +0000 | [diff] [blame] | 2804 | fi |
| 2805 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2806 | |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 2807 | |
| 2808 | USE_THREAD_MODULE="#" |
| 2809 | |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2810 | echo $ac_n "checking for --with-dec-threads""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2811 | echo "configure:2812: checking for --with-dec-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2812 | |
| 2813 | # Check whether --with-dec-threads or --without-dec-threads was given. |
| 2814 | if test "${with_dec_threads+set}" = set; then |
| 2815 | withval="$with_dec_threads" |
| 2816 | echo "$ac_t""$withval" 1>&6 |
| 2817 | LDLAST=-threads |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2818 | if test "${with_thread+set}" != set; then |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2819 | with_thread="$withval"; |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2820 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2821 | else |
| 2822 | echo "$ac_t""no" 1>&6 |
| 2823 | fi |
| 2824 | |
| 2825 | |
| 2826 | echo $ac_n "checking for --with-threads""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2827 | echo "configure:2828: checking for --with-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2828 | # Check whether --with-threads or --without-threads was given. |
| 2829 | if test "${with_threads+set}" = set; then |
| 2830 | withval="$with_threads" |
| 2831 | echo "$ac_t""$withval" 1>&6 |
| 2832 | if test "${with_thread+set}" != set; then |
| 2833 | with_thread="$withval"; |
| 2834 | fi |
| 2835 | else |
| 2836 | echo "$ac_t""no" 1>&6 |
| 2837 | fi |
| 2838 | |
| 2839 | |
| 2840 | echo $ac_n "checking for --with-thread""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2841 | echo "configure:2842: checking for --with-thread" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2842 | # Check whether --with-thread or --without-thread was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2843 | if test "${with_thread+set}" = set; then |
| 2844 | withval="$with_thread" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2845 | |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 2846 | USE_THREAD_MODULE= |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2847 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2848 | if test -d "$withval" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2849 | then LDFLAGS="$LDFLAGS -L$withval" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2850 | fi |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 2851 | cat >> confdefs.h <<\EOF |
| 2852 | #define _REENTRANT 1 |
| 2853 | EOF |
| 2854 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2855 | ac_safe=`echo "mach/cthreads.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2856 | echo $ac_n "checking for mach/cthreads.h""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2857 | echo "configure:2858: checking for mach/cthreads.h" >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2858 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 2859 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2860 | else |
| 2861 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2862 | #line 2863 "configure" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2863 | #include "confdefs.h" |
| 2864 | #include <mach/cthreads.h> |
| 2865 | EOF |
| 2866 | 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] | 2867 | { (eval echo configure:2868: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2868 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2869 | if test -z "$ac_err"; then |
| 2870 | rm -rf conftest* |
| 2871 | eval "ac_cv_header_$ac_safe=yes" |
| 2872 | else |
| 2873 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2874 | echo "configure: failed program was:" >&5 |
| 2875 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2876 | rm -rf conftest* |
| 2877 | eval "ac_cv_header_$ac_safe=no" |
| 2878 | fi |
| 2879 | rm -f conftest* |
| 2880 | fi |
| 2881 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 2882 | echo "$ac_t""yes" 1>&6 |
| 2883 | cat >> confdefs.h <<\EOF |
| 2884 | #define WITH_THREAD 1 |
| 2885 | EOF |
| 2886 | |
| 2887 | cat >> confdefs.h <<\EOF |
| 2888 | #define C_THREADS 1 |
| 2889 | EOF |
| 2890 | |
| 2891 | LIBOBJS="$LIBOBJS thread.o" |
| 2892 | else |
| 2893 | echo "$ac_t""no" 1>&6 |
| 2894 | |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 2895 | echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2896 | echo "configure:2897: checking for pthread_create in -lpthread" >&5 |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 2897 | ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'` |
| 2898 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 2899 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2900 | else |
| 2901 | ac_save_LIBS="$LIBS" |
| 2902 | LIBS="-lpthread $LIBS" |
| 2903 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2904 | #line 2905 "configure" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 2905 | #include "confdefs.h" |
| 2906 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2907 | /* We use char because int might match the return type of a gcc2 |
| 2908 | builtin and then its argument prototype would still apply. */ |
| 2909 | char pthread_create(); |
| 2910 | |
| 2911 | int main() { |
| 2912 | pthread_create() |
| 2913 | ; return 0; } |
| 2914 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2915 | if { (eval echo configure:2916: \"$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] | 2916 | rm -rf conftest* |
| 2917 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2918 | else |
| 2919 | echo "configure: failed program was:" >&5 |
| 2920 | cat conftest.$ac_ext >&5 |
| 2921 | rm -rf conftest* |
| 2922 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2923 | fi |
| 2924 | rm -f conftest* |
| 2925 | LIBS="$ac_save_LIBS" |
| 2926 | |
| 2927 | fi |
| 2928 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2929 | echo "$ac_t""yes" 1>&6 |
| 2930 | cat >> confdefs.h <<\EOF |
| 2931 | #define WITH_THREAD 1 |
| 2932 | EOF |
| 2933 | |
| 2934 | cat >> confdefs.h <<\EOF |
| 2935 | #define _POSIX_THREADS 1 |
| 2936 | EOF |
| 2937 | |
| 2938 | LIBS="-lpthread $LIBS" |
| 2939 | LIBOBJS="$LIBOBJS thread.o" |
| 2940 | else |
| 2941 | echo "$ac_t""no" 1>&6 |
| 2942 | |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2943 | echo $ac_n "checking for pthread_detach""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2944 | echo "configure:2945: checking for pthread_detach" >&5 |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2945 | 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] | 2946 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2947 | else |
| 2948 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2949 | #line 2950 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2950 | #include "confdefs.h" |
| 2951 | /* System header to define __stub macros and hopefully few prototypes, |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2952 | which can conflict with char pthread_detach(); below. */ |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2953 | #include <assert.h> |
| 2954 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2955 | /* We use char because int might match the return type of a gcc2 |
| 2956 | builtin and then its argument prototype would still apply. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2957 | char pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2958 | |
| 2959 | int main() { |
| 2960 | |
| 2961 | /* The GNU C library defines this for functions which it implements |
| 2962 | to always fail with ENOSYS. Some functions are actually named |
| 2963 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2964 | #if defined (__stub_pthread_detach) || defined (__stub___pthread_detach) |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2965 | choke me |
| 2966 | #else |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2967 | pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2968 | #endif |
| 2969 | |
| 2970 | ; return 0; } |
| 2971 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2972 | if { (eval echo configure:2973: \"$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] | 2973 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2974 | eval "ac_cv_func_pthread_detach=yes" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2975 | else |
| 2976 | echo "configure: failed program was:" >&5 |
| 2977 | cat conftest.$ac_ext >&5 |
| 2978 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2979 | eval "ac_cv_func_pthread_detach=no" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2980 | fi |
| 2981 | rm -f conftest* |
| 2982 | fi |
| 2983 | |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2984 | if eval "test \"`echo '$ac_cv_func_'pthread_detach`\" = yes"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2985 | echo "$ac_t""yes" 1>&6 |
| 2986 | cat >> confdefs.h <<\EOF |
| 2987 | #define WITH_THREAD 1 |
| 2988 | EOF |
| 2989 | |
| 2990 | cat >> confdefs.h <<\EOF |
| 2991 | #define _POSIX_THREADS 1 |
| 2992 | EOF |
| 2993 | |
| 2994 | LIBOBJS="$LIBOBJS thread.o" |
| 2995 | else |
| 2996 | echo "$ac_t""no" 1>&6 |
| 2997 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2998 | ac_safe=`echo "kernel/OS.h" | sed 'y%./+-%__p_%'` |
| 2999 | echo $ac_n "checking for kernel/OS.h""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3000 | echo "configure:3001: checking for kernel/OS.h" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3001 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 3002 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3003 | else |
| 3004 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3005 | #line 3006 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3006 | #include "confdefs.h" |
| 3007 | #include <kernel/OS.h> |
| 3008 | EOF |
| 3009 | 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] | 3010 | { (eval echo configure:3011: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3011 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3012 | if test -z "$ac_err"; then |
| 3013 | rm -rf conftest* |
| 3014 | eval "ac_cv_header_$ac_safe=yes" |
| 3015 | else |
| 3016 | echo "$ac_err" >&5 |
| 3017 | echo "configure: failed program was:" >&5 |
| 3018 | cat conftest.$ac_ext >&5 |
| 3019 | rm -rf conftest* |
| 3020 | eval "ac_cv_header_$ac_safe=no" |
| 3021 | fi |
| 3022 | rm -f conftest* |
| 3023 | fi |
| 3024 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 3025 | echo "$ac_t""yes" 1>&6 |
| 3026 | cat >> confdefs.h <<\EOF |
| 3027 | #define WITH_THREAD 1 |
| 3028 | EOF |
| 3029 | |
| 3030 | cat >> confdefs.h <<\EOF |
| 3031 | #define BEOS_THREADS 1 |
| 3032 | EOF |
| 3033 | |
| 3034 | LIBOBJS="$LIBOBJS thread.o" |
| 3035 | else |
| 3036 | echo "$ac_t""no" 1>&6 |
| 3037 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3038 | echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3039 | echo "configure:3040: checking for pthread_create in -lpthreads" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3040 | ac_lib_var=`echo pthreads'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3041 | 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] | 3042 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3043 | else |
| 3044 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3045 | LIBS="-lpthreads $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3046 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3047 | #line 3048 "configure" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3048 | #include "confdefs.h" |
| 3049 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3050 | /* We use char because int might match the return type of a gcc2 |
| 3051 | builtin and then its argument prototype would still apply. */ |
| 3052 | char pthread_create(); |
| 3053 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3054 | int main() { |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3055 | pthread_create() |
| 3056 | ; return 0; } |
| 3057 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3058 | if { (eval echo configure:3059: \"$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] | 3059 | rm -rf conftest* |
| 3060 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3061 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3062 | echo "configure: failed program was:" >&5 |
| 3063 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3064 | rm -rf conftest* |
| 3065 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3066 | fi |
| 3067 | rm -f conftest* |
| 3068 | LIBS="$ac_save_LIBS" |
| 3069 | |
| 3070 | fi |
| 3071 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3072 | echo "$ac_t""yes" 1>&6 |
| 3073 | cat >> confdefs.h <<\EOF |
| 3074 | #define WITH_THREAD 1 |
| 3075 | EOF |
| 3076 | |
| 3077 | cat >> confdefs.h <<\EOF |
| 3078 | #define _POSIX_THREADS 1 |
| 3079 | EOF |
| 3080 | |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3081 | LIBS="$LIBS -lpthreads" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3082 | LIBOBJS="$LIBOBJS thread.o" |
| 3083 | else |
| 3084 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3085 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3086 | echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3087 | echo "configure:3088: checking for pthread_create in -lc_r" >&5 |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3088 | ac_lib_var=`echo c_r'_'pthread_create | sed 'y%./+-%__p_%'` |
| 3089 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3090 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3091 | else |
| 3092 | ac_save_LIBS="$LIBS" |
| 3093 | LIBS="-lc_r $LIBS" |
| 3094 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3095 | #line 3096 "configure" |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3096 | #include "confdefs.h" |
| 3097 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3098 | /* We use char because int might match the return type of a gcc2 |
| 3099 | builtin and then its argument prototype would still apply. */ |
| 3100 | char pthread_create(); |
| 3101 | |
| 3102 | int main() { |
| 3103 | pthread_create() |
| 3104 | ; return 0; } |
| 3105 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3106 | if { (eval echo configure:3107: \"$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] | 3107 | rm -rf conftest* |
| 3108 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3109 | else |
| 3110 | echo "configure: failed program was:" >&5 |
| 3111 | cat conftest.$ac_ext >&5 |
| 3112 | rm -rf conftest* |
| 3113 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3114 | fi |
| 3115 | rm -f conftest* |
| 3116 | LIBS="$ac_save_LIBS" |
| 3117 | |
| 3118 | fi |
| 3119 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3120 | echo "$ac_t""yes" 1>&6 |
| 3121 | cat >> confdefs.h <<\EOF |
| 3122 | #define WITH_THREAD 1 |
| 3123 | EOF |
| 3124 | |
| 3125 | cat >> confdefs.h <<\EOF |
| 3126 | #define _POSIX_THREADS 1 |
| 3127 | EOF |
| 3128 | |
| 3129 | LIBS="$LIBS -lc_r" |
| 3130 | LIBOBJS="$LIBOBJS thread.o" |
| 3131 | else |
| 3132 | echo "$ac_t""no" 1>&6 |
| 3133 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3134 | echo $ac_n "checking for __d6_pthread_create in -lthread""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3135 | echo "configure:3136: checking for __d6_pthread_create in -lthread" >&5 |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3136 | ac_lib_var=`echo thread'_'__d6_pthread_create | sed 'y%./+-%__p_%'` |
| 3137 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3138 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3139 | else |
| 3140 | ac_save_LIBS="$LIBS" |
| 3141 | LIBS="-lthread $LIBS" |
| 3142 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3143 | #line 3144 "configure" |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3144 | #include "confdefs.h" |
| 3145 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3146 | /* We use char because int might match the return type of a gcc2 |
| 3147 | builtin and then its argument prototype would still apply. */ |
| 3148 | char __d6_pthread_create(); |
| 3149 | |
| 3150 | int main() { |
| 3151 | __d6_pthread_create() |
| 3152 | ; return 0; } |
| 3153 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3154 | if { (eval echo configure:3155: \"$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] | 3155 | rm -rf conftest* |
| 3156 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3157 | else |
| 3158 | echo "configure: failed program was:" >&5 |
| 3159 | cat conftest.$ac_ext >&5 |
| 3160 | rm -rf conftest* |
| 3161 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3162 | fi |
| 3163 | rm -f conftest* |
| 3164 | LIBS="$ac_save_LIBS" |
| 3165 | |
| 3166 | fi |
| 3167 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3168 | echo "$ac_t""yes" 1>&6 |
| 3169 | cat >> confdefs.h <<\EOF |
| 3170 | #define WITH_THREAD 1 |
| 3171 | EOF |
| 3172 | |
| 3173 | cat >> confdefs.h <<\EOF |
| 3174 | #define _POSIX_THREADS 1 |
| 3175 | EOF |
| 3176 | |
| 3177 | LIBS="$LIBS -lthread" |
| 3178 | LIBOBJS="$LIBOBJS thread.o" |
| 3179 | else |
| 3180 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3181 | |
| 3182 | echo $ac_n "checking for pthread_create in -lcma""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3183 | echo "configure:3184: checking for pthread_create in -lcma" >&5 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3184 | ac_lib_var=`echo cma'_'pthread_create | sed 'y%./+-%__p_%'` |
| 3185 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3186 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3187 | else |
| 3188 | ac_save_LIBS="$LIBS" |
| 3189 | LIBS="-lcma $LIBS" |
| 3190 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3191 | #line 3192 "configure" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3192 | #include "confdefs.h" |
| 3193 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3194 | /* We use char because int might match the return type of a gcc2 |
| 3195 | builtin and then its argument prototype would still apply. */ |
| 3196 | char pthread_create(); |
| 3197 | |
| 3198 | int main() { |
| 3199 | pthread_create() |
| 3200 | ; return 0; } |
| 3201 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3202 | if { (eval echo configure:3203: \"$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] | 3203 | rm -rf conftest* |
| 3204 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3205 | else |
| 3206 | echo "configure: failed program was:" >&5 |
| 3207 | cat conftest.$ac_ext >&5 |
| 3208 | rm -rf conftest* |
| 3209 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3210 | fi |
| 3211 | rm -f conftest* |
| 3212 | LIBS="$ac_save_LIBS" |
| 3213 | |
| 3214 | fi |
| 3215 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3216 | echo "$ac_t""yes" 1>&6 |
| 3217 | cat >> confdefs.h <<\EOF |
| 3218 | #define WITH_THREAD 1 |
| 3219 | EOF |
| 3220 | |
| 3221 | cat >> confdefs.h <<\EOF |
| 3222 | #define _POSIX_THREADS 1 |
| 3223 | EOF |
| 3224 | |
| 3225 | LIBS="$LIBS -lcma" |
| 3226 | LIBOBJS="$LIBOBJS thread.o" |
| 3227 | else |
| 3228 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3229 | fi |
| 3230 | |
| 3231 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3232 | fi |
| 3233 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3234 | fi |
| 3235 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3236 | fi |
| 3237 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3238 | fi |
| 3239 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3240 | fi |
| 3241 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3242 | fi |
| 3243 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3244 | fi |
| 3245 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3246 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3247 | echo $ac_n "checking for usconfig in -lmpc""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3248 | echo "configure:3249: checking for usconfig in -lmpc" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3249 | ac_lib_var=`echo mpc'_'usconfig | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3250 | 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] | 3251 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3252 | else |
| 3253 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3254 | LIBS="-lmpc $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3255 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3256 | #line 3257 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3257 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3258 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3259 | /* We use char because int might match the return type of a gcc2 |
| 3260 | builtin and then its argument prototype would still apply. */ |
| 3261 | char usconfig(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3262 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3263 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3264 | usconfig() |
| 3265 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3266 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3267 | if { (eval echo configure:3268: \"$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] | 3268 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3269 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3270 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3271 | echo "configure: failed program was:" >&5 |
| 3272 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3273 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3274 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3275 | fi |
| 3276 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3277 | LIBS="$ac_save_LIBS" |
| 3278 | |
| 3279 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3280 | 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] | 3281 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3282 | cat >> confdefs.h <<\EOF |
| 3283 | #define WITH_THREAD 1 |
| 3284 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3285 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3286 | LIBS="$LIBS -lmpc" |
| 3287 | LIBOBJS="$LIBOBJS thread.o" |
| 3288 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3289 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3290 | fi |
| 3291 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3292 | echo $ac_n "checking for thr_create in -lthread""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3293 | echo "configure:3294: checking for thr_create in -lthread" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3294 | ac_lib_var=`echo thread'_'thr_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3295 | 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] | 3296 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3297 | else |
| 3298 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3299 | LIBS="-lthread $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3300 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3301 | #line 3302 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3302 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3303 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3304 | /* We use char because int might match the return type of a gcc2 |
| 3305 | builtin and then its argument prototype would still apply. */ |
| 3306 | char thr_create(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3307 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3308 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3309 | thr_create() |
| 3310 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3311 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3312 | if { (eval echo configure:3313: \"$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] | 3313 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3314 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3315 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3316 | echo "configure: failed program was:" >&5 |
| 3317 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3318 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3319 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3320 | fi |
| 3321 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3322 | LIBS="$ac_save_LIBS" |
| 3323 | |
| 3324 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3325 | 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] | 3326 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3327 | cat >> confdefs.h <<\EOF |
| 3328 | #define WITH_THREAD 1 |
| 3329 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3330 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3331 | LIBS="$LIBS -lthread" |
| 3332 | LIBOBJS="$LIBOBJS thread.o" |
| 3333 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3334 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3335 | fi |
| 3336 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3337 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3338 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3339 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3340 | fi |
| 3341 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3342 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3343 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3344 | |
| 3345 | DLINCLDIR=/ |
| 3346 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3347 | echo $ac_n "checking for --with-sgi-dl""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3348 | echo "configure:3349: checking for --with-sgi-dl" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3349 | # Check whether --with-sgi-dl or --without-sgi-dl was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3350 | if test "${with_sgi_dl+set}" = set; then |
| 3351 | withval="$with_sgi_dl" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3352 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3353 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3354 | cat >> confdefs.h <<\EOF |
| 3355 | #define WITH_SGI_DL 1 |
| 3356 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3357 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3358 | DYNLOADFILE="dynload_dl.o" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3359 | dldir=$withval |
| 3360 | if test -d "$dldir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 3361 | then LDFLAGS="$LDFLAGS -L$dldir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3362 | 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] | 3363 | fi |
| 3364 | DLINCLDIR=${dldir} |
| 3365 | LIBS="$LIBS -ldl -lmld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 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 | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3368 | fi |
| 3369 | |
| 3370 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3371 | echo $ac_n "checking for --with-dl-dld""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3372 | echo "configure:3373: checking for --with-dl-dld" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3373 | # Check whether --with-dl-dld or --without-dl-dld was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3374 | if test "${with_dl_dld+set}" = set; then |
| 3375 | withval="$with_dl_dld" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3376 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3377 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3378 | cat >> confdefs.h <<\EOF |
| 3379 | #define WITH_DL_DLD 1 |
| 3380 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3381 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3382 | DYNLOADFILE="dynload_dl.o" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3383 | dldir=`echo "$withval" | sed 's/,.*//'` |
| 3384 | dlddir=`echo "$withval" | sed 's/.*,//'` |
| 3385 | if test -d "$dldir" -a -d "$dlddir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 3386 | then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3387 | 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] | 3388 | fi |
| 3389 | DLINCLDIR=${dldir} |
| 3390 | LIBS="$LIBS -ldl -ldld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3391 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3392 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3393 | fi |
| 3394 | |
| 3395 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3396 | # the dlopen() function means we might want to use dynload_shlib.o. some |
| 3397 | # platforms, such as AIX, have dlopen(), but don't want to use it. |
| 3398 | echo $ac_n "checking for dlopen""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3399 | echo "configure:3400: checking for dlopen" >&5 |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3400 | if eval "test \"`echo '$''{'ac_cv_func_dlopen'+set}'`\" = set"; then |
| 3401 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3402 | else |
| 3403 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3404 | #line 3405 "configure" |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3405 | #include "confdefs.h" |
| 3406 | /* System header to define __stub macros and hopefully few prototypes, |
| 3407 | which can conflict with char dlopen(); below. */ |
| 3408 | #include <assert.h> |
| 3409 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3410 | /* We use char because int might match the return type of a gcc2 |
| 3411 | builtin and then its argument prototype would still apply. */ |
| 3412 | char dlopen(); |
| 3413 | |
| 3414 | int main() { |
| 3415 | |
| 3416 | /* The GNU C library defines this for functions which it implements |
| 3417 | to always fail with ENOSYS. Some functions are actually named |
| 3418 | something starting with __ and the normal name is an alias. */ |
| 3419 | #if defined (__stub_dlopen) || defined (__stub___dlopen) |
| 3420 | choke me |
| 3421 | #else |
| 3422 | dlopen(); |
| 3423 | #endif |
| 3424 | |
| 3425 | ; return 0; } |
| 3426 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3427 | if { (eval echo configure:3428: \"$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] | 3428 | rm -rf conftest* |
| 3429 | eval "ac_cv_func_dlopen=yes" |
| 3430 | else |
| 3431 | echo "configure: failed program was:" >&5 |
| 3432 | cat conftest.$ac_ext >&5 |
| 3433 | rm -rf conftest* |
| 3434 | eval "ac_cv_func_dlopen=no" |
| 3435 | fi |
| 3436 | rm -f conftest* |
| 3437 | fi |
| 3438 | |
| 3439 | if eval "test \"`echo '$ac_cv_func_'dlopen`\" = yes"; then |
| 3440 | echo "$ac_t""yes" 1>&6 |
| 3441 | : |
| 3442 | else |
| 3443 | echo "$ac_t""no" 1>&6 |
| 3444 | fi |
| 3445 | |
| 3446 | |
| 3447 | # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic |
| 3448 | # loading of modules. |
| 3449 | |
| 3450 | echo $ac_n "checking DYNLOADFILE""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3451 | echo "configure:3452: checking DYNLOADFILE" >&5 |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3452 | if test -z "$DYNLOADFILE" |
| 3453 | then |
| 3454 | case $ac_sys_system/$ac_sys_release in |
| 3455 | AIX*) DYNLOADFILE="dynload_aix.o";; |
| 3456 | BeOS*) DYNLOADFILE="dynload_beos.o";; |
| 3457 | hp*|HP*) DYNLOADFILE="dynload_hpux.o";; |
| 3458 | next/*) DYNLOADFILE="dynload_next.o";; |
| 3459 | *) |
| 3460 | # use dynload_shlib.c and dlopen() if we have it; otherwise stub |
| 3461 | # out any dynamic loading |
| 3462 | if test "$ac_cv_func_dlopen" = yes |
| 3463 | then DYNLOADFILE="dynload_shlib.o" |
| 3464 | else DYNLOADFILE="dynload_stub.o" |
| 3465 | fi |
| 3466 | ;; |
| 3467 | esac |
| 3468 | fi |
| 3469 | echo "$ac_t""$DYNLOADFILE" 1>&6 |
| 3470 | if test "$DYNLOADFILE" != "dynload_stub.o" |
| 3471 | then |
| 3472 | cat >> confdefs.h <<\EOF |
| 3473 | #define HAVE_DYNAMIC_LOADING 1 |
| 3474 | EOF |
| 3475 | |
| 3476 | fi |
| 3477 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3478 | # checks for library functions |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 3479 | for ac_func in alarm chown clock confstr ctermid ctermid_r dlopen execv \ |
| 3480 | flock fork fsync fdatasync fpathconf ftime ftruncate \ |
Fred Drake | f581db1 | 1999-12-14 21:11:47 +0000 | [diff] [blame] | 3481 | getgroups getlogin getpeername getpgrp getpid getpwent gettimeofday getwd \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 3482 | kill link lstat mkfifo mktime nice pathconf pause plock pthread_init \ |
| 3483 | putenv readlink \ |
Guido van Rossum | 9601315 | 1997-10-08 22:47:52 +0000 | [diff] [blame] | 3484 | select setgid setlocale setuid setsid setpgid setpgrp setvbuf \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 3485 | sigaction siginterrupt sigrelse strftime strptime symlink sysconf \ |
Fred Drake | 89143df | 1999-12-09 22:03:25 +0000 | [diff] [blame] | 3486 | tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ |
| 3487 | truncate uname waitpid |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3488 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3489 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3490 | echo "configure:3491: checking for $ac_func" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3491 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 3492 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3493 | else |
| 3494 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3495 | #line 3496 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3496 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3497 | /* System header to define __stub macros and hopefully few prototypes, |
| 3498 | which can conflict with char $ac_func(); below. */ |
| 3499 | #include <assert.h> |
| 3500 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3501 | /* We use char because int might match the return type of a gcc2 |
| 3502 | builtin and then its argument prototype would still apply. */ |
| 3503 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3504 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3505 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3506 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3507 | /* The GNU C library defines this for functions which it implements |
| 3508 | to always fail with ENOSYS. Some functions are actually named |
| 3509 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3510 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3511 | choke me |
| 3512 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3513 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3514 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3515 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3516 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3517 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3518 | if { (eval echo configure:3519: \"$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] | 3519 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3520 | eval "ac_cv_func_$ac_func=yes" |
| 3521 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3522 | echo "configure: failed program was:" >&5 |
| 3523 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3524 | rm -rf conftest* |
| 3525 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3526 | fi |
| 3527 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3528 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3529 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3530 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3531 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3532 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3533 | cat >> confdefs.h <<EOF |
| 3534 | #define $ac_tr_func 1 |
| 3535 | EOF |
| 3536 | |
| 3537 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3538 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3539 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3540 | done |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3541 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 3542 | |
| 3543 | # check for long file support functions |
| 3544 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3545 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3546 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3547 | echo "configure:3548: checking for $ac_func" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3548 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 3549 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3550 | else |
| 3551 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3552 | #line 3553 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3553 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3554 | /* System header to define __stub macros and hopefully few prototypes, |
| 3555 | which can conflict with char $ac_func(); below. */ |
| 3556 | #include <assert.h> |
| 3557 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3558 | /* We use char because int might match the return type of a gcc2 |
| 3559 | builtin and then its argument prototype would still apply. */ |
| 3560 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3561 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3562 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3563 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3564 | /* The GNU C library defines this for functions which it implements |
| 3565 | to always fail with ENOSYS. Some functions are actually named |
| 3566 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3567 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3568 | choke me |
| 3569 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3570 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3571 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3572 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3573 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3574 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3575 | if { (eval echo configure:3576: \"$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] | 3576 | rm -rf conftest* |
| 3577 | eval "ac_cv_func_$ac_func=yes" |
| 3578 | else |
| 3579 | echo "configure: failed program was:" >&5 |
| 3580 | cat conftest.$ac_ext >&5 |
| 3581 | rm -rf conftest* |
| 3582 | eval "ac_cv_func_$ac_func=no" |
| 3583 | fi |
| 3584 | rm -f conftest* |
| 3585 | fi |
| 3586 | |
| 3587 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 3588 | echo "$ac_t""yes" 1>&6 |
| 3589 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 3590 | cat >> confdefs.h <<EOF |
| 3591 | #define $ac_tr_func 1 |
| 3592 | EOF |
| 3593 | |
| 3594 | else |
| 3595 | echo "$ac_t""no" 1>&6 |
| 3596 | fi |
| 3597 | done |
| 3598 | |
| 3599 | |
| 3600 | for ac_func in dup2 getcwd strdup strerror memmove |
| 3601 | do |
| 3602 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3603 | echo "configure:3604: checking for $ac_func" >&5 |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 3604 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 3605 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3606 | else |
| 3607 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3608 | #line 3609 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 3609 | #include "confdefs.h" |
| 3610 | /* System header to define __stub macros and hopefully few prototypes, |
| 3611 | which can conflict with char $ac_func(); below. */ |
| 3612 | #include <assert.h> |
| 3613 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3614 | /* We use char because int might match the return type of a gcc2 |
| 3615 | builtin and then its argument prototype would still apply. */ |
| 3616 | char $ac_func(); |
| 3617 | |
| 3618 | int main() { |
| 3619 | |
| 3620 | /* The GNU C library defines this for functions which it implements |
| 3621 | to always fail with ENOSYS. Some functions are actually named |
| 3622 | something starting with __ and the normal name is an alias. */ |
| 3623 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 3624 | choke me |
| 3625 | #else |
| 3626 | $ac_func(); |
| 3627 | #endif |
| 3628 | |
| 3629 | ; return 0; } |
| 3630 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3631 | if { (eval echo configure:3632: \"$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] | 3632 | rm -rf conftest* |
| 3633 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3634 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3635 | echo "configure: failed program was:" >&5 |
| 3636 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3637 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3638 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3639 | fi |
| 3640 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3641 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3642 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3643 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3644 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3645 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 3646 | cat >> confdefs.h <<EOF |
| 3647 | #define $ac_tr_func 1 |
| 3648 | EOF |
| 3649 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3650 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3651 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3652 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3653 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3654 | done |
| 3655 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3656 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3657 | echo $ac_n "checking for getpgrp""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3658 | echo "configure:3659: checking for getpgrp" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3659 | if eval "test \"`echo '$''{'ac_cv_func_getpgrp'+set}'`\" = set"; then |
| 3660 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3661 | else |
| 3662 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3663 | #line 3664 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3664 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3665 | /* System header to define __stub macros and hopefully few prototypes, |
| 3666 | which can conflict with char getpgrp(); below. */ |
| 3667 | #include <assert.h> |
| 3668 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3669 | /* We use char because int might match the return type of a gcc2 |
| 3670 | builtin and then its argument prototype would still apply. */ |
| 3671 | char getpgrp(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3672 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3673 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3674 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3675 | /* The GNU C library defines this for functions which it implements |
| 3676 | to always fail with ENOSYS. Some functions are actually named |
| 3677 | something starting with __ and the normal name is an alias. */ |
| 3678 | #if defined (__stub_getpgrp) || defined (__stub___getpgrp) |
| 3679 | choke me |
| 3680 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3681 | getpgrp(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3682 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3683 | |
| 3684 | ; return 0; } |
| 3685 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3686 | if { (eval echo configure:3687: \"$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] | 3687 | rm -rf conftest* |
| 3688 | eval "ac_cv_func_getpgrp=yes" |
| 3689 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3690 | echo "configure: failed program was:" >&5 |
| 3691 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3692 | rm -rf conftest* |
| 3693 | eval "ac_cv_func_getpgrp=no" |
| 3694 | fi |
| 3695 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3696 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3697 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3698 | if eval "test \"`echo '$ac_cv_func_'getpgrp`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3699 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3700 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3701 | #line 3702 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3702 | #include "confdefs.h" |
| 3703 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3704 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3705 | getpgrp(0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3706 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3707 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3708 | if { (eval echo configure:3709: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3709 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3710 | cat >> confdefs.h <<\EOF |
| 3711 | #define GETPGRP_HAVE_ARG 1 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3712 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3713 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3714 | else |
| 3715 | echo "configure: failed program was:" >&5 |
| 3716 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3717 | fi |
| 3718 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3719 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3720 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3721 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3722 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3723 | echo $ac_n "checking for setpgrp""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3724 | echo "configure:3725: checking for setpgrp" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3725 | if eval "test \"`echo '$''{'ac_cv_func_setpgrp'+set}'`\" = set"; then |
| 3726 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3727 | else |
| 3728 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3729 | #line 3730 "configure" |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3730 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3731 | /* System header to define __stub macros and hopefully few prototypes, |
| 3732 | which can conflict with char setpgrp(); below. */ |
| 3733 | #include <assert.h> |
| 3734 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3735 | /* We use char because int might match the return type of a gcc2 |
| 3736 | builtin and then its argument prototype would still apply. */ |
| 3737 | char setpgrp(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3738 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3739 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3740 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3741 | /* The GNU C library defines this for functions which it implements |
| 3742 | to always fail with ENOSYS. Some functions are actually named |
| 3743 | something starting with __ and the normal name is an alias. */ |
| 3744 | #if defined (__stub_setpgrp) || defined (__stub___setpgrp) |
| 3745 | choke me |
| 3746 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3747 | setpgrp(); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3748 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3749 | |
| 3750 | ; return 0; } |
| 3751 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3752 | if { (eval echo configure:3753: \"$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] | 3753 | rm -rf conftest* |
| 3754 | eval "ac_cv_func_setpgrp=yes" |
| 3755 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3756 | echo "configure: failed program was:" >&5 |
| 3757 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3758 | rm -rf conftest* |
| 3759 | eval "ac_cv_func_setpgrp=no" |
| 3760 | fi |
| 3761 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3762 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3763 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3764 | if eval "test \"`echo '$ac_cv_func_'setpgrp`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3765 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3766 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3767 | #line 3768 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3768 | #include "confdefs.h" |
| 3769 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3770 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3771 | setpgrp(0,0); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3772 | ; return 0; } |
| 3773 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3774 | if { (eval echo configure:3775: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3775 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3776 | cat >> confdefs.h <<\EOF |
| 3777 | #define SETPGRP_HAVE_ARG 1 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3778 | EOF |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3779 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3780 | else |
| 3781 | echo "configure: failed program was:" >&5 |
| 3782 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3783 | fi |
| 3784 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3785 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3786 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3787 | fi |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3788 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3789 | echo $ac_n "checking for gettimeofday""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3790 | echo "configure:3791: checking for gettimeofday" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3791 | if eval "test \"`echo '$''{'ac_cv_func_gettimeofday'+set}'`\" = set"; then |
| 3792 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3793 | else |
| 3794 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3795 | #line 3796 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3796 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3797 | /* System header to define __stub macros and hopefully few prototypes, |
| 3798 | which can conflict with char gettimeofday(); below. */ |
| 3799 | #include <assert.h> |
| 3800 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3801 | /* We use char because int might match the return type of a gcc2 |
| 3802 | builtin and then its argument prototype would still apply. */ |
| 3803 | char gettimeofday(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3804 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3805 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3806 | |
| 3807 | /* The GNU C library defines this for functions which it implements |
| 3808 | to always fail with ENOSYS. Some functions are actually named |
| 3809 | something starting with __ and the normal name is an alias. */ |
| 3810 | #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday) |
| 3811 | choke me |
| 3812 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3813 | gettimeofday(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3814 | #endif |
| 3815 | |
| 3816 | ; return 0; } |
| 3817 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3818 | if { (eval echo configure:3819: \"$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] | 3819 | rm -rf conftest* |
| 3820 | eval "ac_cv_func_gettimeofday=yes" |
| 3821 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3822 | echo "configure: failed program was:" >&5 |
| 3823 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3824 | rm -rf conftest* |
| 3825 | eval "ac_cv_func_gettimeofday=no" |
| 3826 | fi |
| 3827 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3828 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3829 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3830 | if eval "test \"`echo '$ac_cv_func_'gettimeofday`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3831 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3832 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3833 | #line 3834 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3834 | #include "confdefs.h" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3835 | #include <sys/time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3836 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3837 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
| 3838 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3839 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3840 | if { (eval echo configure:3841: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3841 | : |
| 3842 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3843 | echo "configure: failed program was:" >&5 |
| 3844 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3845 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3846 | cat >> confdefs.h <<\EOF |
| 3847 | #define GETTIMEOFDAY_NO_TZ 1 |
| 3848 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3849 | |
| 3850 | fi |
| 3851 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3852 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3853 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3854 | fi |
| 3855 | |
| 3856 | |
| 3857 | # checks for structures |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3858 | echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3859 | echo "configure:3860: 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] | 3860 | if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then |
| 3861 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3862 | else |
| 3863 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3864 | #line 3865 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3865 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3866 | #include <sys/types.h> |
| 3867 | #include <sys/time.h> |
| 3868 | #include <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 | struct tm *tp; |
| 3871 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3872 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +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 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3875 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3876 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3877 | echo "configure: failed program was:" >&5 |
| 3878 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3879 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3880 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3881 | fi |
| 3882 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3883 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3884 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3885 | echo "$ac_t""$ac_cv_header_time" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3886 | if test $ac_cv_header_time = yes; then |
| 3887 | cat >> confdefs.h <<\EOF |
| 3888 | #define TIME_WITH_SYS_TIME 1 |
| 3889 | EOF |
| 3890 | |
| 3891 | fi |
| 3892 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3893 | echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3894 | echo "configure:3895: 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] | 3895 | if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then |
| 3896 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3897 | else |
| 3898 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3899 | #line 3900 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3900 | #include "confdefs.h" |
| 3901 | #include <sys/types.h> |
| 3902 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3903 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3904 | struct tm *tp; tp->tm_sec; |
| 3905 | ; return 0; } |
| 3906 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3907 | if { (eval echo configure:3908: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3908 | rm -rf conftest* |
| 3909 | ac_cv_struct_tm=time.h |
| 3910 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3911 | echo "configure: failed program was:" >&5 |
| 3912 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3913 | rm -rf conftest* |
| 3914 | ac_cv_struct_tm=sys/time.h |
| 3915 | fi |
| 3916 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3917 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3918 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3919 | echo "$ac_t""$ac_cv_struct_tm" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3920 | if test $ac_cv_struct_tm = sys/time.h; then |
| 3921 | cat >> confdefs.h <<\EOF |
| 3922 | #define TM_IN_SYS_TIME 1 |
| 3923 | EOF |
| 3924 | |
| 3925 | fi |
| 3926 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3927 | echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3928 | echo "configure:3929: checking for tm_zone in struct tm" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3929 | if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then |
| 3930 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3931 | else |
| 3932 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3933 | #line 3934 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3934 | #include "confdefs.h" |
| 3935 | #include <sys/types.h> |
| 3936 | #include <$ac_cv_struct_tm> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3937 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3938 | struct tm tm; tm.tm_zone; |
| 3939 | ; return 0; } |
| 3940 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3941 | if { (eval echo configure:3942: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3942 | rm -rf conftest* |
| 3943 | ac_cv_struct_tm_zone=yes |
| 3944 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3945 | echo "configure: failed program was:" >&5 |
| 3946 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3947 | rm -rf conftest* |
| 3948 | ac_cv_struct_tm_zone=no |
| 3949 | fi |
| 3950 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3951 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3952 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3953 | echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3954 | if test "$ac_cv_struct_tm_zone" = yes; then |
| 3955 | cat >> confdefs.h <<\EOF |
| 3956 | #define HAVE_TM_ZONE 1 |
| 3957 | EOF |
| 3958 | |
| 3959 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3960 | echo $ac_n "checking for tzname""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3961 | echo "configure:3962: checking for tzname" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3962 | if eval "test \"`echo '$''{'ac_cv_var_tzname'+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 | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3966 | #line 3967 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3967 | #include "confdefs.h" |
| 3968 | #include <time.h> |
| 3969 | #ifndef tzname /* For SGI. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3970 | extern char *tzname[]; /* RS6000 and others reject char **tzname. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3971 | #endif |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3972 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3973 | atoi(*tzname); |
| 3974 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3975 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3976 | if { (eval echo configure:3977: \"$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] | 3977 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3978 | ac_cv_var_tzname=yes |
| 3979 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3980 | echo "configure: failed program was:" >&5 |
| 3981 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3982 | rm -rf conftest* |
| 3983 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3984 | fi |
| 3985 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3986 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3987 | |
| 3988 | echo "$ac_t""$ac_cv_var_tzname" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3989 | if test $ac_cv_var_tzname = yes; then |
| 3990 | cat >> confdefs.h <<\EOF |
| 3991 | #define HAVE_TZNAME 1 |
| 3992 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3993 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3994 | fi |
| 3995 | fi |
| 3996 | |
| 3997 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3998 | echo $ac_n "checking for time.h that defines altzone""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 3999 | echo "configure:4000: checking for time.h that defines altzone" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4000 | if eval "test \"`echo '$''{'ac_cv_header_time_altzone'+set}'`\" = set"; then |
| 4001 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4002 | else |
| 4003 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4004 | #line 4005 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4005 | #include "confdefs.h" |
| 4006 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4007 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4008 | return altzone; |
| 4009 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4010 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4011 | if { (eval echo configure:4012: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4012 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4013 | ac_cv_header_time_altzone=yes |
| 4014 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4015 | echo "configure: failed program was:" >&5 |
| 4016 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4017 | rm -rf conftest* |
| 4018 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4019 | fi |
| 4020 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4021 | fi |
| 4022 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4023 | echo "$ac_t""$ac_cv_header_time_altzone" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4024 | if test $ac_cv_header_time_altzone = yes; then |
| 4025 | cat >> confdefs.h <<\EOF |
| 4026 | #define HAVE_ALTZONE 1 |
| 4027 | EOF |
| 4028 | |
| 4029 | fi |
| 4030 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4031 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4032 | echo $ac_n "checking whether sys/select.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4033 | echo "configure:4034: 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] | 4034 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4035 | #line 4036 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4036 | #include "confdefs.h" |
| 4037 | |
| 4038 | #include <sys/types.h> |
| 4039 | #include <sys/select.h> |
| 4040 | #include <sys/time.h> |
| 4041 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4042 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4043 | ; |
| 4044 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4045 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4046 | if { (eval echo configure:4047: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4047 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4048 | cat >> confdefs.h <<\EOF |
| 4049 | #define SYS_SELECT_WITH_SYS_TIME 1 |
| 4050 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4051 | was_it_defined=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4052 | else |
| 4053 | echo "configure: failed program was:" >&5 |
| 4054 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4055 | fi |
| 4056 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4057 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4058 | |
| 4059 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4060 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4061 | echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4062 | echo "configure:4063: checking whether char is unsigned" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4063 | if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then |
| 4064 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4065 | else |
| 4066 | if test "$GCC" = yes; then |
| 4067 | # GCC predefines this symbol on systems where it applies. |
| 4068 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4069 | #line 4070 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4070 | #include "confdefs.h" |
| 4071 | #ifdef __CHAR_UNSIGNED__ |
| 4072 | yes |
| 4073 | #endif |
| 4074 | |
| 4075 | EOF |
| 4076 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 4077 | egrep "yes" >/dev/null 2>&1; then |
| 4078 | rm -rf conftest* |
| 4079 | ac_cv_c_char_unsigned=yes |
| 4080 | else |
| 4081 | rm -rf conftest* |
| 4082 | ac_cv_c_char_unsigned=no |
| 4083 | fi |
| 4084 | rm -f conftest* |
| 4085 | |
| 4086 | else |
| 4087 | if test "$cross_compiling" = yes; then |
| 4088 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 4089 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4090 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4091 | #line 4092 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4092 | #include "confdefs.h" |
| 4093 | /* volatile prevents gcc2 from optimizing the test away on sparcs. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4094 | #if !defined(__STDC__) || __STDC__ != 1 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4095 | #define volatile |
| 4096 | #endif |
| 4097 | main() { |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4098 | volatile char c = 255; exit(c < 0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4099 | } |
| 4100 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4101 | if { (eval echo configure:4102: \"$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] | 4102 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4103 | ac_cv_c_char_unsigned=yes |
| 4104 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4105 | echo "configure: failed program was:" >&5 |
| 4106 | cat conftest.$ac_ext >&5 |
| 4107 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4108 | ac_cv_c_char_unsigned=no |
| 4109 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4110 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4111 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4112 | |
| 4113 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4114 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4115 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4116 | echo "$ac_t""$ac_cv_c_char_unsigned" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4117 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
| 4118 | cat >> confdefs.h <<\EOF |
| 4119 | #define __CHAR_UNSIGNED__ 1 |
| 4120 | EOF |
| 4121 | |
| 4122 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4123 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4124 | echo $ac_n "checking for working const""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4125 | echo "configure:4126: checking for working const" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4126 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
| 4127 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4128 | else |
| 4129 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4130 | #line 4131 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4131 | #include "confdefs.h" |
| 4132 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4133 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4134 | |
| 4135 | /* Ultrix mips cc rejects this. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4136 | typedef int charset[2]; const charset x; |
| 4137 | /* SunOS 4.1.1 cc rejects this. */ |
| 4138 | char const *const *ccp; |
| 4139 | char **p; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4140 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 4141 | struct point {int x, y;}; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4142 | static struct point const zero = {0,0}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4143 | /* AIX XL C 1.02.0.0 rejects this. |
| 4144 | It does not let you subtract one const X* pointer from another in an arm |
| 4145 | of an if-expression whose if-part is not a constant expression */ |
| 4146 | const char *g = "string"; |
| 4147 | ccp = &g + (g ? g-g : 0); |
| 4148 | /* HPUX 7.0 cc rejects these. */ |
| 4149 | ++ccp; |
| 4150 | p = (char**) ccp; |
| 4151 | ccp = (char const *const *) p; |
| 4152 | { /* SCO 3.2v4 cc rejects this. */ |
| 4153 | char *t; |
| 4154 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
| 4155 | |
| 4156 | *t++ = 0; |
| 4157 | } |
| 4158 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4159 | int x[] = {25, 17}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4160 | const int *foo = &x[0]; |
| 4161 | ++foo; |
| 4162 | } |
| 4163 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 4164 | typedef const int *iptr; |
| 4165 | iptr p = 0; |
| 4166 | ++p; |
| 4167 | } |
| 4168 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 4169 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 4170 | struct s { int j; const int *ap[3]; }; |
| 4171 | struct s *b; b->j = 5; |
| 4172 | } |
| 4173 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 4174 | const int foo = 10; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4175 | } |
| 4176 | |
| 4177 | ; return 0; } |
| 4178 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4179 | if { (eval echo configure:4180: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4180 | rm -rf conftest* |
| 4181 | ac_cv_c_const=yes |
| 4182 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4183 | echo "configure: failed program was:" >&5 |
| 4184 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4185 | rm -rf conftest* |
| 4186 | ac_cv_c_const=no |
| 4187 | fi |
| 4188 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4189 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4190 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4191 | echo "$ac_t""$ac_cv_c_const" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4192 | if test $ac_cv_c_const = no; then |
| 4193 | cat >> confdefs.h <<\EOF |
| 4194 | #define const |
| 4195 | EOF |
| 4196 | |
| 4197 | fi |
| 4198 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4199 | echo $ac_n "checking for inline""... $ac_c" 1>&6 |
| 4200 | echo "configure:4201: checking for inline" >&5 |
| 4201 | if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then |
| 4202 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4203 | else |
| 4204 | ac_cv_c_inline=no |
| 4205 | for ac_kw in inline __inline__ __inline; do |
| 4206 | cat > conftest.$ac_ext <<EOF |
| 4207 | #line 4208 "configure" |
| 4208 | #include "confdefs.h" |
| 4209 | |
| 4210 | int main() { |
| 4211 | } $ac_kw foo() { |
| 4212 | ; return 0; } |
| 4213 | EOF |
| 4214 | if { (eval echo configure:4215: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 4215 | rm -rf conftest* |
| 4216 | ac_cv_c_inline=$ac_kw; break |
| 4217 | else |
| 4218 | echo "configure: failed program was:" >&5 |
| 4219 | cat conftest.$ac_ext >&5 |
| 4220 | fi |
| 4221 | rm -f conftest* |
| 4222 | done |
| 4223 | |
| 4224 | fi |
| 4225 | |
| 4226 | echo "$ac_t""$ac_cv_c_inline" 1>&6 |
| 4227 | case "$ac_cv_c_inline" in |
| 4228 | inline | yes) ;; |
| 4229 | no) cat >> confdefs.h <<\EOF |
| 4230 | #define inline |
| 4231 | EOF |
| 4232 | ;; |
| 4233 | *) cat >> confdefs.h <<EOF |
| 4234 | #define inline $ac_cv_c_inline |
| 4235 | EOF |
| 4236 | ;; |
| 4237 | esac |
| 4238 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4239 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4240 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4241 | echo $ac_n "checking for working volatile""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4242 | echo "configure:4243: checking for working volatile" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4243 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4244 | #line 4245 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4245 | #include "confdefs.h" |
| 4246 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4247 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4248 | volatile int x; x = 0; |
| 4249 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4250 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4251 | if { (eval echo configure:4252: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4252 | rm -rf conftest* |
| 4253 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4254 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4255 | echo "configure: failed program was:" >&5 |
| 4256 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4257 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4258 | cat >> confdefs.h <<\EOF |
| 4259 | #define volatile |
| 4260 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4261 | |
| 4262 | fi |
| 4263 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4264 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4265 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4266 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4267 | echo $ac_n "checking for working signed char""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4268 | echo "configure:4269: checking for working signed char" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4269 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4270 | #line 4271 "configure" |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4271 | #include "confdefs.h" |
| 4272 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4273 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4274 | signed char c; |
| 4275 | ; return 0; } |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4276 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4277 | if { (eval echo configure:4278: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4278 | rm -rf conftest* |
| 4279 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4280 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4281 | echo "configure: failed program was:" >&5 |
| 4282 | cat conftest.$ac_ext >&5 |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4283 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4284 | cat >> confdefs.h <<\EOF |
| 4285 | #define signed |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4286 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4287 | |
| 4288 | fi |
| 4289 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4290 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4291 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4292 | have_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4293 | echo $ac_n "checking for prototypes""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4294 | echo "configure:4295: checking for prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4295 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4296 | #line 4297 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4297 | #include "confdefs.h" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4298 | int foo(int x) { return 0; } |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4299 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4300 | return foo(10); |
| 4301 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4302 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4303 | if { (eval echo configure:4304: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4304 | rm -rf conftest* |
| 4305 | cat >> confdefs.h <<\EOF |
| 4306 | #define HAVE_PROTOTYPES 1 |
| 4307 | EOF |
| 4308 | have_prototypes=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4309 | else |
| 4310 | echo "configure: failed program was:" >&5 |
| 4311 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4312 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4313 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4314 | echo "$ac_t""$have_prototypes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4315 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4316 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4317 | echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4318 | echo "configure:4319: checking for variable length prototypes and stdarg.h" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4319 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4320 | #line 4321 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4321 | #include "confdefs.h" |
| 4322 | |
| 4323 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 4324 | int foo(int x, ...) { |
| 4325 | va_list va; |
| 4326 | va_start(va, x); |
| 4327 | va_arg(va, int); |
| 4328 | va_arg(va, char *); |
| 4329 | va_arg(va, double); |
| 4330 | return 0; |
| 4331 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4332 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4333 | int main() { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 4334 | return foo(10, "", 3.14); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4335 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4336 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4337 | if { (eval echo configure:4338: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4338 | rm -rf conftest* |
| 4339 | cat >> confdefs.h <<\EOF |
| 4340 | #define HAVE_STDARG_PROTOTYPES 1 |
| 4341 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4342 | works=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4343 | else |
| 4344 | echo "configure: failed program was:" >&5 |
| 4345 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4346 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4347 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4348 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4349 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4350 | if test "$have_prototypes" = yes; then |
| 4351 | bad_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4352 | echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4353 | echo "configure:4354: checking for bad exec* prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4354 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4355 | #line 4356 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4356 | #include "confdefs.h" |
| 4357 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4358 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4359 | char **t;execve("@",t,t); |
| 4360 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4361 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4362 | if { (eval echo configure:4363: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4363 | : |
| 4364 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4365 | echo "configure: failed program was:" >&5 |
| 4366 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4367 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4368 | cat >> confdefs.h <<\EOF |
| 4369 | #define BAD_EXEC_PROTOTYPES 1 |
| 4370 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4371 | bad_prototypes=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4372 | fi |
| 4373 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4374 | echo "$ac_t""$bad_prototypes" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4375 | fi |
| 4376 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4377 | bad_forward=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4378 | echo $ac_n "checking for bad static forward""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4379 | echo "configure:4380: checking for bad static forward" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4380 | if test "$cross_compiling" = yes; then |
| 4381 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 4382 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4383 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4384 | #line 4385 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4385 | #include "confdefs.h" |
| 4386 | |
| 4387 | struct s { int a; int b; }; |
| 4388 | static struct s foo; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4389 | int foobar() { |
| 4390 | static int random; |
| 4391 | random = (int) &foo; |
| 4392 | return random; |
| 4393 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4394 | static struct s foo = { 1, 2 }; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4395 | main() { |
| 4396 | exit(!((int)&foo == foobar())); |
| 4397 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4398 | |
| 4399 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4400 | if { (eval echo configure:4401: \"$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] | 4401 | then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4402 | : |
| 4403 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4404 | echo "configure: failed program was:" >&5 |
| 4405 | cat conftest.$ac_ext >&5 |
| 4406 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4407 | cat >> confdefs.h <<\EOF |
| 4408 | #define BAD_STATIC_FORWARD 1 |
| 4409 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4410 | bad_forward=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4411 | fi |
| 4412 | rm -fr conftest* |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4413 | fi |
| 4414 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4415 | echo "$ac_t""$bad_forward" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4416 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4417 | va_list_is_array=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4418 | echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4419 | echo "configure:4420: checking whether va_list is an array" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4420 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4421 | #line 4422 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4422 | #include "confdefs.h" |
| 4423 | |
| 4424 | #ifdef HAVE_STDARG_PROTOTYPES |
| 4425 | #include <stdarg.h> |
| 4426 | #else |
| 4427 | #include <varargs.h> |
| 4428 | #endif |
| 4429 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4430 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4431 | va_list list1, list2; list1 = list2; |
| 4432 | ; return 0; } |
| 4433 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4434 | if { (eval echo configure:4435: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +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 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4439 | rm -rf conftest* |
| 4440 | cat >> confdefs.h <<\EOF |
| 4441 | #define VA_LIST_IS_ARRAY 1 |
| 4442 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4443 | va_list_is_array=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4444 | fi |
| 4445 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4446 | echo "$ac_t""$va_list_is_array" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4447 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4448 | # sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-( |
| 4449 | echo $ac_n "checking for gethostbyname_r""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4450 | echo "configure:4451: checking for gethostbyname_r" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4451 | if eval "test \"`echo '$''{'ac_cv_func_gethostbyname_r'+set}'`\" = set"; then |
| 4452 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4453 | else |
| 4454 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4455 | #line 4456 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4456 | #include "confdefs.h" |
| 4457 | /* System header to define __stub macros and hopefully few prototypes, |
| 4458 | which can conflict with char gethostbyname_r(); below. */ |
| 4459 | #include <assert.h> |
| 4460 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4461 | /* We use char because int might match the return type of a gcc2 |
| 4462 | builtin and then its argument prototype would still apply. */ |
| 4463 | char gethostbyname_r(); |
| 4464 | |
| 4465 | int main() { |
| 4466 | |
| 4467 | /* The GNU C library defines this for functions which it implements |
| 4468 | to always fail with ENOSYS. Some functions are actually named |
| 4469 | something starting with __ and the normal name is an alias. */ |
| 4470 | #if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r) |
| 4471 | choke me |
| 4472 | #else |
| 4473 | gethostbyname_r(); |
| 4474 | #endif |
| 4475 | |
| 4476 | ; return 0; } |
| 4477 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4478 | if { (eval echo configure:4479: \"$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] | 4479 | rm -rf conftest* |
| 4480 | eval "ac_cv_func_gethostbyname_r=yes" |
| 4481 | else |
| 4482 | echo "configure: failed program was:" >&5 |
| 4483 | cat conftest.$ac_ext >&5 |
| 4484 | rm -rf conftest* |
| 4485 | eval "ac_cv_func_gethostbyname_r=no" |
| 4486 | fi |
| 4487 | rm -f conftest* |
| 4488 | fi |
| 4489 | |
| 4490 | if eval "test \"`echo '$ac_cv_func_'gethostbyname_r`\" = yes"; then |
| 4491 | echo "$ac_t""yes" 1>&6 |
| 4492 | |
| 4493 | cat >> confdefs.h <<\EOF |
| 4494 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4495 | EOF |
| 4496 | |
| 4497 | echo $ac_n "checking gethostbyname_r with 6 args""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4498 | echo "configure:4499: checking gethostbyname_r with 6 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4499 | OLD_CFLAGS=$CFLAGS |
| 4500 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
| 4501 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4502 | #line 4503 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4503 | #include "confdefs.h" |
| 4504 | |
| 4505 | # include <netdb.h> |
| 4506 | |
| 4507 | int main() { |
| 4508 | |
| 4509 | char *name; |
| 4510 | struct hostent *he, *res; |
| 4511 | char buffer[2048]; |
| 4512 | int buflen = 2048; |
| 4513 | int h_errnop; |
| 4514 | |
| 4515 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
| 4516 | |
| 4517 | ; return 0; } |
| 4518 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4519 | if { (eval echo configure:4520: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4520 | rm -rf conftest* |
| 4521 | |
| 4522 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4523 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4524 | EOF |
| 4525 | |
| 4526 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4527 | #define HAVE_GETHOSTBYNAME_R_6_ARG 1 |
| 4528 | EOF |
| 4529 | |
| 4530 | echo "$ac_t""yes" 1>&6 |
| 4531 | |
| 4532 | else |
| 4533 | echo "configure: failed program was:" >&5 |
| 4534 | cat conftest.$ac_ext >&5 |
| 4535 | rm -rf conftest* |
| 4536 | |
| 4537 | echo "$ac_t""no" 1>&6 |
| 4538 | echo $ac_n "checking gethostbyname_r with 5 args""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4539 | echo "configure:4540: checking gethostbyname_r with 5 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4540 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4541 | #line 4542 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4542 | #include "confdefs.h" |
| 4543 | |
| 4544 | # include <netdb.h> |
| 4545 | |
| 4546 | int main() { |
| 4547 | |
| 4548 | char *name; |
| 4549 | struct hostent *he; |
| 4550 | char buffer[2048]; |
| 4551 | int buflen = 2048; |
| 4552 | int h_errnop; |
| 4553 | |
| 4554 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
| 4555 | |
| 4556 | ; return 0; } |
| 4557 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4558 | if { (eval echo configure:4559: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4559 | rm -rf conftest* |
| 4560 | |
| 4561 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4562 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4563 | EOF |
| 4564 | |
| 4565 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4566 | #define HAVE_GETHOSTBYNAME_R_5_ARG 1 |
| 4567 | EOF |
| 4568 | |
| 4569 | echo "$ac_t""yes" 1>&6 |
| 4570 | |
| 4571 | else |
| 4572 | echo "configure: failed program was:" >&5 |
| 4573 | cat conftest.$ac_ext >&5 |
| 4574 | rm -rf conftest* |
| 4575 | |
| 4576 | echo "$ac_t""no" 1>&6 |
| 4577 | echo $ac_n "checking gethostbyname_r with 3 args""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4578 | echo "configure:4579: checking gethostbyname_r with 3 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4579 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4580 | #line 4581 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4581 | #include "confdefs.h" |
| 4582 | |
| 4583 | # include <netdb.h> |
| 4584 | |
| 4585 | int main() { |
| 4586 | |
| 4587 | char *name; |
| 4588 | struct hostent *he; |
| 4589 | struct hostent_data data; |
| 4590 | |
| 4591 | (void) gethostbyname_r(name, he, &data); |
| 4592 | |
| 4593 | ; return 0; } |
| 4594 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4595 | if { (eval echo configure:4596: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4596 | rm -rf conftest* |
| 4597 | |
| 4598 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4599 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4600 | EOF |
| 4601 | |
| 4602 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4603 | #define HAVE_GETHOSTBYNAME_R_3_ARG 1 |
| 4604 | EOF |
| 4605 | |
| 4606 | echo "$ac_t""yes" 1>&6 |
| 4607 | |
| 4608 | else |
| 4609 | echo "configure: failed program was:" >&5 |
| 4610 | cat conftest.$ac_ext >&5 |
| 4611 | rm -rf conftest* |
| 4612 | |
| 4613 | echo "$ac_t""no" 1>&6 |
| 4614 | |
| 4615 | fi |
| 4616 | rm -f conftest* |
| 4617 | |
| 4618 | fi |
| 4619 | rm -f conftest* |
| 4620 | |
| 4621 | fi |
| 4622 | rm -f conftest* |
| 4623 | CFLAGS=$OLD_CFLAGS |
| 4624 | |
| 4625 | else |
| 4626 | echo "$ac_t""no" 1>&6 |
| 4627 | |
| 4628 | echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4629 | echo "configure:4630: checking for gethostbyname" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4630 | if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then |
| 4631 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4632 | else |
| 4633 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4634 | #line 4635 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4635 | #include "confdefs.h" |
| 4636 | /* System header to define __stub macros and hopefully few prototypes, |
| 4637 | which can conflict with char gethostbyname(); below. */ |
| 4638 | #include <assert.h> |
| 4639 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4640 | /* We use char because int might match the return type of a gcc2 |
| 4641 | builtin and then its argument prototype would still apply. */ |
| 4642 | char gethostbyname(); |
| 4643 | |
| 4644 | int main() { |
| 4645 | |
| 4646 | /* The GNU C library defines this for functions which it implements |
| 4647 | to always fail with ENOSYS. Some functions are actually named |
| 4648 | something starting with __ and the normal name is an alias. */ |
| 4649 | #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) |
| 4650 | choke me |
| 4651 | #else |
| 4652 | gethostbyname(); |
| 4653 | #endif |
| 4654 | |
| 4655 | ; return 0; } |
| 4656 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4657 | if { (eval echo configure:4658: \"$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] | 4658 | rm -rf conftest* |
| 4659 | eval "ac_cv_func_gethostbyname=yes" |
| 4660 | else |
| 4661 | echo "configure: failed program was:" >&5 |
| 4662 | cat conftest.$ac_ext >&5 |
| 4663 | rm -rf conftest* |
| 4664 | eval "ac_cv_func_gethostbyname=no" |
| 4665 | fi |
| 4666 | rm -f conftest* |
| 4667 | fi |
| 4668 | |
| 4669 | if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then |
| 4670 | echo "$ac_t""yes" 1>&6 |
| 4671 | cat >> confdefs.h <<\EOF |
| 4672 | #define HAVE_GETHOSTBYNAME 1 |
| 4673 | EOF |
| 4674 | |
| 4675 | else |
| 4676 | echo "$ac_t""no" 1>&6 |
| 4677 | fi |
| 4678 | |
| 4679 | |
| 4680 | fi |
| 4681 | |
| 4682 | |
| 4683 | |
| 4684 | |
| 4685 | |
| 4686 | |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4687 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4688 | # checks for system services |
| 4689 | # (none yet) |
| 4690 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4691 | # Linux requires this for correct f.p. operations |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4692 | echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4693 | echo "configure:4694: checking for __fpu_control in -lieee" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4694 | ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4695 | 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] | 4696 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4697 | else |
| 4698 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4699 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4700 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4701 | #line 4702 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4702 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4703 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4704 | /* We use char because int might match the return type of a gcc2 |
| 4705 | builtin and then its argument prototype would still apply. */ |
| 4706 | char __fpu_control(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4707 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4708 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4709 | __fpu_control() |
| 4710 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4711 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4712 | if { (eval echo configure:4713: \"$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] | 4713 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4714 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4715 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4716 | echo "configure: failed program was:" >&5 |
| 4717 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4718 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4719 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4720 | fi |
| 4721 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4722 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4723 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4724 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4725 | 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] | 4726 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4727 | ac_tr_lib=HAVE_LIB`echo ieee | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 4728 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4729 | cat >> confdefs.h <<EOF |
| 4730 | #define $ac_tr_lib 1 |
| 4731 | EOF |
| 4732 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4733 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4734 | |
| 4735 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4736 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4737 | fi |
| 4738 | |
| 4739 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4740 | # Check for --with-fpectl |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4741 | echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4742 | echo "configure:4743: checking for --with-fpectl" >&5 |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4743 | # Check whether --with-fpectl or --without-fpectl was given. |
| 4744 | if test "${with_fpectl+set}" = set; then |
| 4745 | withval="$with_fpectl" |
| 4746 | |
| 4747 | if test "$withval" != no |
| 4748 | then cat >> confdefs.h <<\EOF |
| 4749 | #define WANT_SIGFPE_HANDLER 1 |
| 4750 | EOF |
| 4751 | echo "$ac_t""yes" 1>&6 |
| 4752 | else echo "$ac_t""no" 1>&6 |
| 4753 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4754 | else |
| 4755 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4756 | fi |
| 4757 | |
| 4758 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4759 | # check for --with-libm=... |
| 4760 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 4761 | case $ac_sys_system in |
| 4762 | next) ;; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 4763 | BeOS) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 4764 | *) LIBM=-lm |
| 4765 | esac |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4766 | echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4767 | echo "configure:4768: checking for --with-libm=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4768 | # Check whether --with-libm or --without-libm was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4769 | if test "${with_libm+set}" = set; then |
| 4770 | withval="$with_libm" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4771 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4772 | if test "$withval" = no |
| 4773 | then LIBM= |
| 4774 | echo "$ac_t""force LIBM empty" 1>&6 |
| 4775 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4776 | then LIBM=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4777 | echo "$ac_t""set LIBM=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4778 | 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] | 4779 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4780 | else |
| 4781 | echo "$ac_t""default LIBM=\"$LIBM\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4782 | fi |
| 4783 | |
| 4784 | |
| 4785 | # check for --with-libc=... |
| 4786 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4787 | echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4788 | echo "configure:4789: checking for --with-libc=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4789 | # Check whether --with-libc or --without-libc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4790 | if test "${with_libc+set}" = set; then |
| 4791 | withval="$with_libc" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4792 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4793 | if test "$withval" = no |
| 4794 | then LIBC= |
| 4795 | echo "$ac_t""force LIBC empty" 1>&6 |
| 4796 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4797 | then LIBC=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4798 | echo "$ac_t""set LIBC=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4799 | 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] | 4800 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4801 | else |
| 4802 | echo "$ac_t""default LIBC=\"$LIBC\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4803 | fi |
| 4804 | |
| 4805 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4806 | # check for hypot() in math library |
| 4807 | LIBS_SAVE=$LIBS |
| 4808 | LIBS="$LIBS $LIBM" |
| 4809 | for ac_func in hypot |
| 4810 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4811 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4812 | echo "configure:4813: checking for $ac_func" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4813 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 4814 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4815 | else |
| 4816 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4817 | #line 4818 "configure" |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4818 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4819 | /* System header to define __stub macros and hopefully few prototypes, |
| 4820 | which can conflict with char $ac_func(); below. */ |
| 4821 | #include <assert.h> |
| 4822 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4823 | /* We use char because int might match the return type of a gcc2 |
| 4824 | builtin and then its argument prototype would still apply. */ |
| 4825 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4826 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4827 | int main() { |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4828 | |
| 4829 | /* The GNU C library defines this for functions which it implements |
| 4830 | to always fail with ENOSYS. Some functions are actually named |
| 4831 | something starting with __ and the normal name is an alias. */ |
| 4832 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4833 | choke me |
| 4834 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4835 | $ac_func(); |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4836 | #endif |
| 4837 | |
| 4838 | ; return 0; } |
| 4839 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4840 | if { (eval echo configure:4841: \"$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] | 4841 | rm -rf conftest* |
| 4842 | eval "ac_cv_func_$ac_func=yes" |
| 4843 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4844 | echo "configure: failed program was:" >&5 |
| 4845 | cat conftest.$ac_ext >&5 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4846 | rm -rf conftest* |
| 4847 | eval "ac_cv_func_$ac_func=no" |
| 4848 | fi |
| 4849 | rm -f conftest* |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4850 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4851 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4852 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4853 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4854 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4855 | cat >> confdefs.h <<EOF |
| 4856 | #define $ac_tr_func 1 |
| 4857 | EOF |
| 4858 | |
| 4859 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4860 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4861 | fi |
| 4862 | done |
| 4863 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4864 | for ac_func in hypot |
| 4865 | do |
| 4866 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4867 | echo "configure:4868: checking for $ac_func" >&5 |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4868 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 4869 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4870 | else |
| 4871 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4872 | #line 4873 "configure" |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4873 | #include "confdefs.h" |
| 4874 | /* System header to define __stub macros and hopefully few prototypes, |
| 4875 | which can conflict with char $ac_func(); below. */ |
| 4876 | #include <assert.h> |
| 4877 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4878 | /* We use char because int might match the return type of a gcc2 |
| 4879 | builtin and then its argument prototype would still apply. */ |
| 4880 | char $ac_func(); |
| 4881 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4882 | int main() { |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4883 | |
| 4884 | /* The GNU C library defines this for functions which it implements |
| 4885 | to always fail with ENOSYS. Some functions are actually named |
| 4886 | something starting with __ and the normal name is an alias. */ |
| 4887 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4888 | choke me |
| 4889 | #else |
| 4890 | $ac_func(); |
| 4891 | #endif |
| 4892 | |
| 4893 | ; return 0; } |
| 4894 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4895 | if { (eval echo configure:4896: \"$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] | 4896 | rm -rf conftest* |
| 4897 | eval "ac_cv_func_$ac_func=yes" |
| 4898 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4899 | echo "configure: failed program was:" >&5 |
| 4900 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4901 | rm -rf conftest* |
| 4902 | eval "ac_cv_func_$ac_func=no" |
| 4903 | fi |
| 4904 | rm -f conftest* |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4905 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4906 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4907 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4908 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4909 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4910 | cat >> confdefs.h <<EOF |
| 4911 | #define $ac_tr_func 1 |
| 4912 | EOF |
| 4913 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4914 | else |
| 4915 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4916 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4917 | fi |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4918 | done |
| 4919 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4920 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4921 | LIBS=$LIBS_SAVE |
| 4922 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4923 | # check for getopt |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4924 | echo $ac_n "checking for genuine getopt""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4925 | echo "configure:4926: checking for genuine getopt" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4926 | if eval "test \"`echo '$''{'ac_cv_func_getopt'+set}'`\" = set"; then |
| 4927 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4928 | else |
| 4929 | if test "$cross_compiling" = yes; then |
| 4930 | ac_cv_func_getopt=no |
| 4931 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4932 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4933 | #line 4934 "configure" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4934 | #include "confdefs.h" |
| 4935 | #include <stdio.h> |
| 4936 | extern int optind, opterr, getopt(); |
| 4937 | extern char* optarg; |
| 4938 | int main() { |
| 4939 | char* av[] = { "testprog", "parameter", "-fFlag", NULL }; |
| 4940 | opterr = 0; |
| 4941 | if (getopt(3, av, "f:") == 'f') { exit(1); } |
| 4942 | exit(0); |
| 4943 | } |
| 4944 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4945 | if { (eval echo configure:4946: \"$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] | 4946 | then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4947 | ac_cv_func_getopt=yes |
| 4948 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4949 | echo "configure: failed program was:" >&5 |
| 4950 | cat conftest.$ac_ext >&5 |
| 4951 | rm -fr conftest* |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4952 | ac_cv_func_getopt=no |
| 4953 | fi |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4954 | rm -fr conftest* |
| 4955 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4956 | |
| 4957 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4958 | echo "$ac_t""$ac_cv_func_getopt" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4959 | test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o" |
| 4960 | |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 4961 | # check whether malloc(0) returns NULL or not |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 4962 | echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4963 | echo "configure:4964: checking what malloc(0) returns" >&5 |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 4964 | if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then |
| 4965 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4966 | else |
| 4967 | if test "$cross_compiling" = yes; then |
| 4968 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 4969 | else |
| 4970 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4971 | #line 4972 "configure" |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 4972 | #include "confdefs.h" |
| 4973 | #include <stdio.h> |
| 4974 | #ifdef HAVE_STDLIB |
| 4975 | #include <stdlib.h> |
| 4976 | #else |
| 4977 | char *malloc(), *realloc(); |
| 4978 | int *free(); |
| 4979 | #endif |
| 4980 | main() { |
| 4981 | char *p; |
| 4982 | p = malloc(0); |
| 4983 | if (p == NULL) exit(1); |
| 4984 | p = realloc(p, 0); |
| 4985 | if (p == NULL) exit(1); |
| 4986 | free(p); |
| 4987 | exit(0); |
| 4988 | } |
| 4989 | EOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4990 | if { (eval echo configure:4991: \"$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] | 4991 | then |
| 4992 | ac_cv_malloc_zero=nonnull |
| 4993 | else |
| 4994 | echo "configure: failed program was:" >&5 |
| 4995 | cat conftest.$ac_ext >&5 |
| 4996 | rm -fr conftest* |
| 4997 | ac_cv_malloc_zero=null |
| 4998 | fi |
| 4999 | rm -fr conftest* |
| 5000 | fi |
| 5001 | |
| 5002 | fi |
| 5003 | |
| 5004 | echo "$ac_t""$ac_cv_malloc_zero" 1>&6 |
| 5005 | if test "$ac_cv_malloc_zero" = null |
| 5006 | then |
| 5007 | cat >> confdefs.h <<\EOF |
| 5008 | #define MALLOC_ZERO_RETURNS_NULL 1 |
| 5009 | EOF |
| 5010 | |
| 5011 | fi |
| 5012 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5013 | # check for wchar.h |
| 5014 | ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'` |
| 5015 | echo $ac_n "checking for wchar.h""... $ac_c" 1>&6 |
| 5016 | echo "configure:5017: checking for wchar.h" >&5 |
| 5017 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 5018 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5019 | else |
| 5020 | cat > conftest.$ac_ext <<EOF |
| 5021 | #line 5022 "configure" |
| 5022 | #include "confdefs.h" |
| 5023 | #include <wchar.h> |
| 5024 | EOF |
| 5025 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 5026 | { (eval echo configure:5027: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 5027 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 5028 | if test -z "$ac_err"; then |
| 5029 | rm -rf conftest* |
| 5030 | eval "ac_cv_header_$ac_safe=yes" |
| 5031 | else |
| 5032 | echo "$ac_err" >&5 |
| 5033 | echo "configure: failed program was:" >&5 |
| 5034 | cat conftest.$ac_ext >&5 |
| 5035 | rm -rf conftest* |
| 5036 | eval "ac_cv_header_$ac_safe=no" |
| 5037 | fi |
| 5038 | rm -f conftest* |
| 5039 | fi |
| 5040 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 5041 | echo "$ac_t""yes" 1>&6 |
| 5042 | cat >> confdefs.h <<\EOF |
| 5043 | #define HAVE_WCHAR_H 1 |
| 5044 | EOF |
| 5045 | wchar_h="yes" |
| 5046 | else |
| 5047 | echo "$ac_t""no" 1>&6 |
| 5048 | wchar_h="no" |
| 5049 | |
| 5050 | fi |
| 5051 | |
| 5052 | |
| 5053 | # check for usable wchar_t |
| 5054 | usable_wchar_t="unkown" |
| 5055 | echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6 |
| 5056 | echo "configure:5057: checking for usable wchar_t" >&5 |
| 5057 | if test "$cross_compiling" = yes; then |
| 5058 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5059 | else |
| 5060 | cat > conftest.$ac_ext <<EOF |
| 5061 | #line 5062 "configure" |
| 5062 | #include "confdefs.h" |
| 5063 | |
| 5064 | #include "wchar.h" |
| 5065 | #include "wctype.h" |
| 5066 | main() { |
| 5067 | wchar_t s; |
| 5068 | if (sizeof(s) == 2) |
| 5069 | exit(0); |
| 5070 | else |
| 5071 | exit(1); |
| 5072 | } |
| 5073 | |
| 5074 | EOF |
| 5075 | if { (eval echo configure:5076: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 5076 | then |
| 5077 | cat >> confdefs.h <<\EOF |
| 5078 | #define HAVE_USABLE_WCHAR_T 1 |
| 5079 | EOF |
| 5080 | usable_wchar_t="yes" |
| 5081 | else |
| 5082 | echo "configure: failed program was:" >&5 |
| 5083 | cat conftest.$ac_ext >&5 |
| 5084 | rm -fr conftest* |
| 5085 | usable_wchar_t="no" |
| 5086 | fi |
| 5087 | rm -fr conftest* |
| 5088 | fi |
| 5089 | |
| 5090 | echo "$ac_t""$usable_wchar_t" 1>&6 |
| 5091 | |
| 5092 | # check for endianness |
| 5093 | echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 |
| 5094 | echo "configure:5095: checking whether byte ordering is bigendian" >&5 |
| 5095 | if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then |
| 5096 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5097 | else |
| 5098 | ac_cv_c_bigendian=unknown |
| 5099 | # See if sys/param.h defines the BYTE_ORDER macro. |
| 5100 | cat > conftest.$ac_ext <<EOF |
| 5101 | #line 5102 "configure" |
| 5102 | #include "confdefs.h" |
| 5103 | #include <sys/types.h> |
| 5104 | #include <sys/param.h> |
| 5105 | int main() { |
| 5106 | |
| 5107 | #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN |
| 5108 | bogus endian macros |
| 5109 | #endif |
| 5110 | ; return 0; } |
| 5111 | EOF |
| 5112 | if { (eval echo configure:5113: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 5113 | rm -rf conftest* |
| 5114 | # It does; now see whether it defined to BIG_ENDIAN or not. |
| 5115 | cat > conftest.$ac_ext <<EOF |
| 5116 | #line 5117 "configure" |
| 5117 | #include "confdefs.h" |
| 5118 | #include <sys/types.h> |
| 5119 | #include <sys/param.h> |
| 5120 | int main() { |
| 5121 | |
| 5122 | #if BYTE_ORDER != BIG_ENDIAN |
| 5123 | not big endian |
| 5124 | #endif |
| 5125 | ; return 0; } |
| 5126 | EOF |
| 5127 | if { (eval echo configure:5128: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 5128 | rm -rf conftest* |
| 5129 | ac_cv_c_bigendian=yes |
| 5130 | else |
| 5131 | echo "configure: failed program was:" >&5 |
| 5132 | cat conftest.$ac_ext >&5 |
| 5133 | rm -rf conftest* |
| 5134 | ac_cv_c_bigendian=no |
| 5135 | fi |
| 5136 | rm -f conftest* |
| 5137 | else |
| 5138 | echo "configure: failed program was:" >&5 |
| 5139 | cat conftest.$ac_ext >&5 |
| 5140 | fi |
| 5141 | rm -f conftest* |
| 5142 | if test $ac_cv_c_bigendian = unknown; then |
| 5143 | if test "$cross_compiling" = yes; then |
| 5144 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5145 | else |
| 5146 | cat > conftest.$ac_ext <<EOF |
| 5147 | #line 5148 "configure" |
| 5148 | #include "confdefs.h" |
| 5149 | main () { |
| 5150 | /* Are we little or big endian? From Harbison&Steele. */ |
| 5151 | union |
| 5152 | { |
| 5153 | long l; |
| 5154 | char c[sizeof (long)]; |
| 5155 | } u; |
| 5156 | u.l = 1; |
| 5157 | exit (u.c[sizeof (long) - 1] == 1); |
| 5158 | } |
| 5159 | EOF |
| 5160 | if { (eval echo configure:5161: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 5161 | then |
| 5162 | ac_cv_c_bigendian=no |
| 5163 | else |
| 5164 | echo "configure: failed program was:" >&5 |
| 5165 | cat conftest.$ac_ext >&5 |
| 5166 | rm -fr conftest* |
| 5167 | ac_cv_c_bigendian=yes |
| 5168 | fi |
| 5169 | rm -fr conftest* |
| 5170 | fi |
| 5171 | |
| 5172 | fi |
| 5173 | fi |
| 5174 | |
| 5175 | echo "$ac_t""$ac_cv_c_bigendian" 1>&6 |
| 5176 | if test $ac_cv_c_bigendian = yes; then |
| 5177 | cat >> confdefs.h <<\EOF |
| 5178 | #define WORDS_BIGENDIAN 1 |
| 5179 | EOF |
| 5180 | |
| 5181 | fi |
| 5182 | |
| 5183 | |
| 5184 | # Check for --with-wctype-functions |
| 5185 | echo $ac_n "checking for --with-wctype-functions""... $ac_c" 1>&6 |
| 5186 | echo "configure:5187: checking for --with-wctype-functions" >&5 |
| 5187 | # Check whether --with-wctype-functions or --without-wctype-functions was given. |
| 5188 | if test "${with_wctype_functions+set}" = set; then |
| 5189 | withval="$with_wctype_functions" |
| 5190 | |
| 5191 | if test "$withval" != no |
| 5192 | then cat >> confdefs.h <<\EOF |
| 5193 | #define WANT_WCTYPE_FUNCTIONS 1 |
| 5194 | EOF |
| 5195 | echo "$ac_t""yes" 1>&6 |
| 5196 | else echo "$ac_t""no" 1>&6 |
| 5197 | fi |
| 5198 | else |
| 5199 | echo "$ac_t""no" 1>&6 |
| 5200 | fi |
| 5201 | |
| 5202 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5203 | # generate output files |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5204 | trap '' 1 2 15 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5205 | cat > confcache <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5206 | # This file is a shell script that caches the results of configure |
| 5207 | # tests run on this system so they can be shared between configure |
| 5208 | # scripts and configure runs. It is not useful on other systems. |
| 5209 | # If it contains results you don't want to keep, you may remove or edit it. |
| 5210 | # |
| 5211 | # By default, configure uses ./config.cache as the cache file, |
| 5212 | # creating it if it does not exist already. You can give configure |
| 5213 | # the --cache-file=FILE option to use a different cache file; that is |
| 5214 | # what configure does when it calls configure scripts in |
| 5215 | # subdirectories, so they share the cache. |
| 5216 | # Giving --cache-file=/dev/null disables caching, for debugging configure. |
| 5217 | # config.status only pays attention to the cache file if you give it the |
| 5218 | # --recheck option to rerun configure. |
| 5219 | # |
| 5220 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5221 | # The following way of writing the cache mishandles newlines in values, |
| 5222 | # but we know of no workaround that is simple, portable, and efficient. |
| 5223 | # So, don't put newlines in cache variables' values. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5224 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 5225 | # 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] | 5226 | (set) 2>&1 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 5227 | case `(ac_space=' '; set | grep ac_space) 2>&1` in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5228 | *ac_space=\ *) |
| 5229 | # `set' does not quote correctly, so add quotes (double-quote substitution |
| 5230 | # turns \\\\ into \\, and sed turns \\ into \). |
| 5231 | sed -n \ |
| 5232 | -e "s/'/'\\\\''/g" \ |
| 5233 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" |
| 5234 | ;; |
| 5235 | *) |
| 5236 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
| 5237 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' |
| 5238 | ;; |
| 5239 | esac >> confcache |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5240 | if cmp -s $cache_file confcache; then |
| 5241 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5242 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5243 | if test -w $cache_file; then |
| 5244 | echo "updating cache $cache_file" |
| 5245 | cat confcache > $cache_file |
| 5246 | else |
| 5247 | echo "not updating unwritable cache $cache_file" |
| 5248 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5249 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5250 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 5251 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5252 | 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] | 5253 | |
| 5254 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 5255 | # Let make expand exec_prefix. |
| 5256 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 5257 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5258 | # Any assignment to VPATH causes Sun make to only execute |
| 5259 | # the first set of double-colon rules, so remove it if not needed. |
| 5260 | # If there is a colon in the path, we need to keep it. |
| 5261 | if test "x$srcdir" = x.; then |
| 5262 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
| 5263 | fi |
| 5264 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5265 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5266 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5267 | DEFS=-DHAVE_CONFIG_H |
| 5268 | |
| 5269 | # Without the "./", some shells look in PATH for config.status. |
| 5270 | : ${CONFIG_STATUS=./config.status} |
| 5271 | |
| 5272 | echo creating $CONFIG_STATUS |
| 5273 | rm -f $CONFIG_STATUS |
| 5274 | cat > $CONFIG_STATUS <<EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5275 | #! /bin/sh |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5276 | # Generated automatically by configure. |
| 5277 | # Run this file to recreate the current configuration. |
| 5278 | # This directory was configured as follows, |
| 5279 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
| 5280 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5281 | # $0 $ac_configure_args |
| 5282 | # |
| 5283 | # Compiler output produced by configure, useful for debugging |
| 5284 | # configure, is in ./config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5285 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5286 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5287 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5288 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5289 | case "\$ac_option" in |
| 5290 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5291 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
| 5292 | 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] | 5293 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 5294 | echo "$CONFIG_STATUS generated by autoconf version 2.13" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5295 | exit 0 ;; |
| 5296 | -help | --help | --hel | --he | --h) |
| 5297 | echo "\$ac_cs_usage"; exit 0 ;; |
| 5298 | *) echo "\$ac_cs_usage"; exit 1 ;; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5299 | esac |
| 5300 | done |
| 5301 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5302 | ac_given_srcdir=$srcdir |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5303 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 5304 | trap 'rm -fr `echo "Makefile \ |
| 5305 | Objects/Makefile \ |
| 5306 | Parser/Makefile \ |
| 5307 | Python/Makefile \ |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 5308 | Modules/Makefile.pre \ |
| 5309 | 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] | 5310 | EOF |
| 5311 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5312 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5313 | # Protect against being on the right side of a sed subst in config.status. |
| 5314 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; |
| 5315 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5316 | $ac_vpsub |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5317 | $extrasub |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 5318 | s%@SHELL@%$SHELL%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5319 | s%@CFLAGS@%$CFLAGS%g |
| 5320 | s%@CPPFLAGS@%$CPPFLAGS%g |
| 5321 | s%@CXXFLAGS@%$CXXFLAGS%g |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 5322 | s%@FFLAGS@%$FFLAGS%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5323 | s%@DEFS@%$DEFS%g |
| 5324 | s%@LDFLAGS@%$LDFLAGS%g |
| 5325 | s%@LIBS@%$LIBS%g |
| 5326 | s%@exec_prefix@%$exec_prefix%g |
| 5327 | s%@prefix@%$prefix%g |
| 5328 | s%@program_transform_name@%$program_transform_name%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5329 | s%@bindir@%$bindir%g |
| 5330 | s%@sbindir@%$sbindir%g |
| 5331 | s%@libexecdir@%$libexecdir%g |
| 5332 | s%@datadir@%$datadir%g |
| 5333 | s%@sysconfdir@%$sysconfdir%g |
| 5334 | s%@sharedstatedir@%$sharedstatedir%g |
| 5335 | s%@localstatedir@%$localstatedir%g |
| 5336 | s%@libdir@%$libdir%g |
| 5337 | s%@includedir@%$includedir%g |
| 5338 | s%@oldincludedir@%$oldincludedir%g |
| 5339 | s%@infodir@%$infodir%g |
| 5340 | s%@mandir@%$mandir%g |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 5341 | s%@VERSION@%$VERSION%g |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 5342 | s%@MACHDEP@%$MACHDEP%g |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 5343 | s%@SGI_ABI@%$SGI_ABI%g |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 5344 | s%@SET_CXX@%$SET_CXX%g |
| 5345 | s%@MAINOBJ@%$MAINOBJ%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5346 | s%@CC@%$CC%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 5347 | s%@MAKE_LDLIBRARY@%$MAKE_LDLIBRARY%g |
| 5348 | s%@LDLIBRARY@%$LDLIBRARY%g |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 5349 | s%@LINKCC@%$LINKCC%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5350 | s%@RANLIB@%$RANLIB%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5351 | s%@AR@%$AR%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 5352 | s%@INSTALL@%$INSTALL%g |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5353 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
| 5354 | s%@INSTALL_DATA@%$INSTALL_DATA%g |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 5355 | s%@LN@%$LN%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 5356 | s%@OPT@%$OPT%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5357 | s%@CPP@%$CPP%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 5358 | s%@LIBTOOL_CRUFT@%$LIBTOOL_CRUFT%g |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 5359 | s%@SO@%$SO%g |
| 5360 | s%@LDSHARED@%$LDSHARED%g |
| 5361 | s%@CCSHARED@%$CCSHARED%g |
| 5362 | s%@LINKFORSHARED@%$LINKFORSHARED%g |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 5363 | s%@USE_THREAD_MODULE@%$USE_THREAD_MODULE%g |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 5364 | s%@LDLAST@%$LDLAST%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5365 | s%@DLINCLDIR@%$DLINCLDIR%g |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 5366 | s%@DYNLOADFILE@%$DYNLOADFILE%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5367 | s%@LIBOBJS@%$LIBOBJS%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5368 | s%@HAVE_GETHOSTBYNAME_R_6_ARG@%$HAVE_GETHOSTBYNAME_R_6_ARG%g |
| 5369 | s%@HAVE_GETHOSTBYNAME_R_5_ARG@%$HAVE_GETHOSTBYNAME_R_5_ARG%g |
| 5370 | 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] | 5371 | s%@HAVE_GETHOSTBYNAME_R@%$HAVE_GETHOSTBYNAME_R%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5372 | s%@HAVE_GETHOSTBYNAME@%$HAVE_GETHOSTBYNAME%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5373 | s%@LIBM@%$LIBM%g |
| 5374 | s%@LIBC@%$LIBC%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5375 | |
| 5376 | CEOF |
| 5377 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5378 | |
| 5379 | cat >> $CONFIG_STATUS <<\EOF |
| 5380 | |
| 5381 | # Split the substitutions into bite-sized pieces for seds with |
| 5382 | # small command number limits, like on Digital OSF/1 and HP-UX. |
| 5383 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. |
| 5384 | ac_file=1 # Number of current file. |
| 5385 | ac_beg=1 # First line for current file. |
| 5386 | ac_end=$ac_max_sed_cmds # Line after last line for current file. |
| 5387 | ac_more_lines=: |
| 5388 | ac_sed_cmds="" |
| 5389 | while $ac_more_lines; do |
| 5390 | if test $ac_beg -gt 1; then |
| 5391 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file |
| 5392 | else |
| 5393 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file |
| 5394 | fi |
| 5395 | if test ! -s conftest.s$ac_file; then |
| 5396 | ac_more_lines=false |
| 5397 | rm -f conftest.s$ac_file |
| 5398 | else |
| 5399 | if test -z "$ac_sed_cmds"; then |
| 5400 | ac_sed_cmds="sed -f conftest.s$ac_file" |
| 5401 | else |
| 5402 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" |
| 5403 | fi |
| 5404 | ac_file=`expr $ac_file + 1` |
| 5405 | ac_beg=$ac_end |
| 5406 | ac_end=`expr $ac_end + $ac_max_sed_cmds` |
| 5407 | fi |
| 5408 | done |
| 5409 | if test -z "$ac_sed_cmds"; then |
| 5410 | ac_sed_cmds=cat |
| 5411 | fi |
| 5412 | EOF |
| 5413 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5414 | cat >> $CONFIG_STATUS <<EOF |
| 5415 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 5416 | CONFIG_FILES=\${CONFIG_FILES-"Makefile \ |
| 5417 | Objects/Makefile \ |
| 5418 | Parser/Makefile \ |
| 5419 | Python/Makefile \ |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 5420 | Modules/Makefile.pre \ |
| 5421 | Modules/Setup.thread"} |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5422 | EOF |
| 5423 | cat >> $CONFIG_STATUS <<\EOF |
| 5424 | 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] | 5425 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5426 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5427 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5428 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 5429 | *) ac_file_in="${ac_file}.in" ;; |
| 5430 | esac |
| 5431 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5432 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5433 | |
| 5434 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 5435 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 5436 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 5437 | # The file is in a subdirectory. |
| 5438 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5439 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5440 | # A "../" for each directory in $ac_dir_suffix. |
| 5441 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
| 5442 | else |
| 5443 | ac_dir_suffix= ac_dots= |
| 5444 | fi |
| 5445 | |
| 5446 | case "$ac_given_srcdir" in |
| 5447 | .) srcdir=. |
| 5448 | if test -z "$ac_dots"; then top_srcdir=. |
| 5449 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; |
| 5450 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; |
| 5451 | *) # Relative path. |
| 5452 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
| 5453 | top_srcdir="$ac_dots$ac_given_srcdir" ;; |
| 5454 | esac |
| 5455 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5456 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5457 | echo creating "$ac_file" |
| 5458 | rm -f "$ac_file" |
| 5459 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." |
| 5460 | case "$ac_file" in |
| 5461 | *Makefile*) ac_comsub="1i\\ |
| 5462 | # $configure_input" ;; |
| 5463 | *) ac_comsub= ;; |
| 5464 | esac |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5465 | |
| 5466 | 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] | 5467 | sed -e "$ac_comsub |
| 5468 | s%@configure_input@%$configure_input%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5469 | s%@srcdir@%$srcdir%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5470 | s%@top_srcdir@%$top_srcdir%g |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5471 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5472 | fi; done |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5473 | rm -f conftest.s* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5474 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5475 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
| 5476 | # 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] | 5477 | # |
| 5478 | # ac_d sets the value in "#define NAME VALUE" lines. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5479 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
| 5480 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5481 | ac_dC='\3' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5482 | ac_dD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5483 | # 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] | 5484 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 5485 | ac_uB='\([ ]\)%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5486 | ac_uC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5487 | ac_uD='\4%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5488 | # 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] | 5489 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 5490 | ac_eB='$%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5491 | ac_eC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5492 | ac_eD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5493 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5494 | if test "${CONFIG_HEADERS+set}" != set; then |
| 5495 | EOF |
| 5496 | cat >> $CONFIG_STATUS <<EOF |
| 5497 | CONFIG_HEADERS="config.h" |
| 5498 | EOF |
| 5499 | cat >> $CONFIG_STATUS <<\EOF |
| 5500 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5501 | 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] | 5502 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5503 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5504 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5505 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 5506 | *) ac_file_in="${ac_file}.in" ;; |
| 5507 | esac |
| 5508 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5509 | echo creating $ac_file |
| 5510 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5511 | rm -f conftest.frag conftest.in conftest.out |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5512 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
| 5513 | cat $ac_file_inputs > conftest.in |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5514 | |
| 5515 | EOF |
| 5516 | |
| 5517 | # Transform confdefs.h into a sed script conftest.vals that substitutes |
| 5518 | # 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] | 5519 | # 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] | 5520 | # Protect against being in an unquoted here document in config.status. |
| 5521 | rm -f conftest.vals |
| 5522 | cat > conftest.hdr <<\EOF |
| 5523 | s/[\\&%]/\\&/g |
| 5524 | s%[\\$`]%\\&%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5525 | 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] | 5526 | s%ac_d%ac_u%gp |
| 5527 | s%ac_u%ac_e%gp |
| 5528 | EOF |
| 5529 | sed -n -f conftest.hdr confdefs.h > conftest.vals |
| 5530 | rm -f conftest.hdr |
| 5531 | |
| 5532 | # This sed command replaces #undef with comments. This is necessary, for |
| 5533 | # example, in the case of _POSIX_SOURCE, which is predefined and required |
| 5534 | # on some systems where configure will not decide to define it. |
| 5535 | cat >> conftest.vals <<\EOF |
| 5536 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% |
| 5537 | EOF |
| 5538 | |
| 5539 | # Break up conftest.vals because some shells have a limit on |
| 5540 | # 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] | 5541 | |
| 5542 | rm -f conftest.tail |
| 5543 | while : |
| 5544 | do |
| 5545 | ac_lines=`grep -c . conftest.vals` |
| 5546 | # grep -c gives empty output for an empty file on some AIX systems. |
| 5547 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi |
| 5548 | # Write a limited-size here document to conftest.frag. |
| 5549 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS |
| 5550 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS |
| 5551 | echo 'CEOF |
| 5552 | sed -f conftest.frag conftest.in > conftest.out |
| 5553 | rm -f conftest.in |
| 5554 | mv conftest.out conftest.in |
| 5555 | ' >> $CONFIG_STATUS |
| 5556 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
| 5557 | rm -f conftest.vals |
| 5558 | mv conftest.tail conftest.vals |
| 5559 | done |
| 5560 | rm -f conftest.vals |
| 5561 | |
| 5562 | cat >> $CONFIG_STATUS <<\EOF |
| 5563 | rm -f conftest.frag conftest.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5564 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5565 | cat conftest.in >> conftest.h |
| 5566 | rm -f conftest.in |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5567 | if cmp -s $ac_file conftest.h 2>/dev/null; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5568 | echo "$ac_file is unchanged" |
| 5569 | rm -f conftest.h |
| 5570 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5571 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 5572 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 5573 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 5574 | # The file is in a subdirectory. |
| 5575 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
| 5576 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5577 | rm -f $ac_file |
| 5578 | mv conftest.h $ac_file |
| 5579 | fi |
| 5580 | fi; done |
| 5581 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5582 | EOF |
| 5583 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5584 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5585 | EOF |
| 5586 | cat >> $CONFIG_STATUS <<\EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5587 | |
| 5588 | exit 0 |
| 5589 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5590 | chmod +x $CONFIG_STATUS |
| 5591 | rm -fr confdefs* $ac_clean_files |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5592 | 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] | 5593 | |