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 | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3 | # From configure.in Revision: 1.107 |
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 | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 25 | --with-libs='lib1 ...' link against additional libs" |
| 26 | ac_help="$ac_help |
Guido van Rossum | b06df27 | 1997-08-05 21:50:20 +0000 | [diff] [blame] | 27 | --with(out)-readline obsolete, edit Modules/Setup instead" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 28 | ac_help="$ac_help |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 29 | --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries" |
| 30 | ac_help="$ac_help |
| 31 | --with-threads alias for --with-thread" |
| 32 | ac_help="$ac_help |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 33 | --with-thread[=DIRECTORY] make interpreter thread-safe" |
| 34 | ac_help="$ac_help |
| 35 | --with-sgi-dl=DIRECTORY IRIX 4 dynamic linking" |
| 36 | ac_help="$ac_help |
| 37 | --with-dl-dld=DL_DIR,DLD_DIR GNU dynamic linking" |
| 38 | ac_help="$ac_help |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 39 | --with-fpectl enable SIGFPE catching" |
| 40 | ac_help="$ac_help |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 41 | --with-libm=STRING math library" |
| 42 | ac_help="$ac_help |
| 43 | --with-libc=STRING C library" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 44 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 45 | # Initialize some variables set by options. |
| 46 | # The variables have the same names as the options, with |
| 47 | # dashes changed to underlines. |
| 48 | build=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 49 | cache_file=./config.cache |
| 50 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 51 | host=NONE |
| 52 | no_create= |
| 53 | nonopt=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 54 | no_recursion= |
| 55 | prefix=NONE |
| 56 | program_prefix=NONE |
| 57 | program_suffix=NONE |
| 58 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 59 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 60 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 61 | srcdir= |
| 62 | target=NONE |
| 63 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 64 | x_includes=NONE |
| 65 | x_libraries=NONE |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 66 | bindir='${exec_prefix}/bin' |
| 67 | sbindir='${exec_prefix}/sbin' |
| 68 | libexecdir='${exec_prefix}/libexec' |
| 69 | datadir='${prefix}/share' |
| 70 | sysconfdir='${prefix}/etc' |
| 71 | sharedstatedir='${prefix}/com' |
| 72 | localstatedir='${prefix}/var' |
| 73 | libdir='${exec_prefix}/lib' |
| 74 | includedir='${prefix}/include' |
| 75 | oldincludedir='/usr/include' |
| 76 | infodir='${prefix}/info' |
| 77 | mandir='${prefix}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 78 | |
| 79 | # Initialize some other variables. |
| 80 | subdirs= |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 81 | MFLAGS= MAKEFLAGS= |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 82 | SHELL=${CONFIG_SHELL-/bin/sh} |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 83 | # Maximum number of lines to put in a shell here document. |
| 84 | ac_max_here_lines=12 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 85 | |
| 86 | ac_prev= |
| 87 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 88 | do |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 89 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 90 | # If the previous option needs an argument, assign it. |
| 91 | if test -n "$ac_prev"; then |
| 92 | eval "$ac_prev=\$ac_option" |
| 93 | ac_prev= |
| 94 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 95 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 96 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 97 | case "$ac_option" in |
| 98 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; |
| 99 | *) ac_optarg= ;; |
| 100 | esac |
| 101 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 102 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 103 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 104 | case "$ac_option" in |
| 105 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 106 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 107 | ac_prev=bindir ;; |
| 108 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
| 109 | bindir="$ac_optarg" ;; |
| 110 | |
| 111 | -build | --build | --buil | --bui | --bu) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 112 | ac_prev=build ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 113 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 114 | build="$ac_optarg" ;; |
| 115 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 116 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 117 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 118 | ac_prev=cache_file ;; |
| 119 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 120 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
| 121 | cache_file="$ac_optarg" ;; |
| 122 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 123 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
| 124 | ac_prev=datadir ;; |
| 125 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ |
| 126 | | --da=*) |
| 127 | datadir="$ac_optarg" ;; |
| 128 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 129 | -disable-* | --disable-*) |
| 130 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 131 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 132 | 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] | 133 | { 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] | 134 | fi |
| 135 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 136 | eval "enable_${ac_feature}=no" ;; |
| 137 | |
| 138 | -enable-* | --enable-*) |
| 139 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 140 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 141 | 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] | 142 | { 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] | 143 | fi |
| 144 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 145 | case "$ac_option" in |
| 146 | *=*) ;; |
| 147 | *) ac_optarg=yes ;; |
| 148 | esac |
| 149 | eval "enable_${ac_feature}='$ac_optarg'" ;; |
| 150 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 151 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 152 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 153 | | --exec | --exe | --ex) |
| 154 | ac_prev=exec_prefix ;; |
| 155 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 156 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 157 | | --exec=* | --exe=* | --ex=*) |
| 158 | exec_prefix="$ac_optarg" ;; |
| 159 | |
| 160 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 161 | # Obsolete; use --with-gas. |
| 162 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 163 | |
| 164 | -help | --help | --hel | --he) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 165 | # Omit some internal or obsolete options to make the list less imposing. |
| 166 | # 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] | 167 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 168 | Usage: configure [options] [host] |
| 169 | Options: [defaults in brackets after descriptions] |
| 170 | Configuration: |
| 171 | --cache-file=FILE cache test results in FILE |
| 172 | --help print this message |
| 173 | --no-create do not create output files |
| 174 | --quiet, --silent do not print \`checking...' messages |
| 175 | --version print the version of autoconf that created configure |
| 176 | Directory and file names: |
| 177 | --prefix=PREFIX install architecture-independent files in PREFIX |
| 178 | [$ac_default_prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 179 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 180 | [same as prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 181 | --bindir=DIR user executables in DIR [EPREFIX/bin] |
| 182 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] |
| 183 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] |
| 184 | --datadir=DIR read-only architecture-independent data in DIR |
| 185 | [PREFIX/share] |
| 186 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] |
| 187 | --sharedstatedir=DIR modifiable architecture-independent data in DIR |
| 188 | [PREFIX/com] |
| 189 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] |
| 190 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] |
| 191 | --includedir=DIR C header files in DIR [PREFIX/include] |
| 192 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] |
| 193 | --infodir=DIR info documentation in DIR [PREFIX/info] |
| 194 | --mandir=DIR man documentation in DIR [PREFIX/man] |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 195 | --srcdir=DIR find the sources in DIR [configure dir or ..] |
| 196 | --program-prefix=PREFIX prepend PREFIX to installed program names |
| 197 | --program-suffix=SUFFIX append SUFFIX to installed program names |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 198 | --program-transform-name=PROGRAM |
| 199 | run sed PROGRAM on installed program names |
| 200 | EOF |
| 201 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 202 | Host type: |
| 203 | --build=BUILD configure for building on BUILD [BUILD=HOST] |
| 204 | --host=HOST configure for HOST [guessed] |
| 205 | --target=TARGET configure for TARGET [TARGET=HOST] |
| 206 | Features and packages: |
| 207 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 208 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
| 209 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 210 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
| 211 | --x-includes=DIR X include files are in DIR |
| 212 | --x-libraries=DIR X library files are in DIR |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 213 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 214 | if test -n "$ac_help"; then |
| 215 | echo "--enable and --with options recognized:$ac_help" |
| 216 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 217 | exit 0 ;; |
| 218 | |
| 219 | -host | --host | --hos | --ho) |
| 220 | ac_prev=host ;; |
| 221 | -host=* | --host=* | --hos=* | --ho=*) |
| 222 | host="$ac_optarg" ;; |
| 223 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 224 | -includedir | --includedir | --includedi | --included | --include \ |
| 225 | | --includ | --inclu | --incl | --inc) |
| 226 | ac_prev=includedir ;; |
| 227 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 228 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
| 229 | includedir="$ac_optarg" ;; |
| 230 | |
| 231 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 232 | ac_prev=infodir ;; |
| 233 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
| 234 | infodir="$ac_optarg" ;; |
| 235 | |
| 236 | -libdir | --libdir | --libdi | --libd) |
| 237 | ac_prev=libdir ;; |
| 238 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
| 239 | libdir="$ac_optarg" ;; |
| 240 | |
| 241 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 242 | | --libexe | --libex | --libe) |
| 243 | ac_prev=libexecdir ;; |
| 244 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 245 | | --libexe=* | --libex=* | --libe=*) |
| 246 | libexecdir="$ac_optarg" ;; |
| 247 | |
| 248 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
| 249 | | --localstate | --localstat | --localsta | --localst \ |
| 250 | | --locals | --local | --loca | --loc | --lo) |
| 251 | ac_prev=localstatedir ;; |
| 252 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
| 253 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ |
| 254 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) |
| 255 | localstatedir="$ac_optarg" ;; |
| 256 | |
| 257 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 258 | ac_prev=mandir ;; |
| 259 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
| 260 | mandir="$ac_optarg" ;; |
| 261 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 262 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 263 | # Obsolete; use --without-fp. |
| 264 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 265 | |
| 266 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 267 | | --no-cr | --no-c) |
| 268 | no_create=yes ;; |
| 269 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 270 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 271 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 272 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 273 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 274 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 275 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 276 | | --oldin | --oldi | --old | --ol | --o) |
| 277 | ac_prev=oldincludedir ;; |
| 278 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 279 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 280 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
| 281 | oldincludedir="$ac_optarg" ;; |
| 282 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 283 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 284 | ac_prev=prefix ;; |
| 285 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
| 286 | prefix="$ac_optarg" ;; |
| 287 | |
| 288 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 289 | | --program-pre | --program-pr | --program-p) |
| 290 | ac_prev=program_prefix ;; |
| 291 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 292 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
| 293 | program_prefix="$ac_optarg" ;; |
| 294 | |
| 295 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 296 | | --program-suf | --program-su | --program-s) |
| 297 | ac_prev=program_suffix ;; |
| 298 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 299 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
| 300 | program_suffix="$ac_optarg" ;; |
| 301 | |
| 302 | -program-transform-name | --program-transform-name \ |
| 303 | | --program-transform-nam | --program-transform-na \ |
| 304 | | --program-transform-n | --program-transform- \ |
| 305 | | --program-transform | --program-transfor \ |
| 306 | | --program-transfo | --program-transf \ |
| 307 | | --program-trans | --program-tran \ |
| 308 | | --progr-tra | --program-tr | --program-t) |
| 309 | ac_prev=program_transform_name ;; |
| 310 | -program-transform-name=* | --program-transform-name=* \ |
| 311 | | --program-transform-nam=* | --program-transform-na=* \ |
| 312 | | --program-transform-n=* | --program-transform-=* \ |
| 313 | | --program-transform=* | --program-transfor=* \ |
| 314 | | --program-transfo=* | --program-transf=* \ |
| 315 | | --program-trans=* | --program-tran=* \ |
| 316 | | --progr-tra=* | --program-tr=* | --program-t=*) |
| 317 | program_transform_name="$ac_optarg" ;; |
| 318 | |
| 319 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 320 | | -silent | --silent | --silen | --sile | --sil) |
| 321 | silent=yes ;; |
| 322 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 323 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 324 | ac_prev=sbindir ;; |
| 325 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 326 | | --sbi=* | --sb=*) |
| 327 | sbindir="$ac_optarg" ;; |
| 328 | |
| 329 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 330 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 331 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 332 | | --sha | --sh) |
| 333 | ac_prev=sharedstatedir ;; |
| 334 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 335 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 336 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 337 | | --sha=* | --sh=*) |
| 338 | sharedstatedir="$ac_optarg" ;; |
| 339 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 340 | -site | --site | --sit) |
| 341 | ac_prev=site ;; |
| 342 | -site=* | --site=* | --sit=*) |
| 343 | site="$ac_optarg" ;; |
| 344 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 345 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 346 | ac_prev=srcdir ;; |
| 347 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
| 348 | srcdir="$ac_optarg" ;; |
| 349 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 350 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 351 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 352 | ac_prev=sysconfdir ;; |
| 353 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 354 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
| 355 | sysconfdir="$ac_optarg" ;; |
| 356 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 357 | -target | --target | --targe | --targ | --tar | --ta | --t) |
| 358 | ac_prev=target ;; |
| 359 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
| 360 | target="$ac_optarg" ;; |
| 361 | |
| 362 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 363 | verbose=yes ;; |
| 364 | |
| 365 | -version | --version | --versio | --versi | --vers) |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 366 | echo "configure generated by autoconf version 2.13" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 367 | exit 0 ;; |
| 368 | |
| 369 | -with-* | --with-*) |
| 370 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 371 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 372 | 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] | 373 | { 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] | 374 | fi |
| 375 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 376 | case "$ac_option" in |
| 377 | *=*) ;; |
| 378 | *) ac_optarg=yes ;; |
| 379 | esac |
| 380 | eval "with_${ac_package}='$ac_optarg'" ;; |
| 381 | |
| 382 | -without-* | --without-*) |
| 383 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 384 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 385 | 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] | 386 | { 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] | 387 | fi |
| 388 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 389 | eval "with_${ac_package}=no" ;; |
| 390 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 391 | --x) |
| 392 | # Obsolete; use --with-x. |
| 393 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 394 | |
| 395 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 396 | | --x-incl | --x-inc | --x-in | --x-i) |
| 397 | ac_prev=x_includes ;; |
| 398 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 399 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
| 400 | x_includes="$ac_optarg" ;; |
| 401 | |
| 402 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 403 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 404 | ac_prev=x_libraries ;; |
| 405 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 406 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
| 407 | x_libraries="$ac_optarg" ;; |
| 408 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 409 | -*) { 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] | 410 | ;; |
| 411 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 412 | *) |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 413 | 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] | 414 | echo "configure: warning: $ac_option: invalid host type" 1>&2 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 415 | fi |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 416 | if test "x$nonopt" != xNONE; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 417 | { 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] | 418 | fi |
| 419 | nonopt="$ac_option" |
| 420 | ;; |
| 421 | |
| 422 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 423 | done |
| 424 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 425 | if test -n "$ac_prev"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 426 | { 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] | 427 | fi |
| 428 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 429 | 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] | 430 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 431 | # File descriptor usage: |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 432 | # 0 standard input |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 433 | # 1 file creation |
| 434 | # 2 errors and warnings |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 435 | # 3 some systems may open it to /dev/tty |
| 436 | # 4 used on the Kubota Titan |
| 437 | # 6 checking for... messages and results |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 438 | # 5 compiler messages saved in config.log |
| 439 | if test "$silent" = yes; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 440 | exec 6>/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 441 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 442 | exec 6>&1 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 443 | fi |
| 444 | exec 5>./config.log |
| 445 | |
| 446 | echo "\ |
| 447 | This file contains any messages produced by compilers while |
| 448 | running configure, to aid debugging if configure makes a mistake. |
| 449 | " 1>&5 |
| 450 | |
| 451 | # Strip out --no-create and --no-recursion so they do not pile up. |
| 452 | # Also quote any args containing shell metacharacters. |
| 453 | ac_configure_args= |
| 454 | for ac_arg |
| 455 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 456 | case "$ac_arg" in |
| 457 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 458 | | --no-cr | --no-c) ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 459 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 460 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; |
| 461 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) |
| 462 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; |
| 463 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 464 | esac |
| 465 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 466 | |
| 467 | # NLS nuisances. |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 468 | # Only set these to C if already set. These must not be set unconditionally |
| 469 | # because not all systems understand e.g. LANG=C (notably SCO). |
| 470 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! |
| 471 | # Non-C LC_CTYPE values break the ctype check. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 472 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 473 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi |
| 474 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi |
| 475 | 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] | 476 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 477 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
| 478 | rm -rf conftest* confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 479 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. |
| 480 | echo > confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 481 | |
| 482 | # A filename unique to this package, relative to the directory that |
| 483 | # 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] | 484 | ac_unique_file=Include/object.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 485 | |
| 486 | # Find the source files, if location was not specified. |
| 487 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 488 | ac_srcdir_defaulted=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 489 | # Try the directory containing this script, then its parent. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 490 | ac_prog=$0 |
| 491 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` |
| 492 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
| 493 | srcdir=$ac_confdir |
| 494 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 495 | srcdir=.. |
| 496 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 497 | else |
| 498 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 499 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 500 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 501 | if test "$ac_srcdir_defaulted" = yes; then |
| 502 | { 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] | 503 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 504 | { 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] | 505 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 506 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 507 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` |
| 508 | |
| 509 | # Prefer explicitly selected file to automatically selected ones. |
| 510 | if test -z "$CONFIG_SITE"; then |
| 511 | if test "x$prefix" != xNONE; then |
| 512 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" |
| 513 | else |
| 514 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" |
| 515 | fi |
| 516 | fi |
| 517 | for ac_site_file in $CONFIG_SITE; do |
| 518 | if test -r "$ac_site_file"; then |
| 519 | echo "loading site script $ac_site_file" |
| 520 | . "$ac_site_file" |
| 521 | fi |
| 522 | done |
| 523 | |
| 524 | if test -r "$cache_file"; then |
| 525 | echo "loading cache $cache_file" |
| 526 | . $cache_file |
| 527 | else |
| 528 | echo "creating cache $cache_file" |
| 529 | > $cache_file |
| 530 | fi |
| 531 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 532 | ac_ext=c |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 533 | # 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] | 534 | ac_cpp='$CPP $CPPFLAGS' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 535 | 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] | 536 | 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] | 537 | cross_compiling=$ac_cv_prog_cc_cross |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 538 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 539 | ac_exeext= |
| 540 | ac_objext=o |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 541 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then |
| 542 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. |
| 543 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then |
| 544 | ac_n= ac_c=' |
| 545 | ' ac_t=' ' |
| 546 | else |
| 547 | ac_n=-n ac_c= ac_t= |
| 548 | fi |
| 549 | else |
| 550 | ac_n= ac_c='\c' ac_t= |
| 551 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 552 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 553 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 554 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 555 | |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 556 | # Set VERSION so we only need to edit in one place (i.e., here) |
| 557 | |
| 558 | VERSION=1.5 |
| 559 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 560 | # NEXTSTEP stuff |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 561 | 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] | 562 | |
| 563 | echo $ac_n "checking for --with-next-archs""... $ac_c" 1>&6 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 564 | echo "configure:565: checking for --with-next-archs" >&5 |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 565 | # Check whether --with-next-archs or --without-next-archs was given. |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 566 | if test "${with_next_archs+set}" = set; then |
| 567 | withval="$with_next_archs" |
| 568 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 569 | if test -n "$withval"; then |
| 570 | ac_arch_flags=`/usr/lib/arch_tool -archify_list $withval` |
| 571 | # GCC does not currently support multi archs on the NeXT |
| 572 | with_gcc=no |
| 573 | fi |
| 574 | echo "$ac_t""$with_next_archs" 1>&6 |
| 575 | |
| 576 | else |
| 577 | echo "$ac_t""none: using `arch`" 1>&6 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 578 | fi |
| 579 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 580 | |
| 581 | if test -z "$MACHDEP" |
| 582 | then |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 583 | set X `hostinfo | egrep '(NeXT Mach|Kernel Release).*:' | \ |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 584 | sed -e 's/://' -e 's/\./_/'` && \ |
| 585 | ac_sys_system=next && ac_sys_release=$4 |
| 586 | |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 587 | MACHDEP="$ac_sys_system$ac_sys_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 588 | fi |
| 589 | fi |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 590 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 591 | # Check whether --with-next-framework or --without-next-framework was given. |
| 592 | if test "${with_next_framework+set}" = set; then |
| 593 | withval="$with_next_framework" |
| 594 | : |
| 595 | fi |
| 596 | |
| 597 | # Check whether --with-dyld or --without-dyld was given. |
| 598 | if test "${with_dyld+set}" = set; then |
| 599 | withval="$with_dyld" |
| 600 | : |
| 601 | fi |
| 602 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 603 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 604 | # Set name for machine-dependent library files |
| 605 | |
| 606 | echo $ac_n "checking MACHDEP""... $ac_c" 1>&6 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 607 | echo "configure:608: checking MACHDEP" >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 608 | if test -z "$MACHDEP" |
| 609 | then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 610 | ac_sys_system=`uname -s` |
| 611 | if test "$ac_sys_system" = "AIX" ; then |
| 612 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 613 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 614 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 615 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 616 | ac_md_system=`echo $ac_sys_system | |
| 617 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 618 | ac_md_release=`echo $ac_sys_release | |
| 619 | tr -d '/ ' | sed 's/\..*//'` |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 620 | MACHDEP="$ac_md_system$ac_md_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 621 | |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 622 | case $MACHDEP in |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 623 | '') MACHDEP="unknown";; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 624 | esac |
| 625 | fi |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 626 | |
| 627 | # |
| 628 | # SGI compilers allow the specification of the both the ABI and the |
| 629 | # ISA on the command line. Depending on the values of these switches, |
| 630 | # different and often incompatable code will be generated. |
| 631 | # |
| 632 | # The SGI_ABI variable can be used to modify the CC and LDFLAGS and |
| 633 | # thus supply support for various ABI/ISA combinations. The MACHDEP |
| 634 | # variable is also adjusted. |
| 635 | # |
| 636 | |
| 637 | if test ! -z "$SGI_ABI" |
| 638 | then |
| 639 | CC="cc $SGI_ABI" |
| 640 | LDFLAGS="$SGI_ABI $LDFLAGS" |
| 641 | MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'` |
| 642 | fi |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 643 | echo "$ac_t""$MACHDEP" 1>&6 |
| 644 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 645 | # |
| 646 | # CCC is the command that compiles C++ programs |
| 647 | # |
| 648 | # Not all make programs have this predefined. |
| 649 | # |
| 650 | |
| 651 | echo $ac_n "checking CCC""... $ac_c" 1>&6 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 652 | echo "configure:653: checking CCC" >&5 |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 653 | if test -z "$CCC" |
| 654 | then |
| 655 | case $ac_sys_system in |
| 656 | IRIX*) SET_CCC="CCC= CC ${SGI_ABI}";; |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 657 | Linux*) SET_CCC="CCC= g++";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 658 | *) SET_CCC="" |
| 659 | esac |
| 660 | else |
| 661 | SET_CCC="CCC= ${CCC}" |
| 662 | fi |
| 663 | echo "$ac_t""$SET_CCC" 1>&6 |
| 664 | |
| 665 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 666 | # checks for alternative programs |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 667 | echo $ac_n "checking for --without-gcc""... $ac_c" 1>&6 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 668 | echo "configure:669: checking for --without-gcc" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 669 | # Check whether --with-gcc or --without-gcc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 670 | if test "${with_gcc+set}" = set; then |
| 671 | withval="$with_gcc" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 672 | |
| 673 | case $withval in |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 674 | no) CC=cc |
| 675 | without_gcc=yes;; |
| 676 | yes) CC=gcc |
| 677 | without_gcc=no;; |
| 678 | *) CC=$withval |
| 679 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 680 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 681 | else |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 682 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 683 | case $ac_sys_system in |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 684 | OSF1) CC=cc |
| 685 | without_gcc=;; |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 686 | BeOS*) |
| 687 | # Dunno if it's a good idea to get this over with all at once, or |
| 688 | # to handle it in with the other goodies. |
| 689 | MACHDEP=beos |
| 690 | |
| 691 | case $BE_HOST_CPU in |
| 692 | ppc) |
Guido van Rossum | 8137680 | 1999-04-06 15:50:51 +0000 | [diff] [blame] | 693 | CC="mwcc -I$PWD/BeOS -nodup" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 694 | without_gcc=yes |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 695 | case `uname -r` in |
| 696 | 4.0*) OPT="-DUSE_DL_EXPORT -O7 -opt schedule604 -export pragma" ;; |
| 697 | *) OPT="-DUSE_DL_EXPORT -O2 -proc 604e -export pragma" ;; |
| 698 | esac |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 699 | CCSHARED=-UUSE_DL_EXPORT |
| 700 | LDFLAGS="$LDFLAGS -nodup" |
| 701 | |
| 702 | AR="$PWD/BeOS/ar-fake" |
| 703 | RANLIB=: |
| 704 | |
| 705 | cat >> confdefs.h <<\EOF |
| 706 | #define DL_EXPORT_HEADER "dl_export.h" |
| 707 | EOF |
| 708 | |
| 709 | ;; |
| 710 | x86) |
| 711 | CC="gcc -I$PWD/BeOS" |
| 712 | without_gcc=no |
| 713 | OPT="-DUSE_DL_EXPORT -O3 -mpentiumpro" |
| 714 | CCSHARED=-UUSE_DL_EXPORT |
| 715 | |
| 716 | AR="$PWD/BeOS/ar-fake" |
| 717 | RANLIB=: |
| 718 | |
| 719 | cat >> confdefs.h <<\EOF |
| 720 | #define DL_EXPORT_HEADER "dl_export.h" |
| 721 | EOF |
| 722 | |
| 723 | ;; |
| 724 | *) |
| 725 | { echo "configure: error: Your BeOS system isn't PowerPC or x86... neat" 1>&2; exit 1; } |
| 726 | ;; |
| 727 | esac |
| 728 | ;; |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 729 | *) without_gcc=no;; |
| 730 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 731 | fi |
| 732 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 733 | echo "$ac_t""$without_gcc" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 734 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 735 | # If the user switches compilers, we can't believe the cache |
| 736 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 737 | then |
| 738 | { echo "configure: error: cached CC is different -- throw away $cache_file |
| 739 | (it is also a good idea to do 'make clean' before compiling)" 1>&2; exit 1; } |
| 740 | fi |
| 741 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 742 | # Extract the first word of "gcc", so it can be a program name with args. |
| 743 | set dummy gcc; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 744 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 745 | echo "configure:746: checking for $ac_word" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 746 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
| 747 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 748 | else |
| 749 | if test -n "$CC"; then |
| 750 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 751 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 752 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 753 | ac_dummy="$PATH" |
| 754 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 755 | test -z "$ac_dir" && ac_dir=. |
| 756 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 757 | ac_cv_prog_CC="gcc" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 758 | break |
| 759 | fi |
| 760 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 761 | IFS="$ac_save_ifs" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 762 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 763 | fi |
| 764 | CC="$ac_cv_prog_CC" |
| 765 | if test -n "$CC"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 766 | echo "$ac_t""$CC" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 767 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 768 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 769 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 770 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 771 | if test -z "$CC"; then |
| 772 | # Extract the first word of "cc", so it can be a program name with args. |
| 773 | set dummy cc; ac_word=$2 |
| 774 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 775 | echo "configure:776: checking for $ac_word" >&5 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 776 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
| 777 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 778 | else |
| 779 | if test -n "$CC"; then |
| 780 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 781 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 782 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 783 | ac_prog_rejected=no |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 784 | ac_dummy="$PATH" |
| 785 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 786 | test -z "$ac_dir" && ac_dir=. |
| 787 | if test -f $ac_dir/$ac_word; then |
| 788 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then |
| 789 | ac_prog_rejected=yes |
| 790 | continue |
| 791 | fi |
| 792 | ac_cv_prog_CC="cc" |
| 793 | break |
| 794 | fi |
| 795 | done |
| 796 | IFS="$ac_save_ifs" |
| 797 | if test $ac_prog_rejected = yes; then |
| 798 | # We found a bogon in the path, so make sure we never use it. |
| 799 | set dummy $ac_cv_prog_CC |
| 800 | shift |
| 801 | if test $# -gt 0; then |
| 802 | # We chose a different compiler from the bogus one. |
| 803 | # However, it has the same basename, so the bogon will be chosen |
| 804 | # first if we set CC to just the basename; use the full file name. |
| 805 | shift |
| 806 | set dummy "$ac_dir/$ac_word" "$@" |
| 807 | shift |
| 808 | ac_cv_prog_CC="$@" |
| 809 | fi |
| 810 | fi |
| 811 | fi |
| 812 | fi |
| 813 | CC="$ac_cv_prog_CC" |
| 814 | if test -n "$CC"; then |
| 815 | echo "$ac_t""$CC" 1>&6 |
| 816 | else |
| 817 | echo "$ac_t""no" 1>&6 |
| 818 | fi |
| 819 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 820 | if test -z "$CC"; then |
| 821 | case "`uname -s`" in |
| 822 | *win32* | *WIN32*) |
| 823 | # Extract the first word of "cl", so it can be a program name with args. |
| 824 | set dummy cl; ac_word=$2 |
| 825 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 826 | echo "configure:827: checking for $ac_word" >&5 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 827 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
| 828 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 829 | else |
| 830 | if test -n "$CC"; then |
| 831 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 832 | else |
| 833 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 834 | ac_dummy="$PATH" |
| 835 | for ac_dir in $ac_dummy; do |
| 836 | test -z "$ac_dir" && ac_dir=. |
| 837 | if test -f $ac_dir/$ac_word; then |
| 838 | ac_cv_prog_CC="cl" |
| 839 | break |
| 840 | fi |
| 841 | done |
| 842 | IFS="$ac_save_ifs" |
| 843 | fi |
| 844 | fi |
| 845 | CC="$ac_cv_prog_CC" |
| 846 | if test -n "$CC"; then |
| 847 | echo "$ac_t""$CC" 1>&6 |
| 848 | else |
| 849 | echo "$ac_t""no" 1>&6 |
| 850 | fi |
| 851 | ;; |
| 852 | esac |
| 853 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 854 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } |
| 855 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 856 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 857 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 858 | echo "configure:859: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 859 | |
| 860 | ac_ext=c |
| 861 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 862 | ac_cpp='$CPP $CPPFLAGS' |
| 863 | 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] | 864 | 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] | 865 | cross_compiling=$ac_cv_prog_cc_cross |
| 866 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 867 | cat > conftest.$ac_ext << EOF |
| 868 | |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 869 | #line 870 "configure" |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 870 | #include "confdefs.h" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 871 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 872 | main(){return(0);} |
| 873 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 874 | if { (eval echo configure:875: \"$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] | 875 | ac_cv_prog_cc_works=yes |
| 876 | # If we can't run a trivial program, we are probably using a cross compiler. |
| 877 | if (./conftest; exit) 2>/dev/null; then |
| 878 | ac_cv_prog_cc_cross=no |
| 879 | else |
| 880 | ac_cv_prog_cc_cross=yes |
| 881 | fi |
| 882 | else |
| 883 | echo "configure: failed program was:" >&5 |
| 884 | cat conftest.$ac_ext >&5 |
| 885 | ac_cv_prog_cc_works=no |
| 886 | fi |
| 887 | rm -fr conftest* |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 888 | ac_ext=c |
| 889 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 890 | ac_cpp='$CPP $CPPFLAGS' |
| 891 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 892 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 893 | cross_compiling=$ac_cv_prog_cc_cross |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 894 | |
| 895 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 |
| 896 | if test $ac_cv_prog_cc_works = no; then |
| 897 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } |
| 898 | fi |
| 899 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 900 | echo "configure:901: 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] | 901 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
| 902 | cross_compiling=$ac_cv_prog_cc_cross |
| 903 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 904 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 905 | echo "configure:906: checking whether we are using GNU C" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 906 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
| 907 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 908 | else |
| 909 | cat > conftest.c <<EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 910 | #ifdef __GNUC__ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 911 | yes; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 912 | #endif |
| 913 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 914 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:915: \"$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] | 915 | ac_cv_prog_gcc=yes |
| 916 | else |
| 917 | ac_cv_prog_gcc=no |
| 918 | fi |
| 919 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 920 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 921 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 922 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 923 | if test $ac_cv_prog_gcc = yes; then |
| 924 | GCC=yes |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 925 | else |
| 926 | GCC= |
| 927 | fi |
| 928 | |
| 929 | ac_test_CFLAGS="${CFLAGS+set}" |
| 930 | ac_save_CFLAGS="$CFLAGS" |
| 931 | CFLAGS= |
| 932 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 933 | echo "configure:934: checking whether ${CC-cc} accepts -g" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 934 | 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] | 935 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 936 | else |
| 937 | echo 'void f(){}' > conftest.c |
| 938 | 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] | 939 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 940 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 941 | ac_cv_prog_cc_g=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 942 | fi |
| 943 | rm -f conftest* |
| 944 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 945 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 946 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 947 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 948 | if test "$ac_test_CFLAGS" = set; then |
| 949 | CFLAGS="$ac_save_CFLAGS" |
| 950 | elif test $ac_cv_prog_cc_g = yes; then |
| 951 | if test "$GCC" = yes; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 952 | CFLAGS="-g -O2" |
| 953 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 954 | CFLAGS="-g" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 955 | fi |
| 956 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 957 | if test "$GCC" = yes; then |
| 958 | CFLAGS="-O2" |
| 959 | else |
| 960 | CFLAGS= |
| 961 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 962 | fi |
| 963 | |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 964 | |
Guido van Rossum | dd997f7 | 1998-10-07 19:58:26 +0000 | [diff] [blame] | 965 | case $MACHDEP in |
| 966 | bsdos*) |
| 967 | case $CC in |
| 968 | gcc) CC="$CC -D_HAVE_BSDI";; |
| 969 | esac;; |
| 970 | esac |
| 971 | |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 972 | case $ac_sys_system in |
| 973 | hp*|HP*) |
| 974 | case $CC in |
| 975 | cc|*/cc) CC="$CC -Aa -D_HPUX_SOURCE";; |
| 976 | esac;; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 977 | BeOS*) |
| 978 | case $CC in |
| 979 | cc) CC=cc;; |
| 980 | esac;; |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 981 | esac |
| 982 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 983 | # LDLIBRARY is the name of the library to link against (as opposed to the |
| 984 | # name of the library into which to insert object files). On systems |
| 985 | # without shared libraries, LDLIBRARY is the same as LIBRARY (defined in |
| 986 | # the Makefiles). |
| 987 | |
| 988 | |
| 989 | LDLIBRARY='' |
| 990 | |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 991 | # 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] | 992 | # This is altered for AIX and BeOS in order to build the export list before |
| 993 | # linking. |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 994 | |
| 995 | echo $ac_n "checking LINKCC""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 996 | echo "configure:997: checking LINKCC" >&5 |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 997 | if test -z "$LINKCC" |
| 998 | then |
| 999 | case $ac_sys_system in |
| 1000 | AIX*) |
Guido van Rossum | 45140f9 | 1997-08-29 18:44:06 +0000 | [diff] [blame] | 1001 | LINKCC="\$(srcdir)/makexp_aix python.exp \"\" \$(LIBRARY); \$(PURIFY) \$(CC)";; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1002 | BeOS*) |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 1003 | LINKCC="\$(srcdir)/../BeOS/linkcc \$(LIBRARY) \$(PURIFY) \$(CC) \$(OPT)" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1004 | LDLIBRARY='libpython$(VERSION).so';; |
Guido van Rossum | 3c4bb80 | 1997-12-18 23:55:32 +0000 | [diff] [blame] | 1005 | dgux*) |
| 1006 | LINKCC="LD_RUN_PATH=$libdir \$(PURIFY) \$(CC)";; |
Guido van Rossum | 25f9303 | 1997-08-18 16:00:04 +0000 | [diff] [blame] | 1007 | *) LINKCC="\$(PURIFY) \$(CC)";; |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1008 | esac |
| 1009 | fi |
| 1010 | echo "$ac_t""$LINKCC" 1>&6 |
| 1011 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1012 | echo $ac_n "checking LDLIBRARY""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1013 | echo "configure:1014: checking LDLIBRARY" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1014 | |
| 1015 | # NeXT framework builds require that the 'ar' library be converted into |
| 1016 | # a bundle using libtool. |
| 1017 | if test "$with_next_framework" |
| 1018 | then |
| 1019 | LDLIBRARY='libpython$(VERSION).dylib' |
| 1020 | fi |
| 1021 | |
| 1022 | # DG/UX requires some fancy ld contortions to produce a .so from an .a |
| 1023 | if test "$MACHDEP" = "dguxR4" |
| 1024 | then |
| 1025 | LDLIBRARY='libpython$(VERSION).so' |
| 1026 | OPT="$OPT -pic" |
| 1027 | fi |
| 1028 | echo "$ac_t""$LDLIBRARY" 1>&6 |
| 1029 | |
| 1030 | # If LDLIBRARY is different from LIBRARY, emit a rule to build it. |
| 1031 | if test -z "$LDLIBRARY" |
| 1032 | then |
| 1033 | LDLIBRARY='libpython$(VERSION).a' |
| 1034 | MAKE_LDLIBRARY="true" |
| 1035 | else |
| 1036 | MAKE_LDLIBRARY='$(MAKE) $(LDLIBRARY)' |
| 1037 | fi |
| 1038 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1039 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 1040 | set dummy ranlib; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1041 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1042 | echo "configure:1043: checking for $ac_word" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1043 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
| 1044 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1045 | else |
| 1046 | if test -n "$RANLIB"; then |
| 1047 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 1048 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1049 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 1050 | ac_dummy="$PATH" |
| 1051 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1052 | test -z "$ac_dir" && ac_dir=. |
| 1053 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1054 | ac_cv_prog_RANLIB="ranlib" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1055 | break |
| 1056 | fi |
| 1057 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1058 | IFS="$ac_save_ifs" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1059 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1060 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1061 | fi |
| 1062 | RANLIB="$ac_cv_prog_RANLIB" |
| 1063 | if test -n "$RANLIB"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1064 | echo "$ac_t""$RANLIB" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1065 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1066 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1067 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1068 | |
| 1069 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1070 | for ac_prog in ar aal |
| 1071 | do |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1072 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 1073 | set dummy $ac_prog; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1074 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1075 | echo "configure:1076: checking for $ac_word" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1076 | if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then |
| 1077 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1078 | else |
| 1079 | if test -n "$AR"; then |
| 1080 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 1081 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1082 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 1083 | ac_dummy="$PATH" |
| 1084 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1085 | test -z "$ac_dir" && ac_dir=. |
| 1086 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1087 | ac_cv_prog_AR="$ac_prog" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1088 | break |
| 1089 | fi |
| 1090 | done |
| 1091 | IFS="$ac_save_ifs" |
| 1092 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1093 | fi |
| 1094 | AR="$ac_cv_prog_AR" |
| 1095 | if test -n "$AR"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1096 | echo "$ac_t""$AR" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1097 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1098 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1099 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1100 | |
| 1101 | test -n "$AR" && break |
| 1102 | done |
| 1103 | test -n "$AR" || AR="ar" |
| 1104 | |
| 1105 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1106 | |
| 1107 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1108 | # Install just never works :-( |
| 1109 | if test -z "$INSTALL" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1110 | then |
| 1111 | INSTALL=cp |
| 1112 | INSTALL_PROGRAM=cp |
| 1113 | INSTALL_DATA=cp |
| 1114 | else |
| 1115 | INSTALL_PROGRAM="$INSTALL" |
| 1116 | INSTALL_DATA="$INSTALL -m 644" |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1117 | fi |
| 1118 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1119 | # Not every filesystem supports hard links |
| 1120 | |
| 1121 | if test -z "$LN" ; then |
| 1122 | case $ac_sys_system in |
| 1123 | BeOS*) LN="ln -s";; |
| 1124 | *) LN=ln;; |
| 1125 | esac |
| 1126 | fi |
| 1127 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1128 | # Optimizer/debugger flags passed between Makefiles |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1129 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1130 | if test -z "$OPT" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1131 | then |
Guido van Rossum | edca74a | 1997-07-18 23:29:40 +0000 | [diff] [blame] | 1132 | case $GCC in |
| 1133 | yes) |
| 1134 | case $ac_cv_prog_cc_g in |
| 1135 | yes) OPT="-g -O2";; |
| 1136 | *) OPT="-O2";; |
| 1137 | esac |
| 1138 | ;; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1139 | *) OPT="-O";; |
| 1140 | esac |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1141 | fi |
| 1142 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1143 | if test "$ac_arch_flags" |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 1144 | then |
| 1145 | OPT="$OPT $ac_arch_flags" |
| 1146 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1147 | # checks for UNIX variants that set C preprocessor variables |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1148 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1149 | echo "configure:1150: checking how to run the C preprocessor" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1150 | # On Suns, sometimes $CPP names a directory. |
| 1151 | if test -n "$CPP" && test -d "$CPP"; then |
| 1152 | CPP= |
| 1153 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1154 | if test -z "$CPP"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1155 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then |
| 1156 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1157 | else |
| 1158 | # This must be in double quotes, not single quotes, because CPP may get |
| 1159 | # substituted into the Makefile and "${CC-cc}" will confuse make. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1160 | CPP="${CC-cc} -E" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1161 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 1162 | # not just through cpp. |
| 1163 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1164 | #line 1165 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1165 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1166 | #include <assert.h> |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1167 | Syntax Error |
| 1168 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1169 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1170 | { (eval echo configure:1171: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1171 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1172 | if test -z "$ac_err"; then |
| 1173 | : |
| 1174 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1175 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1176 | echo "configure: failed program was:" >&5 |
| 1177 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1178 | rm -rf conftest* |
| 1179 | CPP="${CC-cc} -E -traditional-cpp" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1180 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1181 | #line 1182 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1182 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1183 | #include <assert.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1184 | Syntax Error |
| 1185 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1186 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1187 | { (eval echo configure:1188: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1188 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 1189 | if test -z "$ac_err"; then |
| 1190 | : |
| 1191 | else |
| 1192 | echo "$ac_err" >&5 |
| 1193 | echo "configure: failed program was:" >&5 |
| 1194 | cat conftest.$ac_ext >&5 |
| 1195 | rm -rf conftest* |
| 1196 | CPP="${CC-cc} -nologo -E" |
| 1197 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1198 | #line 1199 "configure" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1199 | #include "confdefs.h" |
| 1200 | #include <assert.h> |
| 1201 | Syntax Error |
| 1202 | EOF |
| 1203 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1204 | { (eval echo configure:1205: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1205 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1206 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1207 | : |
| 1208 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1209 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1210 | echo "configure: failed program was:" >&5 |
| 1211 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1212 | rm -rf conftest* |
| 1213 | CPP=/lib/cpp |
| 1214 | fi |
| 1215 | rm -f conftest* |
| 1216 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1217 | rm -f conftest* |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1218 | fi |
| 1219 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1220 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1221 | fi |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 1222 | CPP="$ac_cv_prog_CPP" |
| 1223 | else |
| 1224 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1225 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1226 | echo "$ac_t""$CPP" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1227 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1228 | echo $ac_n "checking for AIX""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1229 | echo "configure:1230: checking for AIX" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1230 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1231 | #line 1232 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1232 | #include "confdefs.h" |
| 1233 | #ifdef _AIX |
| 1234 | yes |
| 1235 | #endif |
| 1236 | |
| 1237 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1238 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1239 | egrep "yes" >/dev/null 2>&1; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1240 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1241 | echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1242 | #define _ALL_SOURCE 1 |
| 1243 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1244 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1245 | else |
| 1246 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1247 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1248 | fi |
| 1249 | rm -f conftest* |
| 1250 | |
| 1251 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1252 | ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1253 | echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1254 | echo "configure:1255: checking for minix/config.h" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1255 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 1256 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1257 | else |
| 1258 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1259 | #line 1260 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1260 | #include "confdefs.h" |
| 1261 | #include <minix/config.h> |
| 1262 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1263 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1264 | { (eval echo configure:1265: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1265 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1266 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1267 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1268 | eval "ac_cv_header_$ac_safe=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1269 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1270 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1271 | echo "configure: failed program was:" >&5 |
| 1272 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1273 | rm -rf conftest* |
| 1274 | eval "ac_cv_header_$ac_safe=no" |
| 1275 | fi |
| 1276 | rm -f conftest* |
| 1277 | fi |
| 1278 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1279 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1280 | MINIX=yes |
| 1281 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1282 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1283 | MINIX= |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1284 | fi |
| 1285 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1286 | if test "$MINIX" = yes; then |
| 1287 | cat >> confdefs.h <<\EOF |
| 1288 | #define _POSIX_SOURCE 1 |
| 1289 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1290 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1291 | cat >> confdefs.h <<\EOF |
| 1292 | #define _POSIX_1_SOURCE 2 |
| 1293 | EOF |
| 1294 | |
| 1295 | cat >> confdefs.h <<\EOF |
| 1296 | #define _MINIX 1 |
| 1297 | EOF |
| 1298 | |
| 1299 | fi |
| 1300 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1301 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1302 | echo $ac_n "checking whether $CC accepts -OPT:Olimit=0""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1303 | echo "configure:1304: checking whether $CC accepts -OPT:Olimit=0" >&5 |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1304 | if eval "test \"`echo '$''{'ac_cv_opt_olimit_ok'+set}'`\" = set"; then |
| 1305 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1306 | else |
| 1307 | ac_save_cc="$CC" |
| 1308 | CC="$CC -OPT:Olimit=0" |
| 1309 | if test "$cross_compiling" = yes; then |
| 1310 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1311 | else |
| 1312 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1313 | #line 1314 "configure" |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1314 | #include "confdefs.h" |
| 1315 | int main() { return 0; } |
| 1316 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1317 | if { (eval echo configure:1318: \"$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] | 1318 | then |
| 1319 | ac_cv_opt_olimit_ok=yes |
| 1320 | else |
| 1321 | echo "configure: failed program was:" >&5 |
| 1322 | cat conftest.$ac_ext >&5 |
| 1323 | rm -fr conftest* |
| 1324 | ac_cv_opt_olimit_ok=no |
| 1325 | fi |
| 1326 | rm -fr conftest* |
| 1327 | fi |
| 1328 | |
| 1329 | CC="$ac_save_cc" |
| 1330 | fi |
| 1331 | |
| 1332 | echo "$ac_t""$ac_cv_opt_olimit_ok" 1>&6 |
Guido van Rossum | 2efa34b | 1997-10-23 17:43:11 +0000 | [diff] [blame] | 1333 | if test $ac_cv_opt_olimit_ok = yes; then |
Guido van Rossum | 304dd2d | 1997-10-20 23:10:56 +0000 | [diff] [blame] | 1334 | OPT="$OPT -OPT:Olimit=0" |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1335 | else |
| 1336 | echo $ac_n "checking whether $CC accepts -Olimit 1500""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1337 | echo "configure:1338: checking whether $CC accepts -Olimit 1500" >&5 |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1338 | if eval "test \"`echo '$''{'ac_cv_olimit_ok'+set}'`\" = set"; then |
| 1339 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1340 | else |
| 1341 | ac_save_cc="$CC" |
| 1342 | CC="$CC -Olimit 1500" |
| 1343 | if test "$cross_compiling" = yes; then |
| 1344 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1345 | else |
| 1346 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1347 | #line 1348 "configure" |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1348 | #include "confdefs.h" |
| 1349 | int main() { return 0; } |
| 1350 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1351 | if { (eval echo configure:1352: \"$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] | 1352 | then |
| 1353 | ac_cv_olimit_ok=yes |
| 1354 | else |
| 1355 | echo "configure: failed program was:" >&5 |
| 1356 | cat conftest.$ac_ext >&5 |
| 1357 | rm -fr conftest* |
| 1358 | ac_cv_olimit_ok=no |
Guido van Rossum | 201afe5 | 1997-05-14 21:14:44 +0000 | [diff] [blame] | 1359 | fi |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1360 | rm -fr conftest* |
| 1361 | fi |
| 1362 | |
| 1363 | CC="$ac_save_cc" |
| 1364 | fi |
| 1365 | |
| 1366 | echo "$ac_t""$ac_cv_olimit_ok" 1>&6 |
| 1367 | if test $ac_cv_olimit_ok = yes; then |
| 1368 | OPT="$OPT -Olimit 1500" |
| 1369 | fi |
| 1370 | fi |
| 1371 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1372 | # check for ANSI or K&R ("traditional") preprocessor |
| 1373 | echo $ac_n "checking for C preprocessor type""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1374 | echo "configure:1375: checking for C preprocessor type" >&5 |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1375 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1376 | #line 1377 "configure" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1377 | #include "confdefs.h" |
| 1378 | |
| 1379 | #define spam(name, doc) {#name, &name, #name "() -- " doc} |
| 1380 | int foo; |
| 1381 | struct {char *name; int *addr; char *doc;} desc = spam(foo, "something"); |
| 1382 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1383 | int main() { |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1384 | ; |
| 1385 | ; return 0; } |
| 1386 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1387 | if { (eval echo configure:1388: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1388 | rm -rf conftest* |
| 1389 | cpp_type=ansi |
| 1390 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1391 | echo "configure: failed program was:" >&5 |
| 1392 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1393 | rm -rf conftest* |
| 1394 | cat >> confdefs.h <<\EOF |
| 1395 | #define HAVE_OLD_CPP 1 |
| 1396 | EOF |
| 1397 | cpp_type=traditional |
| 1398 | fi |
| 1399 | rm -f conftest* |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1400 | echo "$ac_t""$cpp_type" 1>&6 |
| 1401 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1402 | # checks for header files |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1403 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1404 | echo "configure:1405: checking for ANSI C header files" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1405 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
| 1406 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1407 | else |
| 1408 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1409 | #line 1410 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1410 | #include "confdefs.h" |
| 1411 | #include <stdlib.h> |
| 1412 | #include <stdarg.h> |
| 1413 | #include <string.h> |
| 1414 | #include <float.h> |
| 1415 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1416 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1417 | { (eval echo configure:1418: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1418 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1419 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1420 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1421 | ac_cv_header_stdc=yes |
| 1422 | else |
| 1423 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1424 | echo "configure: failed program was:" >&5 |
| 1425 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1426 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1427 | ac_cv_header_stdc=no |
| 1428 | fi |
| 1429 | rm -f conftest* |
| 1430 | |
| 1431 | if test $ac_cv_header_stdc = yes; then |
| 1432 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 1433 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1434 | #line 1435 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1435 | #include "confdefs.h" |
| 1436 | #include <string.h> |
| 1437 | EOF |
| 1438 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1439 | egrep "memchr" >/dev/null 2>&1; then |
| 1440 | : |
| 1441 | else |
| 1442 | rm -rf conftest* |
| 1443 | ac_cv_header_stdc=no |
| 1444 | fi |
| 1445 | rm -f conftest* |
| 1446 | |
| 1447 | fi |
| 1448 | |
| 1449 | if test $ac_cv_header_stdc = yes; then |
| 1450 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 1451 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1452 | #line 1453 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1453 | #include "confdefs.h" |
| 1454 | #include <stdlib.h> |
| 1455 | EOF |
| 1456 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1457 | egrep "free" >/dev/null 2>&1; then |
| 1458 | : |
| 1459 | else |
| 1460 | rm -rf conftest* |
| 1461 | ac_cv_header_stdc=no |
| 1462 | fi |
| 1463 | rm -f conftest* |
| 1464 | |
| 1465 | fi |
| 1466 | |
| 1467 | if test $ac_cv_header_stdc = yes; then |
| 1468 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 1469 | if test "$cross_compiling" = yes; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1470 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1471 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1472 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1473 | #line 1474 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1474 | #include "confdefs.h" |
| 1475 | #include <ctype.h> |
| 1476 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 1477 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1478 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1479 | int main () { int i; for (i = 0; i < 256; i++) |
| 1480 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); |
| 1481 | exit (0); } |
| 1482 | |
| 1483 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1484 | if { (eval echo configure:1485: \"$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] | 1485 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1486 | : |
| 1487 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1488 | echo "configure: failed program was:" >&5 |
| 1489 | cat conftest.$ac_ext >&5 |
| 1490 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1491 | ac_cv_header_stdc=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1492 | fi |
| 1493 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1494 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1495 | |
| 1496 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1497 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1498 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1499 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1500 | if test $ac_cv_header_stdc = yes; then |
| 1501 | cat >> confdefs.h <<\EOF |
| 1502 | #define STDC_HEADERS 1 |
| 1503 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1504 | |
| 1505 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1506 | |
Guido van Rossum | 9601315 | 1997-10-08 22:47:52 +0000 | [diff] [blame] | 1507 | 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] | 1508 | 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] | 1509 | sys/audioio.h sys/file.h sys/lock.h \ |
| 1510 | 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] | 1511 | sys/un.h sys/utsname.h sys/wait.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1512 | do |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1513 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1514 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1515 | echo "configure:1516: checking for $ac_hdr" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1516 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 1517 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1518 | else |
| 1519 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1520 | #line 1521 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1521 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1522 | #include <$ac_hdr> |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1523 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1524 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1525 | { (eval echo configure:1526: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1526 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1527 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1528 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1529 | eval "ac_cv_header_$ac_safe=yes" |
| 1530 | else |
| 1531 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1532 | echo "configure: failed program was:" >&5 |
| 1533 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1534 | rm -rf conftest* |
| 1535 | eval "ac_cv_header_$ac_safe=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1536 | fi |
| 1537 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1538 | fi |
| 1539 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1540 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1541 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1542 | cat >> confdefs.h <<EOF |
| 1543 | #define $ac_tr_hdr 1 |
| 1544 | EOF |
| 1545 | |
| 1546 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1547 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1548 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1549 | done |
| 1550 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1551 | ac_header_dirent=no |
| 1552 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h |
| 1553 | do |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1554 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1555 | echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1556 | echo "configure:1557: checking for $ac_hdr that defines DIR" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1557 | if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then |
| 1558 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1559 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1560 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1561 | #line 1562 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1562 | #include "confdefs.h" |
| 1563 | #include <sys/types.h> |
| 1564 | #include <$ac_hdr> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1565 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1566 | DIR *dirp = 0; |
| 1567 | ; return 0; } |
| 1568 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1569 | if { (eval echo configure:1570: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1570 | rm -rf conftest* |
| 1571 | eval "ac_cv_header_dirent_$ac_safe=yes" |
| 1572 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1573 | echo "configure: failed program was:" >&5 |
| 1574 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1575 | rm -rf conftest* |
| 1576 | eval "ac_cv_header_dirent_$ac_safe=no" |
| 1577 | fi |
| 1578 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1579 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1580 | 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] | 1581 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1582 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1583 | cat >> confdefs.h <<EOF |
| 1584 | #define $ac_tr_hdr 1 |
| 1585 | EOF |
| 1586 | ac_header_dirent=$ac_hdr; break |
| 1587 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1588 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1589 | fi |
| 1590 | done |
| 1591 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 1592 | if test $ac_header_dirent = dirent.h; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1593 | echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1594 | echo "configure:1595: checking for opendir in -ldir" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1595 | ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1596 | 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] | 1597 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1598 | else |
| 1599 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1600 | LIBS="-ldir $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1601 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1602 | #line 1603 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1603 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1604 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1605 | /* We use char because int might match the return type of a gcc2 |
| 1606 | builtin and then its argument prototype would still apply. */ |
| 1607 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1608 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1609 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1610 | opendir() |
| 1611 | ; return 0; } |
| 1612 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1613 | if { (eval echo configure:1614: \"$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] | 1614 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1615 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1616 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1617 | echo "configure: failed program was:" >&5 |
| 1618 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1619 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1620 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1621 | fi |
| 1622 | rm -f conftest* |
| 1623 | LIBS="$ac_save_LIBS" |
| 1624 | |
| 1625 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1626 | 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] | 1627 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1628 | LIBS="$LIBS -ldir" |
| 1629 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1630 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1631 | fi |
| 1632 | |
| 1633 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1634 | echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1635 | echo "configure:1636: checking for opendir in -lx" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1636 | ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1637 | 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] | 1638 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1639 | else |
| 1640 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1641 | LIBS="-lx $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1642 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1643 | #line 1644 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1644 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1645 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1646 | /* We use char because int might match the return type of a gcc2 |
| 1647 | builtin and then its argument prototype would still apply. */ |
| 1648 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1649 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1650 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1651 | opendir() |
| 1652 | ; return 0; } |
| 1653 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1654 | if { (eval echo configure:1655: \"$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] | 1655 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1656 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1657 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1658 | echo "configure: failed program was:" >&5 |
| 1659 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1660 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1661 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1662 | fi |
| 1663 | rm -f conftest* |
| 1664 | LIBS="$ac_save_LIBS" |
| 1665 | |
| 1666 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1667 | 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] | 1668 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1669 | LIBS="$LIBS -lx" |
| 1670 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1671 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1672 | fi |
| 1673 | |
| 1674 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1675 | |
| 1676 | |
| 1677 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1678 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1679 | echo $ac_n "checking for clock_t in time.h""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1680 | echo "configure:1681: checking for clock_t in time.h" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1681 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1682 | #line 1683 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1683 | #include "confdefs.h" |
| 1684 | #include <time.h> |
| 1685 | EOF |
| 1686 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1687 | egrep "clock_t" >/dev/null 2>&1; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1688 | rm -rf conftest* |
| 1689 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1690 | else |
| 1691 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1692 | cat >> confdefs.h <<\EOF |
| 1693 | #define clock_t long |
| 1694 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1695 | |
| 1696 | fi |
| 1697 | rm -f conftest* |
| 1698 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1699 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1700 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1701 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 1702 | cat >> confdefs.h <<\EOF |
| 1703 | #if defined(SCO_DS) |
| 1704 | #undef _OFF_T |
| 1705 | #endif |
| 1706 | EOF |
| 1707 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1708 | echo $ac_n "checking for mode_t""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1709 | echo "configure:1710: checking for mode_t" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1710 | if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then |
| 1711 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1712 | else |
| 1713 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1714 | #line 1715 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1715 | #include "confdefs.h" |
| 1716 | #include <sys/types.h> |
| 1717 | #if STDC_HEADERS |
| 1718 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1719 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1720 | #endif |
| 1721 | EOF |
| 1722 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1723 | 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] | 1724 | rm -rf conftest* |
| 1725 | ac_cv_type_mode_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1726 | else |
| 1727 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1728 | ac_cv_type_mode_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1729 | fi |
| 1730 | rm -f conftest* |
| 1731 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1732 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1733 | echo "$ac_t""$ac_cv_type_mode_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1734 | if test $ac_cv_type_mode_t = no; then |
| 1735 | cat >> confdefs.h <<\EOF |
| 1736 | #define mode_t int |
| 1737 | EOF |
| 1738 | |
| 1739 | fi |
| 1740 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1741 | echo $ac_n "checking for off_t""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1742 | echo "configure:1743: checking for off_t" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1743 | if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then |
| 1744 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1745 | else |
| 1746 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1747 | #line 1748 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1748 | #include "confdefs.h" |
| 1749 | #include <sys/types.h> |
| 1750 | #if STDC_HEADERS |
| 1751 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1752 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1753 | #endif |
| 1754 | EOF |
| 1755 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1756 | 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] | 1757 | rm -rf conftest* |
| 1758 | ac_cv_type_off_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1759 | else |
| 1760 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1761 | ac_cv_type_off_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1762 | fi |
| 1763 | rm -f conftest* |
| 1764 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1765 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1766 | echo "$ac_t""$ac_cv_type_off_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1767 | if test $ac_cv_type_off_t = no; then |
| 1768 | cat >> confdefs.h <<\EOF |
| 1769 | #define off_t long |
| 1770 | EOF |
| 1771 | |
| 1772 | fi |
| 1773 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1774 | echo $ac_n "checking for pid_t""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1775 | echo "configure:1776: checking for pid_t" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1776 | if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then |
| 1777 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1778 | else |
| 1779 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1780 | #line 1781 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1781 | #include "confdefs.h" |
| 1782 | #include <sys/types.h> |
| 1783 | #if STDC_HEADERS |
| 1784 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1785 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1786 | #endif |
| 1787 | EOF |
| 1788 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1789 | 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] | 1790 | rm -rf conftest* |
| 1791 | ac_cv_type_pid_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1792 | else |
| 1793 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1794 | ac_cv_type_pid_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1795 | fi |
| 1796 | rm -f conftest* |
| 1797 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1798 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1799 | echo "$ac_t""$ac_cv_type_pid_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1800 | if test $ac_cv_type_pid_t = no; then |
| 1801 | cat >> confdefs.h <<\EOF |
| 1802 | #define pid_t int |
| 1803 | EOF |
| 1804 | |
| 1805 | fi |
| 1806 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1807 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1808 | echo "configure:1809: checking return type of signal handlers" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1809 | if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then |
| 1810 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1811 | else |
| 1812 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1813 | #line 1814 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1814 | #include "confdefs.h" |
| 1815 | #include <sys/types.h> |
| 1816 | #include <signal.h> |
| 1817 | #ifdef signal |
| 1818 | #undef signal |
| 1819 | #endif |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1820 | #ifdef __cplusplus |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1821 | extern "C" void (*signal (int, void (*)(int)))(int); |
| 1822 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1823 | void (*signal ()) (); |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1824 | #endif |
| 1825 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1826 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1827 | int i; |
| 1828 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1829 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1830 | if { (eval echo configure:1831: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1831 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1832 | ac_cv_type_signal=void |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1833 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1834 | echo "configure: failed program was:" >&5 |
| 1835 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1836 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1837 | ac_cv_type_signal=int |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1838 | fi |
| 1839 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1840 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1841 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1842 | echo "$ac_t""$ac_cv_type_signal" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1843 | cat >> confdefs.h <<EOF |
| 1844 | #define RETSIGTYPE $ac_cv_type_signal |
| 1845 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1846 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1847 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1848 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1849 | echo "configure:1850: checking for size_t" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1850 | if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then |
| 1851 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1852 | else |
| 1853 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1854 | #line 1855 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1855 | #include "confdefs.h" |
| 1856 | #include <sys/types.h> |
| 1857 | #if STDC_HEADERS |
| 1858 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1859 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1860 | #endif |
| 1861 | EOF |
| 1862 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1863 | 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] | 1864 | rm -rf conftest* |
| 1865 | ac_cv_type_size_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1866 | else |
| 1867 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1868 | ac_cv_type_size_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1869 | fi |
| 1870 | rm -f conftest* |
| 1871 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1872 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1873 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1874 | if test $ac_cv_type_size_t = no; then |
| 1875 | cat >> confdefs.h <<\EOF |
| 1876 | #define size_t unsigned |
| 1877 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1878 | |
| 1879 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1880 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1881 | echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1882 | echo "configure:1883: checking for uid_t in sys/types.h" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1883 | if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then |
| 1884 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1885 | else |
| 1886 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1887 | #line 1888 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1888 | #include "confdefs.h" |
| 1889 | #include <sys/types.h> |
| 1890 | EOF |
| 1891 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1892 | egrep "uid_t" >/dev/null 2>&1; then |
| 1893 | rm -rf conftest* |
| 1894 | ac_cv_type_uid_t=yes |
| 1895 | else |
| 1896 | rm -rf conftest* |
| 1897 | ac_cv_type_uid_t=no |
| 1898 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1899 | rm -f conftest* |
| 1900 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1901 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1902 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1903 | echo "$ac_t""$ac_cv_type_uid_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1904 | if test $ac_cv_type_uid_t = no; then |
| 1905 | cat >> confdefs.h <<\EOF |
| 1906 | #define uid_t int |
| 1907 | EOF |
| 1908 | |
| 1909 | cat >> confdefs.h <<\EOF |
| 1910 | #define gid_t int |
| 1911 | EOF |
| 1912 | |
| 1913 | fi |
| 1914 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1915 | |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1916 | echo $ac_n "checking size of int""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1917 | echo "configure:1918: checking size of int" >&5 |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1918 | if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then |
| 1919 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1920 | else |
| 1921 | if test "$cross_compiling" = yes; then |
| 1922 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1923 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1924 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1925 | #line 1926 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1926 | #include "confdefs.h" |
| 1927 | #include <stdio.h> |
| 1928 | main() |
| 1929 | { |
| 1930 | FILE *f=fopen("conftestval", "w"); |
| 1931 | if (!f) exit(1); |
| 1932 | fprintf(f, "%d\n", sizeof(int)); |
| 1933 | exit(0); |
| 1934 | } |
| 1935 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1936 | if { (eval echo configure:1937: \"$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] | 1937 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1938 | ac_cv_sizeof_int=`cat conftestval` |
| 1939 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1940 | echo "configure: failed program was:" >&5 |
| 1941 | cat conftest.$ac_ext >&5 |
| 1942 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1943 | ac_cv_sizeof_int=0 |
| 1944 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1945 | rm -fr conftest* |
| 1946 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1947 | |
| 1948 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1949 | echo "$ac_t""$ac_cv_sizeof_int" 1>&6 |
| 1950 | cat >> confdefs.h <<EOF |
| 1951 | #define SIZEOF_INT $ac_cv_sizeof_int |
| 1952 | EOF |
| 1953 | |
| 1954 | |
| 1955 | echo $ac_n "checking size of long""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1956 | echo "configure:1957: checking size of long" >&5 |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1957 | if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then |
| 1958 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1959 | else |
| 1960 | if test "$cross_compiling" = yes; then |
| 1961 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1962 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1963 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1964 | #line 1965 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1965 | #include "confdefs.h" |
| 1966 | #include <stdio.h> |
| 1967 | main() |
| 1968 | { |
| 1969 | FILE *f=fopen("conftestval", "w"); |
| 1970 | if (!f) exit(1); |
| 1971 | fprintf(f, "%d\n", sizeof(long)); |
| 1972 | exit(0); |
| 1973 | } |
| 1974 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1975 | if { (eval echo configure:1976: \"$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] | 1976 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1977 | ac_cv_sizeof_long=`cat conftestval` |
| 1978 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1979 | echo "configure: failed program was:" >&5 |
| 1980 | cat conftest.$ac_ext >&5 |
| 1981 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1982 | ac_cv_sizeof_long=0 |
| 1983 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1984 | rm -fr conftest* |
| 1985 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1986 | |
| 1987 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1988 | echo "$ac_t""$ac_cv_sizeof_long" 1>&6 |
| 1989 | cat >> confdefs.h <<EOF |
| 1990 | #define SIZEOF_LONG $ac_cv_sizeof_long |
| 1991 | EOF |
| 1992 | |
| 1993 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 1994 | echo $ac_n "checking size of void *""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 1995 | echo "configure:1996: checking size of void *" >&5 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 1996 | if eval "test \"`echo '$''{'ac_cv_sizeof_void_p'+set}'`\" = set"; then |
| 1997 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1998 | else |
| 1999 | if test "$cross_compiling" = yes; then |
| 2000 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2001 | else |
| 2002 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2003 | #line 2004 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2004 | #include "confdefs.h" |
| 2005 | #include <stdio.h> |
| 2006 | main() |
| 2007 | { |
| 2008 | FILE *f=fopen("conftestval", "w"); |
| 2009 | if (!f) exit(1); |
| 2010 | fprintf(f, "%d\n", sizeof(void *)); |
| 2011 | exit(0); |
| 2012 | } |
| 2013 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2014 | if { (eval echo configure:2015: \"$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] | 2015 | then |
| 2016 | ac_cv_sizeof_void_p=`cat conftestval` |
| 2017 | else |
| 2018 | echo "configure: failed program was:" >&5 |
| 2019 | cat conftest.$ac_ext >&5 |
| 2020 | rm -fr conftest* |
| 2021 | ac_cv_sizeof_void_p=0 |
| 2022 | fi |
| 2023 | rm -fr conftest* |
| 2024 | fi |
| 2025 | |
| 2026 | fi |
| 2027 | echo "$ac_t""$ac_cv_sizeof_void_p" 1>&6 |
| 2028 | cat >> confdefs.h <<EOF |
| 2029 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
| 2030 | EOF |
| 2031 | |
| 2032 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2033 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2034 | echo $ac_n "checking for long long support""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2035 | echo "configure:2036: checking for long long support" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2036 | have_long_long=no |
| 2037 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2038 | #line 2039 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2039 | #include "confdefs.h" |
| 2040 | |
| 2041 | int main() { |
| 2042 | long long x; x = (long long)0; |
| 2043 | ; return 0; } |
| 2044 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2045 | if { (eval echo configure:2046: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2046 | rm -rf conftest* |
| 2047 | cat >> confdefs.h <<\EOF |
| 2048 | #define HAVE_LONG_LONG 1 |
| 2049 | EOF |
| 2050 | have_long_long=yes |
| 2051 | else |
| 2052 | echo "configure: failed program was:" >&5 |
| 2053 | cat conftest.$ac_ext >&5 |
| 2054 | fi |
| 2055 | rm -f conftest* |
| 2056 | echo "$ac_t""$have_long_long" 1>&6 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2057 | if test "$have_long_long" = yes ; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2058 | echo $ac_n "checking size of long long""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2059 | echo "configure:2060: checking size of long long" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2060 | if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then |
| 2061 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2062 | else |
| 2063 | if test "$cross_compiling" = yes; then |
| 2064 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2065 | else |
| 2066 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2067 | #line 2068 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2068 | #include "confdefs.h" |
| 2069 | #include <stdio.h> |
| 2070 | main() |
| 2071 | { |
| 2072 | FILE *f=fopen("conftestval", "w"); |
| 2073 | if (!f) exit(1); |
| 2074 | fprintf(f, "%d\n", sizeof(long long)); |
| 2075 | exit(0); |
| 2076 | } |
| 2077 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2078 | if { (eval echo configure:2079: \"$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] | 2079 | then |
| 2080 | ac_cv_sizeof_long_long=`cat conftestval` |
| 2081 | else |
| 2082 | echo "configure: failed program was:" >&5 |
| 2083 | cat conftest.$ac_ext >&5 |
| 2084 | rm -fr conftest* |
| 2085 | ac_cv_sizeof_long_long=0 |
| 2086 | fi |
| 2087 | rm -fr conftest* |
| 2088 | fi |
| 2089 | |
| 2090 | fi |
| 2091 | echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6 |
| 2092 | cat >> confdefs.h <<EOF |
| 2093 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
| 2094 | EOF |
| 2095 | |
| 2096 | |
| 2097 | fi |
| 2098 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2099 | # Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>. |
| 2100 | echo $ac_n "checking size of off_t""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2101 | echo "configure:2102: checking size of off_t" >&5 |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2102 | if eval "test \"`echo '$''{'ac_cv_sizeof_off_t'+set}'`\" = set"; then |
| 2103 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2104 | else |
| 2105 | if test "$cross_compiling" = yes; then |
| 2106 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2107 | else |
| 2108 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2109 | #line 2110 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2110 | #include "confdefs.h" |
| 2111 | #include <stdio.h> |
| 2112 | #include <sys/types.h> |
| 2113 | main() |
| 2114 | { |
| 2115 | FILE *f=fopen("conftestval", "w"); |
| 2116 | if (!f) exit(1); |
| 2117 | fprintf(f, "%d\n", sizeof(off_t)); |
| 2118 | exit(0); |
| 2119 | } |
| 2120 | EOF |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2121 | if { (eval echo configure:2122: \"$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] | 2122 | then |
| 2123 | ac_cv_sizeof_off_t=`cat conftestval` |
| 2124 | else |
| 2125 | echo "configure: failed program was:" >&5 |
| 2126 | cat conftest.$ac_ext >&5 |
| 2127 | rm -fr conftest* |
| 2128 | ac_cv_sizeof_off_t=0 |
| 2129 | fi |
| 2130 | rm -fr conftest* |
| 2131 | fi |
| 2132 | |
| 2133 | |
| 2134 | fi |
| 2135 | |
| 2136 | echo "$ac_t""$ac_cv_sizeof_off_t" 1>&6 |
| 2137 | cat >> confdefs.h <<EOF |
| 2138 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
| 2139 | EOF |
| 2140 | |
| 2141 | |
| 2142 | echo $ac_n "checking whether to enable large file support""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2143 | echo "configure:2144: checking whether to enable large file support" >&5 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2144 | if test "$have_long_long" = yes -a \ |
| 2145 | "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \ |
| 2146 | "$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] | 2147 | cat >> confdefs.h <<\EOF |
| 2148 | #define HAVE_LARGEFILE_SUPPORT 1 |
| 2149 | EOF |
| 2150 | |
| 2151 | echo "$ac_t""yes" 1>&6 |
| 2152 | else |
| 2153 | echo "$ac_t""no" 1>&6 |
| 2154 | fi |
| 2155 | |
| 2156 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2157 | # Minor variations in building a framework between NextStep versions 4 and 5 |
| 2158 | |
| 2159 | case $ac_sys_system/$ac_sys_release in |
| 2160 | next/4*) |
| 2161 | ns_undef_sym='__environ' |
| 2162 | LIBTOOL_CRUFT="-U $ns_undef_sym" ;; |
| 2163 | next/5*) |
| 2164 | ns_undef_sym='_environ' |
| 2165 | LIBTOOL_CRUFT="-lcc_dynamic -U $ns_undef_sym" ;; |
| 2166 | esac |
| 2167 | |
| 2168 | echo $ac_n "checking for --with-next-framework""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2169 | echo "configure:2170: checking for --with-next-framework" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2170 | if test "$with_next_framework" |
| 2171 | then |
| 2172 | OPT="$OPT -fno-common" |
| 2173 | # -U __environ is needed since bundles don't have access |
| 2174 | # to crt0 when built but will always be linked against it |
| 2175 | LDFLAGS="$LDFLAGS -Wl,-U,$ns_undef_sym" |
| 2176 | cat >> confdefs.h <<\EOF |
| 2177 | #define WITH_NEXT_FRAMEWORK 1 |
| 2178 | EOF |
| 2179 | |
| 2180 | echo "$ac_t""yes" 1>&6 |
| 2181 | else |
| 2182 | echo "$ac_t""no" 1>&6 |
| 2183 | fi |
| 2184 | |
| 2185 | echo $ac_n "checking for --with-dyld""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2186 | echo "configure:2187: checking for --with-dyld" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2187 | if test "$with_next_framework" -o "$with_dyld" |
| 2188 | then |
| 2189 | if test "$with_dyld" |
| 2190 | then |
| 2191 | echo "$ac_t""yes" 1>&6 |
| 2192 | else |
| 2193 | echo "$ac_t""required for framework build" 1>&6 |
| 2194 | fi |
| 2195 | cat >> confdefs.h <<\EOF |
| 2196 | #define WITH_DYLD 1 |
| 2197 | EOF |
| 2198 | |
| 2199 | ns_dyld='set' |
| 2200 | else |
| 2201 | echo "$ac_t""no" 1>&6 |
| 2202 | fi |
| 2203 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2204 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2205 | |
| 2206 | |
| 2207 | |
| 2208 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2209 | # SO is the extension of shared libraries `(including the dot!) |
| 2210 | # -- usually .so, .sl on HP-UX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2211 | echo $ac_n "checking SO""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2212 | echo "configure:2213: checking SO" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2213 | if test -z "$SO" |
| 2214 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2215 | case $ac_sys_system in |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2216 | hp*|HP*) SO=.sl;; |
| 2217 | *) SO=.so;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2218 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2219 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2220 | echo "$ac_t""$SO" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2221 | # LDSHARED is the ld *command* used to create shared library |
| 2222 | # -- "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] | 2223 | # (Shared libraries in this instance are shared modules to be loaded into |
| 2224 | # Python, as opposed to building Python itself as a shared library.) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2225 | echo $ac_n "checking LDSHARED""... $ac_c" 1>&6 |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 2226 | echo "configure:2227: checking LDSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2227 | if test -z "$LDSHARED" |
| 2228 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2229 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 45140f9 | 1997-08-29 18:44:06 +0000 | [diff] [blame] | 2230 | AIX*) LDSHARED="\$(srcdir)/ld_so_aix \$(CC)";; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2231 | BeOS*) LDSHARED="\$(srcdir)/../BeOS/linkmodule -L.. -lpython\$(VERSION)";; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2232 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 2233 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2234 | SunOS/4*) LDSHARED="ld";; |
| 2235 | SunOS/5*) LDSHARED="ld -G";; |
| 2236 | hp*|HP*) LDSHARED="ld -b";; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2237 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
| 2238 | DYNIX/ptx*) LDSHARED="ld -G";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2239 | next/*) |
| 2240 | if test "$ns_dyld" |
| 2241 | then LDSHARED='$(CC) $(LDFLAGS) -bundle -prebind' |
| 2242 | else LDSHARED='$(CC) $(CFLAGS) -nostdlib -r'; |
| 2243 | fi |
| 2244 | if test "$with_next_framework" ; then |
| 2245 | LDSHARED="$LDSHARED \$(LDLIBRARY)" |
| 2246 | fi ;; |
Guido van Rossum | 81652ab | 1996-07-21 02:53:27 +0000 | [diff] [blame] | 2247 | Linux*) LDSHARED="gcc -shared";; |
Guido van Rossum | 3c4bb80 | 1997-12-18 23:55:32 +0000 | [diff] [blame] | 2248 | dgux*) LDSHARED="ld -G";; |
Guido van Rossum | 458e7fa | 1999-09-17 15:40:40 +0000 | [diff] [blame] | 2249 | BSD/OS*/4*) LDSHARED="gcc -shared";; |
Guido van Rossum | a8acf72 | 1999-04-27 22:06:08 +0000 | [diff] [blame] | 2250 | FreeBSD*/[34]*) LDSHARED="gcc -shared";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2251 | FreeBSD*|OpenBSD*) LDSHARED="ld -Bshareable";; |
| 2252 | NetBSD*) |
| 2253 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 2254 | then |
| 2255 | LDSHARED="cc -shared" |
| 2256 | else |
| 2257 | LDSHARED="ld -Bshareable" |
| 2258 | fi;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2259 | SCO_SV*) LDSHARED="cc -G -KPIC -Ki486 -belf -Wl,-Bexport";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2260 | *) LDSHARED="ld";; |
| 2261 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2262 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2263 | echo "$ac_t""$LDSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2264 | # 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] | 2265 | # library (module) -- this is only needed for a few systems |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2266 | echo $ac_n "checking CCSHARED""... $ac_c" 1>&6 |
Guido van Rossum | 458e7fa | 1999-09-17 15:40:40 +0000 | [diff] [blame] | 2267 | echo "configure:2268: checking CCSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2268 | if test -z "$CCSHARED" |
| 2269 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2270 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 2271 | hp*|HP*) if test "$GCC" = yes; |
| 2272 | then CCSHARED="-fpic"; |
| 2273 | else CCSHARED="+z"; |
| 2274 | fi;; |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2275 | Linux*) CCSHARED="-fpic";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2276 | BSD/OS*/4*) CCSHARED="-fpic";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2277 | FreeBSD*|OpenBSD*) CCSHARED="-fpic";; |
| 2278 | NetBSD*) CCSHARED="-fPIC";; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2279 | SCO_SV*) CCSHARED="-KPIC -dy -Bdynamic";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2280 | IRIX*/6*) case $CC in |
| 2281 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 2282 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2283 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2284 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2285 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2286 | echo "$ac_t""$CCSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2287 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2288 | # the python executable -- this is only needed for a few systems |
| 2289 | echo $ac_n "checking LINKFORSHARED""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2290 | echo "configure:2291: checking LINKFORSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2291 | if test -z "$LINKFORSHARED" |
| 2292 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2293 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 69f6580 | 1998-03-03 21:47:00 +0000 | [diff] [blame] | 2294 | AIX*) LINKFORSHARED='-Wl,-bE:python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2295 | hp*|HP*) |
Guido van Rossum | 304dd2d | 1997-10-20 23:10:56 +0000 | [diff] [blame] | 2296 | LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2297 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | a8acf72 | 1999-04-27 22:06:08 +0000 | [diff] [blame] | 2298 | FreeBSD/[34]*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 2d9feed | 1997-11-24 17:36:21 +0000 | [diff] [blame] | 2299 | Linux*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2300 | # -u libsys_s pulls in all symbols in libsys |
| 2301 | next/2*|next/3*) LINKFORSHARED="-u libsys_s";; |
| 2302 | # -u __dummy makes the linker aware of the objc runtime |
| 2303 | # in System.framework; otherwise, __objcInit (referenced in |
| 2304 | # crt1.o) gets erroneously defined as common, which breaks dynamic |
| 2305 | # loading of any modules which reference it in System.framework |
| 2306 | next/4*|next/5*) LINKFORSHARED="-u __dummy -framework System" ;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2307 | SCO_SV*) LINKFORSHARED="-Bdynamic -dy -Wl,-Bexport";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2308 | NetBSD*) |
| 2309 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 2310 | then |
| 2311 | LINKFORSHARED="-Wl,--export-dynamic" |
| 2312 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2313 | SunOS/5*) case $CC in |
| 2314 | *gcc*) |
| 2315 | if $CC -Xlinker -V 2>/dev/null | grep BFD >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 2316 | then |
| 2317 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2318 | fi;; |
| 2319 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2320 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2321 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2322 | echo "$ac_t""$LINKFORSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2323 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2324 | # checks for libraries |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2325 | echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2326 | echo "configure:2327: checking for dlopen in -ldl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2327 | ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2328 | 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] | 2329 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2330 | else |
| 2331 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2332 | LIBS="-ldl $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2333 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2334 | #line 2335 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2335 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2336 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2337 | /* We use char because int might match the return type of a gcc2 |
| 2338 | builtin and then its argument prototype would still apply. */ |
| 2339 | char dlopen(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2340 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2341 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2342 | dlopen() |
| 2343 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2344 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2345 | if { (eval echo configure:2346: \"$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] | 2346 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2347 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2348 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2349 | echo "configure: failed program was:" >&5 |
| 2350 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2351 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2352 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2353 | fi |
| 2354 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2355 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2356 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2357 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2358 | 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] | 2359 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2360 | ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 2361 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2362 | cat >> confdefs.h <<EOF |
| 2363 | #define $ac_tr_lib 1 |
| 2364 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2365 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2366 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2367 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2368 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2369 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2370 | fi |
| 2371 | # Dynamic linking for SunOS/Solaris and SYSV |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2372 | echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2373 | echo "configure:2374: checking for shl_load in -ldld" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2374 | ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2375 | 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] | 2376 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2377 | else |
| 2378 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2379 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2380 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2381 | #line 2382 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2382 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2383 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2384 | /* We use char because int might match the return type of a gcc2 |
| 2385 | builtin and then its argument prototype would still apply. */ |
| 2386 | char shl_load(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2387 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2388 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2389 | shl_load() |
| 2390 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2391 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2392 | if { (eval echo configure:2393: \"$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] | 2393 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2394 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2395 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2396 | echo "configure: failed program was:" >&5 |
| 2397 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2398 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2399 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2400 | fi |
| 2401 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2402 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2403 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2404 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2405 | 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] | 2406 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2407 | ac_tr_lib=HAVE_LIB`echo dld | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 2408 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2409 | cat >> confdefs.h <<EOF |
| 2410 | #define $ac_tr_lib 1 |
| 2411 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2412 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2413 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2414 | |
| 2415 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2416 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2417 | fi |
| 2418 | # Dynamic linking for HP-UX |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 2419 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
| 2420 | # However on SGI IRIX, these exist but are broken. |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2421 | # BeOS' sockets are stashed in libnet. |
| 2422 | case "$ac_sys_system" in |
| 2423 | IRIX*) ;; |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 2424 | *) |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2425 | echo $ac_n "checking for t_open in -lnsl""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2426 | echo "configure:2427: checking for t_open in -lnsl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2427 | ac_lib_var=`echo nsl'_'t_open | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2428 | 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] | 2429 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2430 | else |
| 2431 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2432 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2433 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2434 | #line 2435 "configure" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2435 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2436 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2437 | /* We use char because int might match the return type of a gcc2 |
| 2438 | builtin and then its argument prototype would still apply. */ |
| 2439 | char t_open(); |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2440 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2441 | int main() { |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 2442 | t_open() |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2443 | ; return 0; } |
| 2444 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2445 | if { (eval echo configure:2446: \"$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] | 2446 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2447 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2448 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2449 | echo "configure: failed program was:" >&5 |
| 2450 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2451 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2452 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2453 | fi |
| 2454 | rm -f conftest* |
| 2455 | LIBS="$ac_save_LIBS" |
| 2456 | |
| 2457 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2458 | 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] | 2459 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2460 | LIBS="-lnsl $LIBS" |
| 2461 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2462 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2463 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 2464 | # SVR4 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2465 | echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2466 | echo "configure:2467: checking for socket in -lsocket" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2467 | ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2468 | 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] | 2469 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2470 | else |
| 2471 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2472 | LIBS="-lsocket $LIBS $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2473 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2474 | #line 2475 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2475 | #include "confdefs.h" |
| 2476 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2477 | /* We use char because int might match the return type of a gcc2 |
| 2478 | builtin and then its argument prototype would still apply. */ |
| 2479 | char socket(); |
| 2480 | |
| 2481 | int main() { |
| 2482 | socket() |
| 2483 | ; return 0; } |
| 2484 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2485 | if { (eval echo configure:2486: \"$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] | 2486 | rm -rf conftest* |
| 2487 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2488 | else |
| 2489 | echo "configure: failed program was:" >&5 |
| 2490 | cat conftest.$ac_ext >&5 |
| 2491 | rm -rf conftest* |
| 2492 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2493 | fi |
| 2494 | rm -f conftest* |
| 2495 | LIBS="$ac_save_LIBS" |
| 2496 | |
| 2497 | fi |
| 2498 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2499 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2500 | LIBS="-lsocket $LIBS" |
| 2501 | else |
| 2502 | echo "$ac_t""no" 1>&6 |
| 2503 | fi |
| 2504 | # SVR4 sockets |
| 2505 | echo $ac_n "checking for socket in -lnet""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2506 | echo "configure:2507: checking for socket in -lnet" >&5 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2507 | ac_lib_var=`echo net'_'socket | sed 'y%./+-%__p_%'` |
| 2508 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 2509 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2510 | else |
| 2511 | ac_save_LIBS="$LIBS" |
| 2512 | LIBS="-lnet $LIBS $LIBS" |
| 2513 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2514 | #line 2515 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2515 | #include "confdefs.h" |
| 2516 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2517 | /* We use char because int might match the return type of a gcc2 |
| 2518 | builtin and then its argument prototype would still apply. */ |
| 2519 | char socket(); |
| 2520 | |
| 2521 | int main() { |
| 2522 | socket() |
| 2523 | ; return 0; } |
| 2524 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2525 | if { (eval echo configure:2526: \"$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] | 2526 | rm -rf conftest* |
| 2527 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2528 | else |
| 2529 | echo "configure: failed program was:" >&5 |
| 2530 | cat conftest.$ac_ext >&5 |
| 2531 | rm -rf conftest* |
| 2532 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2533 | fi |
| 2534 | rm -f conftest* |
| 2535 | LIBS="$ac_save_LIBS" |
| 2536 | |
| 2537 | fi |
| 2538 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2539 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2540 | LIBS="-lnet $LIBS" |
| 2541 | else |
| 2542 | echo "$ac_t""no" 1>&6 |
| 2543 | fi |
| 2544 | # BeOS |
| 2545 | ;; |
| 2546 | esac |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 2547 | |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 2548 | echo $ac_n "checking for --with-libs""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2549 | echo "configure:2550: checking for --with-libs" >&5 |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 2550 | # Check whether --with-libs or --without-libs was given. |
| 2551 | if test "${with_libs+set}" = set; then |
| 2552 | withval="$with_libs" |
| 2553 | |
| 2554 | echo "$ac_t""$withval" 1>&6 |
| 2555 | LIBS="$withval $LIBS" |
| 2556 | |
| 2557 | else |
| 2558 | echo "$ac_t""no" 1>&6 |
| 2559 | fi |
| 2560 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2561 | |
Guido van Rossum | 3c83bb4 | 1996-12-31 22:35:16 +0000 | [diff] [blame] | 2562 | echo $ac_n "checking for --with(out)-readline""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2563 | echo "configure:2564: checking for --with(out)-readline" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2564 | # Check whether --with-readline or --without-readline was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2565 | if test "${with_readline+set}" = set; then |
| 2566 | withval="$with_readline" |
Guido van Rossum | b06df27 | 1997-08-05 21:50:20 +0000 | [diff] [blame] | 2567 | echo "$ac_t""$withval" 1>&6 |
| 2568 | { 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] | 2569 | else |
Guido van Rossum | b06df27 | 1997-08-05 21:50:20 +0000 | [diff] [blame] | 2570 | echo "$ac_t""not specified." 1>&6 |
Guido van Rossum | 3c83bb4 | 1996-12-31 22:35:16 +0000 | [diff] [blame] | 2571 | fi |
| 2572 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2573 | |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 2574 | |
| 2575 | USE_THREAD_MODULE="#" |
| 2576 | |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2577 | echo $ac_n "checking for --with-dec-threads""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2578 | echo "configure:2579: checking for --with-dec-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2579 | |
| 2580 | # Check whether --with-dec-threads or --without-dec-threads was given. |
| 2581 | if test "${with_dec_threads+set}" = set; then |
| 2582 | withval="$with_dec_threads" |
| 2583 | echo "$ac_t""$withval" 1>&6 |
| 2584 | LDLAST=-threads |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2585 | if test "${with_thread+set}" != set; then |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2586 | with_thread="$withval"; |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2587 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2588 | else |
| 2589 | echo "$ac_t""no" 1>&6 |
| 2590 | fi |
| 2591 | |
| 2592 | |
| 2593 | echo $ac_n "checking for --with-threads""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2594 | echo "configure:2595: checking for --with-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 2595 | # Check whether --with-threads or --without-threads was given. |
| 2596 | if test "${with_threads+set}" = set; then |
| 2597 | withval="$with_threads" |
| 2598 | echo "$ac_t""$withval" 1>&6 |
| 2599 | if test "${with_thread+set}" != set; then |
| 2600 | with_thread="$withval"; |
| 2601 | fi |
| 2602 | else |
| 2603 | echo "$ac_t""no" 1>&6 |
| 2604 | fi |
| 2605 | |
| 2606 | |
| 2607 | echo $ac_n "checking for --with-thread""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2608 | echo "configure:2609: checking for --with-thread" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2609 | # Check whether --with-thread or --without-thread was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2610 | if test "${with_thread+set}" = set; then |
| 2611 | withval="$with_thread" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2612 | |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 2613 | USE_THREAD_MODULE= |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2614 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2615 | if test -d "$withval" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2616 | then LDFLAGS="$LDFLAGS -L$withval" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2617 | fi |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 2618 | cat >> confdefs.h <<\EOF |
| 2619 | #define _REENTRANT 1 |
| 2620 | EOF |
| 2621 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2622 | ac_safe=`echo "mach/cthreads.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2623 | echo $ac_n "checking for mach/cthreads.h""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2624 | echo "configure:2625: checking for mach/cthreads.h" >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2625 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 2626 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2627 | else |
| 2628 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2629 | #line 2630 "configure" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2630 | #include "confdefs.h" |
| 2631 | #include <mach/cthreads.h> |
| 2632 | EOF |
| 2633 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2634 | { (eval echo configure:2635: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2635 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2636 | if test -z "$ac_err"; then |
| 2637 | rm -rf conftest* |
| 2638 | eval "ac_cv_header_$ac_safe=yes" |
| 2639 | else |
| 2640 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2641 | echo "configure: failed program was:" >&5 |
| 2642 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2643 | rm -rf conftest* |
| 2644 | eval "ac_cv_header_$ac_safe=no" |
| 2645 | fi |
| 2646 | rm -f conftest* |
| 2647 | fi |
| 2648 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 2649 | echo "$ac_t""yes" 1>&6 |
| 2650 | cat >> confdefs.h <<\EOF |
| 2651 | #define WITH_THREAD 1 |
| 2652 | EOF |
| 2653 | |
| 2654 | cat >> confdefs.h <<\EOF |
| 2655 | #define C_THREADS 1 |
| 2656 | EOF |
| 2657 | |
| 2658 | LIBOBJS="$LIBOBJS thread.o" |
| 2659 | else |
| 2660 | echo "$ac_t""no" 1>&6 |
| 2661 | |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2662 | echo $ac_n "checking for pthread_detach""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2663 | echo "configure:2664: checking for pthread_detach" >&5 |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2664 | 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] | 2665 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2666 | else |
| 2667 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2668 | #line 2669 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2669 | #include "confdefs.h" |
| 2670 | /* System header to define __stub macros and hopefully few prototypes, |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2671 | which can conflict with char pthread_detach(); below. */ |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2672 | #include <assert.h> |
| 2673 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2674 | /* We use char because int might match the return type of a gcc2 |
| 2675 | builtin and then its argument prototype would still apply. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2676 | char pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2677 | |
| 2678 | int main() { |
| 2679 | |
| 2680 | /* The GNU C library defines this for functions which it implements |
| 2681 | to always fail with ENOSYS. Some functions are actually named |
| 2682 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2683 | #if defined (__stub_pthread_detach) || defined (__stub___pthread_detach) |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2684 | choke me |
| 2685 | #else |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2686 | pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2687 | #endif |
| 2688 | |
| 2689 | ; return 0; } |
| 2690 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2691 | if { (eval echo configure:2692: \"$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] | 2692 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2693 | eval "ac_cv_func_pthread_detach=yes" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2694 | else |
| 2695 | echo "configure: failed program was:" >&5 |
| 2696 | cat conftest.$ac_ext >&5 |
| 2697 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2698 | eval "ac_cv_func_pthread_detach=no" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2699 | fi |
| 2700 | rm -f conftest* |
| 2701 | fi |
| 2702 | |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 2703 | if eval "test \"`echo '$ac_cv_func_'pthread_detach`\" = yes"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2704 | echo "$ac_t""yes" 1>&6 |
| 2705 | cat >> confdefs.h <<\EOF |
| 2706 | #define WITH_THREAD 1 |
| 2707 | EOF |
| 2708 | |
| 2709 | cat >> confdefs.h <<\EOF |
| 2710 | #define _POSIX_THREADS 1 |
| 2711 | EOF |
| 2712 | |
| 2713 | LIBOBJS="$LIBOBJS thread.o" |
| 2714 | else |
| 2715 | echo "$ac_t""no" 1>&6 |
| 2716 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2717 | ac_safe=`echo "kernel/OS.h" | sed 'y%./+-%__p_%'` |
| 2718 | echo $ac_n "checking for kernel/OS.h""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2719 | echo "configure:2720: checking for kernel/OS.h" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2720 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 2721 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2722 | else |
| 2723 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2724 | #line 2725 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2725 | #include "confdefs.h" |
| 2726 | #include <kernel/OS.h> |
| 2727 | EOF |
| 2728 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2729 | { (eval echo configure:2730: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2730 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2731 | if test -z "$ac_err"; then |
| 2732 | rm -rf conftest* |
| 2733 | eval "ac_cv_header_$ac_safe=yes" |
| 2734 | else |
| 2735 | echo "$ac_err" >&5 |
| 2736 | echo "configure: failed program was:" >&5 |
| 2737 | cat conftest.$ac_ext >&5 |
| 2738 | rm -rf conftest* |
| 2739 | eval "ac_cv_header_$ac_safe=no" |
| 2740 | fi |
| 2741 | rm -f conftest* |
| 2742 | fi |
| 2743 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 2744 | echo "$ac_t""yes" 1>&6 |
| 2745 | cat >> confdefs.h <<\EOF |
| 2746 | #define WITH_THREAD 1 |
| 2747 | EOF |
| 2748 | |
| 2749 | cat >> confdefs.h <<\EOF |
| 2750 | #define BEOS_THREADS 1 |
| 2751 | EOF |
| 2752 | |
| 2753 | LIBOBJS="$LIBOBJS thread.o" |
| 2754 | else |
| 2755 | echo "$ac_t""no" 1>&6 |
| 2756 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2757 | echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2758 | echo "configure:2759: checking for pthread_create in -lpthreads" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2759 | ac_lib_var=`echo pthreads'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2760 | 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] | 2761 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2762 | else |
| 2763 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2764 | LIBS="-lpthreads $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2765 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2766 | #line 2767 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2767 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2768 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2769 | /* We use char because int might match the return type of a gcc2 |
| 2770 | builtin and then its argument prototype would still apply. */ |
| 2771 | char pthread_create(); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2772 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2773 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2774 | pthread_create() |
| 2775 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2776 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2777 | if { (eval echo configure:2778: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2778 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2779 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2780 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2781 | echo "configure: failed program was:" >&5 |
| 2782 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2783 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2784 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2785 | fi |
| 2786 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2787 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2788 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2789 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2790 | 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] | 2791 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2792 | cat >> confdefs.h <<\EOF |
| 2793 | #define WITH_THREAD 1 |
| 2794 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2795 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2796 | cat >> confdefs.h <<\EOF |
| 2797 | #define _POSIX_THREADS 1 |
| 2798 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2799 | |
| 2800 | LIBS="$LIBS -lpthreads" |
| 2801 | LIBOBJS="$LIBOBJS thread.o" |
| 2802 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2803 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2804 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2805 | echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2806 | echo "configure:2807: checking for pthread_create in -lpthread" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2807 | ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2808 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 2809 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2810 | else |
| 2811 | ac_save_LIBS="$LIBS" |
| 2812 | LIBS="-lpthread $LIBS" |
| 2813 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2814 | #line 2815 "configure" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2815 | #include "confdefs.h" |
| 2816 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2817 | /* We use char because int might match the return type of a gcc2 |
| 2818 | builtin and then its argument prototype would still apply. */ |
| 2819 | char pthread_create(); |
| 2820 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2821 | int main() { |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2822 | pthread_create() |
| 2823 | ; return 0; } |
| 2824 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2825 | if { (eval echo configure:2826: \"$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] | 2826 | rm -rf conftest* |
| 2827 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2828 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2829 | echo "configure: failed program was:" >&5 |
| 2830 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2831 | rm -rf conftest* |
| 2832 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2833 | fi |
| 2834 | rm -f conftest* |
| 2835 | LIBS="$ac_save_LIBS" |
| 2836 | |
| 2837 | fi |
| 2838 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2839 | echo "$ac_t""yes" 1>&6 |
| 2840 | cat >> confdefs.h <<\EOF |
| 2841 | #define WITH_THREAD 1 |
| 2842 | EOF |
| 2843 | |
| 2844 | cat >> confdefs.h <<\EOF |
| 2845 | #define _POSIX_THREADS 1 |
| 2846 | EOF |
| 2847 | |
| 2848 | LIBS="$LIBS -lpthread" |
| 2849 | LIBOBJS="$LIBOBJS thread.o" |
| 2850 | else |
| 2851 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 2852 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 2853 | echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2854 | echo "configure:2855: checking for pthread_create in -lc_r" >&5 |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 2855 | ac_lib_var=`echo c_r'_'pthread_create | sed 'y%./+-%__p_%'` |
| 2856 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 2857 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2858 | else |
| 2859 | ac_save_LIBS="$LIBS" |
| 2860 | LIBS="-lc_r $LIBS" |
| 2861 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2862 | #line 2863 "configure" |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 2863 | #include "confdefs.h" |
| 2864 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2865 | /* We use char because int might match the return type of a gcc2 |
| 2866 | builtin and then its argument prototype would still apply. */ |
| 2867 | char pthread_create(); |
| 2868 | |
| 2869 | int main() { |
| 2870 | pthread_create() |
| 2871 | ; return 0; } |
| 2872 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2873 | if { (eval echo configure:2874: \"$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] | 2874 | rm -rf conftest* |
| 2875 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2876 | else |
| 2877 | echo "configure: failed program was:" >&5 |
| 2878 | cat conftest.$ac_ext >&5 |
| 2879 | rm -rf conftest* |
| 2880 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2881 | fi |
| 2882 | rm -f conftest* |
| 2883 | LIBS="$ac_save_LIBS" |
| 2884 | |
| 2885 | fi |
| 2886 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2887 | echo "$ac_t""yes" 1>&6 |
| 2888 | cat >> confdefs.h <<\EOF |
| 2889 | #define WITH_THREAD 1 |
| 2890 | EOF |
| 2891 | |
| 2892 | cat >> confdefs.h <<\EOF |
| 2893 | #define _POSIX_THREADS 1 |
| 2894 | EOF |
| 2895 | |
| 2896 | LIBS="$LIBS -lc_r" |
| 2897 | LIBOBJS="$LIBOBJS thread.o" |
| 2898 | else |
| 2899 | echo "$ac_t""no" 1>&6 |
| 2900 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 2901 | echo $ac_n "checking for __d6_pthread_create in -lthread""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2902 | echo "configure:2903: checking for __d6_pthread_create in -lthread" >&5 |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 2903 | ac_lib_var=`echo thread'_'__d6_pthread_create | sed 'y%./+-%__p_%'` |
| 2904 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 2905 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2906 | else |
| 2907 | ac_save_LIBS="$LIBS" |
| 2908 | LIBS="-lthread $LIBS" |
| 2909 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2910 | #line 2911 "configure" |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 2911 | #include "confdefs.h" |
| 2912 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2913 | /* We use char because int might match the return type of a gcc2 |
| 2914 | builtin and then its argument prototype would still apply. */ |
| 2915 | char __d6_pthread_create(); |
| 2916 | |
| 2917 | int main() { |
| 2918 | __d6_pthread_create() |
| 2919 | ; return 0; } |
| 2920 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2921 | if { (eval echo configure:2922: \"$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] | 2922 | rm -rf conftest* |
| 2923 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2924 | else |
| 2925 | echo "configure: failed program was:" >&5 |
| 2926 | cat conftest.$ac_ext >&5 |
| 2927 | rm -rf conftest* |
| 2928 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2929 | fi |
| 2930 | rm -f conftest* |
| 2931 | LIBS="$ac_save_LIBS" |
| 2932 | |
| 2933 | fi |
| 2934 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2935 | echo "$ac_t""yes" 1>&6 |
| 2936 | cat >> confdefs.h <<\EOF |
| 2937 | #define WITH_THREAD 1 |
| 2938 | EOF |
| 2939 | |
| 2940 | cat >> confdefs.h <<\EOF |
| 2941 | #define _POSIX_THREADS 1 |
| 2942 | EOF |
| 2943 | |
| 2944 | LIBS="$LIBS -lthread" |
| 2945 | LIBOBJS="$LIBOBJS thread.o" |
| 2946 | else |
| 2947 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 2948 | |
| 2949 | echo $ac_n "checking for pthread_create in -lcma""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2950 | echo "configure:2951: checking for pthread_create in -lcma" >&5 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 2951 | ac_lib_var=`echo cma'_'pthread_create | sed 'y%./+-%__p_%'` |
| 2952 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 2953 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2954 | else |
| 2955 | ac_save_LIBS="$LIBS" |
| 2956 | LIBS="-lcma $LIBS" |
| 2957 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2958 | #line 2959 "configure" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 2959 | #include "confdefs.h" |
| 2960 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2961 | /* We use char because int might match the return type of a gcc2 |
| 2962 | builtin and then its argument prototype would still apply. */ |
| 2963 | char pthread_create(); |
| 2964 | |
| 2965 | int main() { |
| 2966 | pthread_create() |
| 2967 | ; return 0; } |
| 2968 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2969 | if { (eval echo configure:2970: \"$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] | 2970 | rm -rf conftest* |
| 2971 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2972 | else |
| 2973 | echo "configure: failed program was:" >&5 |
| 2974 | cat conftest.$ac_ext >&5 |
| 2975 | rm -rf conftest* |
| 2976 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2977 | fi |
| 2978 | rm -f conftest* |
| 2979 | LIBS="$ac_save_LIBS" |
| 2980 | |
| 2981 | fi |
| 2982 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2983 | echo "$ac_t""yes" 1>&6 |
| 2984 | cat >> confdefs.h <<\EOF |
| 2985 | #define WITH_THREAD 1 |
| 2986 | EOF |
| 2987 | |
| 2988 | cat >> confdefs.h <<\EOF |
| 2989 | #define _POSIX_THREADS 1 |
| 2990 | EOF |
| 2991 | |
| 2992 | LIBS="$LIBS -lcma" |
| 2993 | LIBOBJS="$LIBOBJS thread.o" |
| 2994 | else |
| 2995 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2996 | fi |
| 2997 | |
| 2998 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2999 | fi |
| 3000 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3001 | fi |
| 3002 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3003 | fi |
| 3004 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3005 | fi |
| 3006 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3007 | fi |
| 3008 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3009 | fi |
| 3010 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3011 | fi |
| 3012 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3013 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3014 | echo $ac_n "checking for usconfig in -lmpc""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3015 | echo "configure:3016: checking for usconfig in -lmpc" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3016 | ac_lib_var=`echo mpc'_'usconfig | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3017 | 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] | 3018 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3019 | else |
| 3020 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3021 | LIBS="-lmpc $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3022 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3023 | #line 3024 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3024 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3025 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3026 | /* We use char because int might match the return type of a gcc2 |
| 3027 | builtin and then its argument prototype would still apply. */ |
| 3028 | char usconfig(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3029 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3030 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3031 | usconfig() |
| 3032 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3033 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3034 | if { (eval echo configure:3035: \"$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] | 3035 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3036 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3037 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3038 | echo "configure: failed program was:" >&5 |
| 3039 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3040 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3041 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3042 | fi |
| 3043 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3044 | LIBS="$ac_save_LIBS" |
| 3045 | |
| 3046 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3047 | 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] | 3048 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3049 | cat >> confdefs.h <<\EOF |
| 3050 | #define WITH_THREAD 1 |
| 3051 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3052 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3053 | LIBS="$LIBS -lmpc" |
| 3054 | LIBOBJS="$LIBOBJS thread.o" |
| 3055 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3056 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3057 | fi |
| 3058 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3059 | echo $ac_n "checking for thr_create in -lthread""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3060 | echo "configure:3061: checking for thr_create in -lthread" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3061 | ac_lib_var=`echo thread'_'thr_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3062 | 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] | 3063 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3064 | else |
| 3065 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3066 | LIBS="-lthread $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3067 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3068 | #line 3069 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3069 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3070 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3071 | /* We use char because int might match the return type of a gcc2 |
| 3072 | builtin and then its argument prototype would still apply. */ |
| 3073 | char thr_create(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3074 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3075 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3076 | thr_create() |
| 3077 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3078 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3079 | if { (eval echo configure:3080: \"$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] | 3080 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3081 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3082 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3083 | echo "configure: failed program was:" >&5 |
| 3084 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3085 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3086 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3087 | fi |
| 3088 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3089 | LIBS="$ac_save_LIBS" |
| 3090 | |
| 3091 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3092 | 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] | 3093 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3094 | cat >> confdefs.h <<\EOF |
| 3095 | #define WITH_THREAD 1 |
| 3096 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3097 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3098 | LIBS="$LIBS -lthread" |
| 3099 | LIBOBJS="$LIBOBJS thread.o" |
| 3100 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3101 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3102 | fi |
| 3103 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3104 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3105 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3106 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3107 | fi |
| 3108 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3109 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3110 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3111 | |
| 3112 | DLINCLDIR=/ |
| 3113 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3114 | echo $ac_n "checking for --with-sgi-dl""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3115 | echo "configure:3116: checking for --with-sgi-dl" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3116 | # Check whether --with-sgi-dl or --without-sgi-dl was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3117 | if test "${with_sgi_dl+set}" = set; then |
| 3118 | withval="$with_sgi_dl" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3119 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3120 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3121 | cat >> confdefs.h <<\EOF |
| 3122 | #define WITH_SGI_DL 1 |
| 3123 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3124 | |
| 3125 | dldir=$withval |
| 3126 | if test -d "$dldir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 3127 | then LDFLAGS="$LDFLAGS -L$dldir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3128 | 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] | 3129 | fi |
| 3130 | DLINCLDIR=${dldir} |
| 3131 | LIBS="$LIBS -ldl -lmld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3132 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3133 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3134 | fi |
| 3135 | |
| 3136 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3137 | echo $ac_n "checking for --with-dl-dld""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3138 | echo "configure:3139: checking for --with-dl-dld" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3139 | # Check whether --with-dl-dld or --without-dl-dld was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3140 | if test "${with_dl_dld+set}" = set; then |
| 3141 | withval="$with_dl_dld" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3142 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3143 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3144 | cat >> confdefs.h <<\EOF |
| 3145 | #define WITH_DL_DLD 1 |
| 3146 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3147 | |
| 3148 | dldir=`echo "$withval" | sed 's/,.*//'` |
| 3149 | dlddir=`echo "$withval" | sed 's/.*,//'` |
| 3150 | if test -d "$dldir" -a -d "$dlddir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 3151 | then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3152 | 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] | 3153 | fi |
| 3154 | DLINCLDIR=${dldir} |
| 3155 | LIBS="$LIBS -ldl -ldld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3156 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3157 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3158 | fi |
| 3159 | |
| 3160 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3161 | # checks for library functions |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 3162 | for ac_func in alarm chown clock dlopen execv flock fork \ |
| 3163 | fsync fdatasync ftime ftruncate \ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 3164 | getpeername getpgrp getpid getpwent gettimeofday getwd \ |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3165 | kill link lstat mkfifo mktime nice pause plock pthread_init putenv readlink \ |
Guido van Rossum | 9601315 | 1997-10-08 22:47:52 +0000 | [diff] [blame] | 3166 | select setgid setlocale setuid setsid setpgid setpgrp setvbuf \ |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 3167 | sigaction siginterrupt sigrelse strftime strptime symlink \ |
Guido van Rossum | 08d6be4 | 1998-06-11 15:19:05 +0000 | [diff] [blame] | 3168 | tcgetpgrp tcsetpgrp timegm times truncate uname waitpid |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3169 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3170 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3171 | echo "configure:3172: checking for $ac_func" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3172 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 3173 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3174 | else |
| 3175 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3176 | #line 3177 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3177 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3178 | /* System header to define __stub macros and hopefully few prototypes, |
| 3179 | which can conflict with char $ac_func(); below. */ |
| 3180 | #include <assert.h> |
| 3181 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3182 | /* We use char because int might match the return type of a gcc2 |
| 3183 | builtin and then its argument prototype would still apply. */ |
| 3184 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3185 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3186 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3187 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3188 | /* The GNU C library defines this for functions which it implements |
| 3189 | to always fail with ENOSYS. Some functions are actually named |
| 3190 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3191 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3192 | choke me |
| 3193 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3194 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3195 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3196 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3197 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3198 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3199 | if { (eval echo configure:3200: \"$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] | 3200 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3201 | eval "ac_cv_func_$ac_func=yes" |
| 3202 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3203 | echo "configure: failed program was:" >&5 |
| 3204 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3205 | rm -rf conftest* |
| 3206 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3207 | fi |
| 3208 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3209 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3210 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3211 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3212 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3213 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3214 | cat >> confdefs.h <<EOF |
| 3215 | #define $ac_tr_func 1 |
| 3216 | EOF |
| 3217 | |
| 3218 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3219 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3220 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3221 | done |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3222 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 3223 | |
| 3224 | # check for long file support functions |
| 3225 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3226 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3227 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3228 | echo "configure:3229: checking for $ac_func" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3229 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 3230 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3231 | else |
| 3232 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3233 | #line 3234 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3234 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3235 | /* System header to define __stub macros and hopefully few prototypes, |
| 3236 | which can conflict with char $ac_func(); below. */ |
| 3237 | #include <assert.h> |
| 3238 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3239 | /* We use char because int might match the return type of a gcc2 |
| 3240 | builtin and then its argument prototype would still apply. */ |
| 3241 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3242 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3243 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3244 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3245 | /* The GNU C library defines this for functions which it implements |
| 3246 | to always fail with ENOSYS. Some functions are actually named |
| 3247 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3248 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3249 | choke me |
| 3250 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3251 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3252 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3253 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3254 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3255 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3256 | if { (eval echo configure:3257: \"$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] | 3257 | rm -rf conftest* |
| 3258 | eval "ac_cv_func_$ac_func=yes" |
| 3259 | else |
| 3260 | echo "configure: failed program was:" >&5 |
| 3261 | cat conftest.$ac_ext >&5 |
| 3262 | rm -rf conftest* |
| 3263 | eval "ac_cv_func_$ac_func=no" |
| 3264 | fi |
| 3265 | rm -f conftest* |
| 3266 | fi |
| 3267 | |
| 3268 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 3269 | echo "$ac_t""yes" 1>&6 |
| 3270 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 3271 | cat >> confdefs.h <<EOF |
| 3272 | #define $ac_tr_func 1 |
| 3273 | EOF |
| 3274 | |
| 3275 | else |
| 3276 | echo "$ac_t""no" 1>&6 |
| 3277 | fi |
| 3278 | done |
| 3279 | |
| 3280 | |
| 3281 | for ac_func in dup2 getcwd strdup strerror memmove |
| 3282 | do |
| 3283 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3284 | echo "configure:3285: checking for $ac_func" >&5 |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 3285 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 3286 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3287 | else |
| 3288 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3289 | #line 3290 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 3290 | #include "confdefs.h" |
| 3291 | /* System header to define __stub macros and hopefully few prototypes, |
| 3292 | which can conflict with char $ac_func(); below. */ |
| 3293 | #include <assert.h> |
| 3294 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3295 | /* We use char because int might match the return type of a gcc2 |
| 3296 | builtin and then its argument prototype would still apply. */ |
| 3297 | char $ac_func(); |
| 3298 | |
| 3299 | int main() { |
| 3300 | |
| 3301 | /* The GNU C library defines this for functions which it implements |
| 3302 | to always fail with ENOSYS. Some functions are actually named |
| 3303 | something starting with __ and the normal name is an alias. */ |
| 3304 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 3305 | choke me |
| 3306 | #else |
| 3307 | $ac_func(); |
| 3308 | #endif |
| 3309 | |
| 3310 | ; return 0; } |
| 3311 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +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 | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3313 | rm -rf conftest* |
| 3314 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +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 | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3318 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3319 | eval "ac_cv_func_$ac_func=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 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3323 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3324 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3325 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3326 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 3327 | cat >> confdefs.h <<EOF |
| 3328 | #define $ac_tr_func 1 |
| 3329 | EOF |
| 3330 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3331 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3332 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3333 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3334 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3335 | done |
| 3336 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3337 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3338 | echo $ac_n "checking for getpgrp""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3339 | echo "configure:3340: checking for getpgrp" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3340 | if eval "test \"`echo '$''{'ac_cv_func_getpgrp'+set}'`\" = set"; then |
| 3341 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3342 | else |
| 3343 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3344 | #line 3345 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3345 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3346 | /* System header to define __stub macros and hopefully few prototypes, |
| 3347 | which can conflict with char getpgrp(); below. */ |
| 3348 | #include <assert.h> |
| 3349 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3350 | /* We use char because int might match the return type of a gcc2 |
| 3351 | builtin and then its argument prototype would still apply. */ |
| 3352 | char getpgrp(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3353 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3354 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3355 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3356 | /* The GNU C library defines this for functions which it implements |
| 3357 | to always fail with ENOSYS. Some functions are actually named |
| 3358 | something starting with __ and the normal name is an alias. */ |
| 3359 | #if defined (__stub_getpgrp) || defined (__stub___getpgrp) |
| 3360 | choke me |
| 3361 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3362 | getpgrp(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3363 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3364 | |
| 3365 | ; return 0; } |
| 3366 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3367 | if { (eval echo configure:3368: \"$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] | 3368 | rm -rf conftest* |
| 3369 | eval "ac_cv_func_getpgrp=yes" |
| 3370 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3371 | echo "configure: failed program was:" >&5 |
| 3372 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3373 | rm -rf conftest* |
| 3374 | eval "ac_cv_func_getpgrp=no" |
| 3375 | fi |
| 3376 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3377 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3378 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3379 | if eval "test \"`echo '$ac_cv_func_'getpgrp`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3380 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3381 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3382 | #line 3383 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3383 | #include "confdefs.h" |
| 3384 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3385 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3386 | getpgrp(0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3387 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3388 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3389 | if { (eval echo configure:3390: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3390 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3391 | cat >> confdefs.h <<\EOF |
| 3392 | #define GETPGRP_HAVE_ARG 1 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3393 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3394 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3395 | else |
| 3396 | echo "configure: failed program was:" >&5 |
| 3397 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3398 | fi |
| 3399 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3400 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3401 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3402 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3403 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3404 | echo $ac_n "checking for setpgrp""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3405 | echo "configure:3406: checking for setpgrp" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3406 | if eval "test \"`echo '$''{'ac_cv_func_setpgrp'+set}'`\" = set"; then |
| 3407 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3408 | else |
| 3409 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3410 | #line 3411 "configure" |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3411 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3412 | /* System header to define __stub macros and hopefully few prototypes, |
| 3413 | which can conflict with char setpgrp(); below. */ |
| 3414 | #include <assert.h> |
| 3415 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3416 | /* We use char because int might match the return type of a gcc2 |
| 3417 | builtin and then its argument prototype would still apply. */ |
| 3418 | char setpgrp(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3419 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3420 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3421 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3422 | /* The GNU C library defines this for functions which it implements |
| 3423 | to always fail with ENOSYS. Some functions are actually named |
| 3424 | something starting with __ and the normal name is an alias. */ |
| 3425 | #if defined (__stub_setpgrp) || defined (__stub___setpgrp) |
| 3426 | choke me |
| 3427 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3428 | setpgrp(); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3429 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3430 | |
| 3431 | ; return 0; } |
| 3432 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3433 | if { (eval echo configure:3434: \"$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] | 3434 | rm -rf conftest* |
| 3435 | eval "ac_cv_func_setpgrp=yes" |
| 3436 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3437 | echo "configure: failed program was:" >&5 |
| 3438 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3439 | rm -rf conftest* |
| 3440 | eval "ac_cv_func_setpgrp=no" |
| 3441 | fi |
| 3442 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3443 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3444 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3445 | if eval "test \"`echo '$ac_cv_func_'setpgrp`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3446 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3447 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3448 | #line 3449 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3449 | #include "confdefs.h" |
| 3450 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3451 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3452 | setpgrp(0,0); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3453 | ; return 0; } |
| 3454 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3455 | if { (eval echo configure:3456: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3456 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3457 | cat >> confdefs.h <<\EOF |
| 3458 | #define SETPGRP_HAVE_ARG 1 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3459 | EOF |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3460 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3461 | else |
| 3462 | echo "configure: failed program was:" >&5 |
| 3463 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3464 | fi |
| 3465 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3466 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3467 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3468 | fi |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 3469 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3470 | echo $ac_n "checking for gettimeofday""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3471 | echo "configure:3472: checking for gettimeofday" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3472 | if eval "test \"`echo '$''{'ac_cv_func_gettimeofday'+set}'`\" = set"; then |
| 3473 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3474 | else |
| 3475 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3476 | #line 3477 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3477 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3478 | /* System header to define __stub macros and hopefully few prototypes, |
| 3479 | which can conflict with char gettimeofday(); below. */ |
| 3480 | #include <assert.h> |
| 3481 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3482 | /* We use char because int might match the return type of a gcc2 |
| 3483 | builtin and then its argument prototype would still apply. */ |
| 3484 | char gettimeofday(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3485 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3486 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3487 | |
| 3488 | /* The GNU C library defines this for functions which it implements |
| 3489 | to always fail with ENOSYS. Some functions are actually named |
| 3490 | something starting with __ and the normal name is an alias. */ |
| 3491 | #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday) |
| 3492 | choke me |
| 3493 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3494 | gettimeofday(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3495 | #endif |
| 3496 | |
| 3497 | ; return 0; } |
| 3498 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3499 | if { (eval echo configure:3500: \"$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] | 3500 | rm -rf conftest* |
| 3501 | eval "ac_cv_func_gettimeofday=yes" |
| 3502 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3503 | echo "configure: failed program was:" >&5 |
| 3504 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3505 | rm -rf conftest* |
| 3506 | eval "ac_cv_func_gettimeofday=no" |
| 3507 | fi |
| 3508 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3509 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3510 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3511 | if eval "test \"`echo '$ac_cv_func_'gettimeofday`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3512 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3513 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3514 | #line 3515 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3515 | #include "confdefs.h" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3516 | #include <sys/time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3517 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3518 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
| 3519 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3520 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3521 | if { (eval echo configure:3522: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3522 | : |
| 3523 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3524 | echo "configure: failed program was:" >&5 |
| 3525 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3526 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3527 | cat >> confdefs.h <<\EOF |
| 3528 | #define GETTIMEOFDAY_NO_TZ 1 |
| 3529 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3530 | |
| 3531 | fi |
| 3532 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3533 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3534 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3535 | fi |
| 3536 | |
| 3537 | |
| 3538 | # checks for structures |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3539 | echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3540 | echo "configure:3541: 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] | 3541 | if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then |
| 3542 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3543 | else |
| 3544 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3545 | #line 3546 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3546 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3547 | #include <sys/types.h> |
| 3548 | #include <sys/time.h> |
| 3549 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3550 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3551 | struct tm *tp; |
| 3552 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3553 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3554 | if { (eval echo configure:3555: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3555 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3556 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3557 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3558 | echo "configure: failed program was:" >&5 |
| 3559 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3560 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3561 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3562 | fi |
| 3563 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3564 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3565 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3566 | echo "$ac_t""$ac_cv_header_time" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3567 | if test $ac_cv_header_time = yes; then |
| 3568 | cat >> confdefs.h <<\EOF |
| 3569 | #define TIME_WITH_SYS_TIME 1 |
| 3570 | EOF |
| 3571 | |
| 3572 | fi |
| 3573 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3574 | echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3575 | echo "configure:3576: 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] | 3576 | if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then |
| 3577 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3578 | else |
| 3579 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3580 | #line 3581 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3581 | #include "confdefs.h" |
| 3582 | #include <sys/types.h> |
| 3583 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3584 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3585 | struct tm *tp; tp->tm_sec; |
| 3586 | ; return 0; } |
| 3587 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3588 | if { (eval echo configure:3589: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3589 | rm -rf conftest* |
| 3590 | ac_cv_struct_tm=time.h |
| 3591 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3592 | echo "configure: failed program was:" >&5 |
| 3593 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3594 | rm -rf conftest* |
| 3595 | ac_cv_struct_tm=sys/time.h |
| 3596 | fi |
| 3597 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3598 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3599 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3600 | echo "$ac_t""$ac_cv_struct_tm" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3601 | if test $ac_cv_struct_tm = sys/time.h; then |
| 3602 | cat >> confdefs.h <<\EOF |
| 3603 | #define TM_IN_SYS_TIME 1 |
| 3604 | EOF |
| 3605 | |
| 3606 | fi |
| 3607 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3608 | echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3609 | echo "configure:3610: checking for tm_zone in struct tm" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3610 | if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then |
| 3611 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3612 | else |
| 3613 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3614 | #line 3615 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3615 | #include "confdefs.h" |
| 3616 | #include <sys/types.h> |
| 3617 | #include <$ac_cv_struct_tm> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3618 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3619 | struct tm tm; tm.tm_zone; |
| 3620 | ; return 0; } |
| 3621 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3622 | if { (eval echo configure:3623: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3623 | rm -rf conftest* |
| 3624 | ac_cv_struct_tm_zone=yes |
| 3625 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3626 | echo "configure: failed program was:" >&5 |
| 3627 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3628 | rm -rf conftest* |
| 3629 | ac_cv_struct_tm_zone=no |
| 3630 | fi |
| 3631 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3632 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3633 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3634 | echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3635 | if test "$ac_cv_struct_tm_zone" = yes; then |
| 3636 | cat >> confdefs.h <<\EOF |
| 3637 | #define HAVE_TM_ZONE 1 |
| 3638 | EOF |
| 3639 | |
| 3640 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3641 | echo $ac_n "checking for tzname""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3642 | echo "configure:3643: checking for tzname" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3643 | if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then |
| 3644 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3645 | else |
| 3646 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3647 | #line 3648 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3648 | #include "confdefs.h" |
| 3649 | #include <time.h> |
| 3650 | #ifndef tzname /* For SGI. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3651 | extern char *tzname[]; /* RS6000 and others reject char **tzname. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3652 | #endif |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3653 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3654 | atoi(*tzname); |
| 3655 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3656 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3657 | if { (eval echo configure:3658: \"$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] | 3658 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3659 | ac_cv_var_tzname=yes |
| 3660 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3661 | echo "configure: failed program was:" >&5 |
| 3662 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3663 | rm -rf conftest* |
| 3664 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3665 | fi |
| 3666 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3667 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3668 | |
| 3669 | echo "$ac_t""$ac_cv_var_tzname" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3670 | if test $ac_cv_var_tzname = yes; then |
| 3671 | cat >> confdefs.h <<\EOF |
| 3672 | #define HAVE_TZNAME 1 |
| 3673 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3674 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3675 | fi |
| 3676 | fi |
| 3677 | |
| 3678 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3679 | echo $ac_n "checking for time.h that defines altzone""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3680 | echo "configure:3681: checking for time.h that defines altzone" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3681 | if eval "test \"`echo '$''{'ac_cv_header_time_altzone'+set}'`\" = set"; then |
| 3682 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3683 | else |
| 3684 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3685 | #line 3686 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3686 | #include "confdefs.h" |
| 3687 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3688 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3689 | return altzone; |
| 3690 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3691 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3692 | if { (eval echo configure:3693: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3693 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3694 | ac_cv_header_time_altzone=yes |
| 3695 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3696 | echo "configure: failed program was:" >&5 |
| 3697 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3698 | rm -rf conftest* |
| 3699 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3700 | fi |
| 3701 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3702 | fi |
| 3703 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3704 | echo "$ac_t""$ac_cv_header_time_altzone" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3705 | if test $ac_cv_header_time_altzone = yes; then |
| 3706 | cat >> confdefs.h <<\EOF |
| 3707 | #define HAVE_ALTZONE 1 |
| 3708 | EOF |
| 3709 | |
| 3710 | fi |
| 3711 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3712 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3713 | echo $ac_n "checking whether sys/select.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3714 | echo "configure:3715: 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] | 3715 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3716 | #line 3717 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3717 | #include "confdefs.h" |
| 3718 | |
| 3719 | #include <sys/types.h> |
| 3720 | #include <sys/select.h> |
| 3721 | #include <sys/time.h> |
| 3722 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3723 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3724 | ; |
| 3725 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3726 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3727 | if { (eval echo configure:3728: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3728 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3729 | cat >> confdefs.h <<\EOF |
| 3730 | #define SYS_SELECT_WITH_SYS_TIME 1 |
| 3731 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3732 | was_it_defined=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3733 | else |
| 3734 | echo "configure: failed program was:" >&5 |
| 3735 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3736 | fi |
| 3737 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3738 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3739 | |
| 3740 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3741 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3742 | echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3743 | echo "configure:3744: checking whether char is unsigned" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3744 | if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then |
| 3745 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3746 | else |
| 3747 | if test "$GCC" = yes; then |
| 3748 | # GCC predefines this symbol on systems where it applies. |
| 3749 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3750 | #line 3751 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3751 | #include "confdefs.h" |
| 3752 | #ifdef __CHAR_UNSIGNED__ |
| 3753 | yes |
| 3754 | #endif |
| 3755 | |
| 3756 | EOF |
| 3757 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 3758 | egrep "yes" >/dev/null 2>&1; then |
| 3759 | rm -rf conftest* |
| 3760 | ac_cv_c_char_unsigned=yes |
| 3761 | else |
| 3762 | rm -rf conftest* |
| 3763 | ac_cv_c_char_unsigned=no |
| 3764 | fi |
| 3765 | rm -f conftest* |
| 3766 | |
| 3767 | else |
| 3768 | if test "$cross_compiling" = yes; then |
| 3769 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 3770 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3771 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3772 | #line 3773 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3773 | #include "confdefs.h" |
| 3774 | /* volatile prevents gcc2 from optimizing the test away on sparcs. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3775 | #if !defined(__STDC__) || __STDC__ != 1 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3776 | #define volatile |
| 3777 | #endif |
| 3778 | main() { |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3779 | volatile char c = 255; exit(c < 0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3780 | } |
| 3781 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3782 | if { (eval echo configure:3783: \"$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] | 3783 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3784 | ac_cv_c_char_unsigned=yes |
| 3785 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3786 | echo "configure: failed program was:" >&5 |
| 3787 | cat conftest.$ac_ext >&5 |
| 3788 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3789 | ac_cv_c_char_unsigned=no |
| 3790 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3791 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3792 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3793 | |
| 3794 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3795 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3796 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3797 | echo "$ac_t""$ac_cv_c_char_unsigned" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3798 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
| 3799 | cat >> confdefs.h <<\EOF |
| 3800 | #define __CHAR_UNSIGNED__ 1 |
| 3801 | EOF |
| 3802 | |
| 3803 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3804 | |
| 3805 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3806 | echo $ac_n "checking for working const""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3807 | echo "configure:3808: checking for working const" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3808 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
| 3809 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3810 | else |
| 3811 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3812 | #line 3813 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3813 | #include "confdefs.h" |
| 3814 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3815 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3816 | |
| 3817 | /* Ultrix mips cc rejects this. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3818 | typedef int charset[2]; const charset x; |
| 3819 | /* SunOS 4.1.1 cc rejects this. */ |
| 3820 | char const *const *ccp; |
| 3821 | char **p; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3822 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 3823 | struct point {int x, y;}; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3824 | static struct point const zero = {0,0}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3825 | /* AIX XL C 1.02.0.0 rejects this. |
| 3826 | It does not let you subtract one const X* pointer from another in an arm |
| 3827 | of an if-expression whose if-part is not a constant expression */ |
| 3828 | const char *g = "string"; |
| 3829 | ccp = &g + (g ? g-g : 0); |
| 3830 | /* HPUX 7.0 cc rejects these. */ |
| 3831 | ++ccp; |
| 3832 | p = (char**) ccp; |
| 3833 | ccp = (char const *const *) p; |
| 3834 | { /* SCO 3.2v4 cc rejects this. */ |
| 3835 | char *t; |
| 3836 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
| 3837 | |
| 3838 | *t++ = 0; |
| 3839 | } |
| 3840 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3841 | int x[] = {25, 17}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3842 | const int *foo = &x[0]; |
| 3843 | ++foo; |
| 3844 | } |
| 3845 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 3846 | typedef const int *iptr; |
| 3847 | iptr p = 0; |
| 3848 | ++p; |
| 3849 | } |
| 3850 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 3851 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 3852 | struct s { int j; const int *ap[3]; }; |
| 3853 | struct s *b; b->j = 5; |
| 3854 | } |
| 3855 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 3856 | const int foo = 10; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3857 | } |
| 3858 | |
| 3859 | ; return 0; } |
| 3860 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3861 | if { (eval echo configure:3862: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3862 | rm -rf conftest* |
| 3863 | ac_cv_c_const=yes |
| 3864 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3865 | echo "configure: failed program was:" >&5 |
| 3866 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3867 | rm -rf conftest* |
| 3868 | ac_cv_c_const=no |
| 3869 | fi |
| 3870 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3871 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3872 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3873 | echo "$ac_t""$ac_cv_c_const" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3874 | if test $ac_cv_c_const = no; then |
| 3875 | cat >> confdefs.h <<\EOF |
| 3876 | #define const |
| 3877 | EOF |
| 3878 | |
| 3879 | fi |
| 3880 | |
| 3881 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3882 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3883 | echo $ac_n "checking for working volatile""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3884 | echo "configure:3885: checking for working volatile" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3885 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3886 | #line 3887 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3887 | #include "confdefs.h" |
| 3888 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3889 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3890 | volatile int x; x = 0; |
| 3891 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3892 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3893 | if { (eval echo configure:3894: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3894 | rm -rf conftest* |
| 3895 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3896 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3897 | echo "configure: failed program was:" >&5 |
| 3898 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3899 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3900 | cat >> confdefs.h <<\EOF |
| 3901 | #define volatile |
| 3902 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3903 | |
| 3904 | fi |
| 3905 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3906 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3907 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3908 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3909 | echo $ac_n "checking for working signed char""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3910 | echo "configure:3911: checking for working signed char" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3911 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3912 | #line 3913 "configure" |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 3913 | #include "confdefs.h" |
| 3914 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3915 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3916 | signed char c; |
| 3917 | ; return 0; } |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 3918 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3919 | if { (eval echo configure:3920: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3920 | rm -rf conftest* |
| 3921 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 3922 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3923 | echo "configure: failed program was:" >&5 |
| 3924 | cat conftest.$ac_ext >&5 |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 3925 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3926 | cat >> confdefs.h <<\EOF |
| 3927 | #define signed |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3928 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3929 | |
| 3930 | fi |
| 3931 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3932 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3933 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3934 | have_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3935 | echo $ac_n "checking for prototypes""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3936 | echo "configure:3937: checking for prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3937 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3938 | #line 3939 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3939 | #include "confdefs.h" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3940 | int foo(int x) { return 0; } |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3941 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3942 | return foo(10); |
| 3943 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3944 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3945 | if { (eval echo configure:3946: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3946 | rm -rf conftest* |
| 3947 | cat >> confdefs.h <<\EOF |
| 3948 | #define HAVE_PROTOTYPES 1 |
| 3949 | EOF |
| 3950 | have_prototypes=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3951 | else |
| 3952 | echo "configure: failed program was:" >&5 |
| 3953 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3954 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3955 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3956 | echo "$ac_t""$have_prototypes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3957 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3958 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3959 | echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3960 | echo "configure:3961: checking for variable length prototypes and stdarg.h" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3961 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3962 | #line 3963 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3963 | #include "confdefs.h" |
| 3964 | |
| 3965 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 3966 | int foo(int x, ...) { |
| 3967 | va_list va; |
| 3968 | va_start(va, x); |
| 3969 | va_arg(va, int); |
| 3970 | va_arg(va, char *); |
| 3971 | va_arg(va, double); |
| 3972 | return 0; |
| 3973 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3974 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3975 | int main() { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 3976 | return foo(10, "", 3.14); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3977 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3978 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3979 | if { (eval echo configure:3980: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3980 | rm -rf conftest* |
| 3981 | cat >> confdefs.h <<\EOF |
| 3982 | #define HAVE_STDARG_PROTOTYPES 1 |
| 3983 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3984 | works=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3985 | else |
| 3986 | echo "configure: failed program was:" >&5 |
| 3987 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3988 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3989 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3990 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3991 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3992 | if test "$have_prototypes" = yes; then |
| 3993 | bad_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3994 | echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3995 | echo "configure:3996: checking for bad exec* prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3996 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3997 | #line 3998 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3998 | #include "confdefs.h" |
| 3999 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4000 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4001 | char **t;execve("@",t,t); |
| 4002 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4003 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4004 | if { (eval echo configure:4005: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4005 | : |
| 4006 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4007 | echo "configure: failed program was:" >&5 |
| 4008 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4009 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4010 | cat >> confdefs.h <<\EOF |
| 4011 | #define BAD_EXEC_PROTOTYPES 1 |
| 4012 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4013 | bad_prototypes=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4014 | fi |
| 4015 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4016 | echo "$ac_t""$bad_prototypes" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4017 | fi |
| 4018 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4019 | bad_forward=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4020 | echo $ac_n "checking for bad static forward""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4021 | echo "configure:4022: checking for bad static forward" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4022 | if test "$cross_compiling" = yes; then |
| 4023 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 4024 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4025 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4026 | #line 4027 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4027 | #include "confdefs.h" |
| 4028 | |
| 4029 | struct s { int a; int b; }; |
| 4030 | static struct s foo; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4031 | int foobar() { |
| 4032 | static int random; |
| 4033 | random = (int) &foo; |
| 4034 | return random; |
| 4035 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4036 | static struct s foo = { 1, 2 }; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4037 | main() { |
| 4038 | exit(!((int)&foo == foobar())); |
| 4039 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4040 | |
| 4041 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4042 | if { (eval echo configure:4043: \"$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] | 4043 | then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4044 | : |
| 4045 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4046 | echo "configure: failed program was:" >&5 |
| 4047 | cat conftest.$ac_ext >&5 |
| 4048 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4049 | cat >> confdefs.h <<\EOF |
| 4050 | #define BAD_STATIC_FORWARD 1 |
| 4051 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4052 | bad_forward=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4053 | fi |
| 4054 | rm -fr conftest* |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4055 | fi |
| 4056 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4057 | echo "$ac_t""$bad_forward" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4058 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4059 | va_list_is_array=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4060 | echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4061 | echo "configure:4062: checking whether va_list is an array" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4062 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4063 | #line 4064 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4064 | #include "confdefs.h" |
| 4065 | |
| 4066 | #ifdef HAVE_STDARG_PROTOTYPES |
| 4067 | #include <stdarg.h> |
| 4068 | #else |
| 4069 | #include <varargs.h> |
| 4070 | #endif |
| 4071 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4072 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4073 | va_list list1, list2; list1 = list2; |
| 4074 | ; return 0; } |
| 4075 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4076 | if { (eval echo configure:4077: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4077 | : |
| 4078 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4079 | echo "configure: failed program was:" >&5 |
| 4080 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4081 | rm -rf conftest* |
| 4082 | cat >> confdefs.h <<\EOF |
| 4083 | #define VA_LIST_IS_ARRAY 1 |
| 4084 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4085 | va_list_is_array=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4086 | fi |
| 4087 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4088 | echo "$ac_t""$va_list_is_array" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4089 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4090 | # sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-( |
| 4091 | echo $ac_n "checking for gethostbyname_r""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4092 | echo "configure:4093: checking for gethostbyname_r" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4093 | if eval "test \"`echo '$''{'ac_cv_func_gethostbyname_r'+set}'`\" = set"; then |
| 4094 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4095 | else |
| 4096 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4097 | #line 4098 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4098 | #include "confdefs.h" |
| 4099 | /* System header to define __stub macros and hopefully few prototypes, |
| 4100 | which can conflict with char gethostbyname_r(); below. */ |
| 4101 | #include <assert.h> |
| 4102 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4103 | /* We use char because int might match the return type of a gcc2 |
| 4104 | builtin and then its argument prototype would still apply. */ |
| 4105 | char gethostbyname_r(); |
| 4106 | |
| 4107 | int main() { |
| 4108 | |
| 4109 | /* The GNU C library defines this for functions which it implements |
| 4110 | to always fail with ENOSYS. Some functions are actually named |
| 4111 | something starting with __ and the normal name is an alias. */ |
| 4112 | #if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r) |
| 4113 | choke me |
| 4114 | #else |
| 4115 | gethostbyname_r(); |
| 4116 | #endif |
| 4117 | |
| 4118 | ; return 0; } |
| 4119 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4120 | if { (eval echo configure:4121: \"$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] | 4121 | rm -rf conftest* |
| 4122 | eval "ac_cv_func_gethostbyname_r=yes" |
| 4123 | else |
| 4124 | echo "configure: failed program was:" >&5 |
| 4125 | cat conftest.$ac_ext >&5 |
| 4126 | rm -rf conftest* |
| 4127 | eval "ac_cv_func_gethostbyname_r=no" |
| 4128 | fi |
| 4129 | rm -f conftest* |
| 4130 | fi |
| 4131 | |
| 4132 | if eval "test \"`echo '$ac_cv_func_'gethostbyname_r`\" = yes"; then |
| 4133 | echo "$ac_t""yes" 1>&6 |
| 4134 | |
| 4135 | cat >> confdefs.h <<\EOF |
| 4136 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4137 | EOF |
| 4138 | |
| 4139 | echo $ac_n "checking gethostbyname_r with 6 args""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4140 | echo "configure:4141: checking gethostbyname_r with 6 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4141 | OLD_CFLAGS=$CFLAGS |
| 4142 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
| 4143 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4144 | #line 4145 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4145 | #include "confdefs.h" |
| 4146 | |
| 4147 | # include <netdb.h> |
| 4148 | |
| 4149 | int main() { |
| 4150 | |
| 4151 | char *name; |
| 4152 | struct hostent *he, *res; |
| 4153 | char buffer[2048]; |
| 4154 | int buflen = 2048; |
| 4155 | int h_errnop; |
| 4156 | |
| 4157 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
| 4158 | |
| 4159 | ; return 0; } |
| 4160 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4161 | if { (eval echo configure:4162: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4162 | rm -rf conftest* |
| 4163 | |
| 4164 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4165 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4166 | EOF |
| 4167 | |
| 4168 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4169 | #define HAVE_GETHOSTBYNAME_R_6_ARG 1 |
| 4170 | EOF |
| 4171 | |
| 4172 | echo "$ac_t""yes" 1>&6 |
| 4173 | |
| 4174 | else |
| 4175 | echo "configure: failed program was:" >&5 |
| 4176 | cat conftest.$ac_ext >&5 |
| 4177 | rm -rf conftest* |
| 4178 | |
| 4179 | echo "$ac_t""no" 1>&6 |
| 4180 | echo $ac_n "checking gethostbyname_r with 5 args""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4181 | echo "configure:4182: checking gethostbyname_r with 5 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4182 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4183 | #line 4184 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4184 | #include "confdefs.h" |
| 4185 | |
| 4186 | # include <netdb.h> |
| 4187 | |
| 4188 | int main() { |
| 4189 | |
| 4190 | char *name; |
| 4191 | struct hostent *he; |
| 4192 | char buffer[2048]; |
| 4193 | int buflen = 2048; |
| 4194 | int h_errnop; |
| 4195 | |
| 4196 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
| 4197 | |
| 4198 | ; return 0; } |
| 4199 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4200 | if { (eval echo configure:4201: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4201 | rm -rf conftest* |
| 4202 | |
| 4203 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4204 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4205 | EOF |
| 4206 | |
| 4207 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4208 | #define HAVE_GETHOSTBYNAME_R_5_ARG 1 |
| 4209 | EOF |
| 4210 | |
| 4211 | echo "$ac_t""yes" 1>&6 |
| 4212 | |
| 4213 | else |
| 4214 | echo "configure: failed program was:" >&5 |
| 4215 | cat conftest.$ac_ext >&5 |
| 4216 | rm -rf conftest* |
| 4217 | |
| 4218 | echo "$ac_t""no" 1>&6 |
| 4219 | echo $ac_n "checking gethostbyname_r with 3 args""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4220 | echo "configure:4221: checking gethostbyname_r with 3 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4221 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4222 | #line 4223 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4223 | #include "confdefs.h" |
| 4224 | |
| 4225 | # include <netdb.h> |
| 4226 | |
| 4227 | int main() { |
| 4228 | |
| 4229 | char *name; |
| 4230 | struct hostent *he; |
| 4231 | struct hostent_data data; |
| 4232 | |
| 4233 | (void) gethostbyname_r(name, he, &data); |
| 4234 | |
| 4235 | ; return 0; } |
| 4236 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4237 | if { (eval echo configure:4238: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4238 | rm -rf conftest* |
| 4239 | |
| 4240 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4241 | #define HAVE_GETHOSTBYNAME_R 1 |
| 4242 | EOF |
| 4243 | |
| 4244 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4245 | #define HAVE_GETHOSTBYNAME_R_3_ARG 1 |
| 4246 | EOF |
| 4247 | |
| 4248 | echo "$ac_t""yes" 1>&6 |
| 4249 | |
| 4250 | else |
| 4251 | echo "configure: failed program was:" >&5 |
| 4252 | cat conftest.$ac_ext >&5 |
| 4253 | rm -rf conftest* |
| 4254 | |
| 4255 | echo "$ac_t""no" 1>&6 |
| 4256 | |
| 4257 | fi |
| 4258 | rm -f conftest* |
| 4259 | |
| 4260 | fi |
| 4261 | rm -f conftest* |
| 4262 | |
| 4263 | fi |
| 4264 | rm -f conftest* |
| 4265 | CFLAGS=$OLD_CFLAGS |
| 4266 | |
| 4267 | else |
| 4268 | echo "$ac_t""no" 1>&6 |
| 4269 | |
| 4270 | echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4271 | echo "configure:4272: checking for gethostbyname" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4272 | if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then |
| 4273 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4274 | else |
| 4275 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4276 | #line 4277 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4277 | #include "confdefs.h" |
| 4278 | /* System header to define __stub macros and hopefully few prototypes, |
| 4279 | which can conflict with char gethostbyname(); below. */ |
| 4280 | #include <assert.h> |
| 4281 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4282 | /* We use char because int might match the return type of a gcc2 |
| 4283 | builtin and then its argument prototype would still apply. */ |
| 4284 | char gethostbyname(); |
| 4285 | |
| 4286 | int main() { |
| 4287 | |
| 4288 | /* The GNU C library defines this for functions which it implements |
| 4289 | to always fail with ENOSYS. Some functions are actually named |
| 4290 | something starting with __ and the normal name is an alias. */ |
| 4291 | #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) |
| 4292 | choke me |
| 4293 | #else |
| 4294 | gethostbyname(); |
| 4295 | #endif |
| 4296 | |
| 4297 | ; return 0; } |
| 4298 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4299 | if { (eval echo configure:4300: \"$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] | 4300 | rm -rf conftest* |
| 4301 | eval "ac_cv_func_gethostbyname=yes" |
| 4302 | else |
| 4303 | echo "configure: failed program was:" >&5 |
| 4304 | cat conftest.$ac_ext >&5 |
| 4305 | rm -rf conftest* |
| 4306 | eval "ac_cv_func_gethostbyname=no" |
| 4307 | fi |
| 4308 | rm -f conftest* |
| 4309 | fi |
| 4310 | |
| 4311 | if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then |
| 4312 | echo "$ac_t""yes" 1>&6 |
| 4313 | cat >> confdefs.h <<\EOF |
| 4314 | #define HAVE_GETHOSTBYNAME 1 |
| 4315 | EOF |
| 4316 | |
| 4317 | else |
| 4318 | echo "$ac_t""no" 1>&6 |
| 4319 | fi |
| 4320 | |
| 4321 | |
| 4322 | fi |
| 4323 | |
| 4324 | |
| 4325 | |
| 4326 | |
| 4327 | |
| 4328 | |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 4329 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4330 | # checks for system services |
| 4331 | # (none yet) |
| 4332 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4333 | # Linux requires this for correct f.p. operations |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4334 | echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4335 | echo "configure:4336: checking for __fpu_control in -lieee" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4336 | ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'` |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4337 | 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] | 4338 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4339 | else |
| 4340 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4341 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4342 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4343 | #line 4344 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4344 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4345 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4346 | /* We use char because int might match the return type of a gcc2 |
| 4347 | builtin and then its argument prototype would still apply. */ |
| 4348 | char __fpu_control(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4349 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4350 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4351 | __fpu_control() |
| 4352 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4353 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4354 | if { (eval echo configure:4355: \"$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] | 4355 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4356 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4357 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4358 | echo "configure: failed program was:" >&5 |
| 4359 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4360 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4361 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4362 | fi |
| 4363 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4364 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4365 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4366 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4367 | 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] | 4368 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4369 | ac_tr_lib=HAVE_LIB`echo ieee | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 4370 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4371 | cat >> confdefs.h <<EOF |
| 4372 | #define $ac_tr_lib 1 |
| 4373 | EOF |
| 4374 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4375 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4376 | |
| 4377 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4378 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4379 | fi |
| 4380 | |
| 4381 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4382 | # Check for --with-fpectl |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4383 | echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4384 | echo "configure:4385: checking for --with-fpectl" >&5 |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4385 | # Check whether --with-fpectl or --without-fpectl was given. |
| 4386 | if test "${with_fpectl+set}" = set; then |
| 4387 | withval="$with_fpectl" |
| 4388 | |
| 4389 | if test "$withval" != no |
| 4390 | then cat >> confdefs.h <<\EOF |
| 4391 | #define WANT_SIGFPE_HANDLER 1 |
| 4392 | EOF |
| 4393 | echo "$ac_t""yes" 1>&6 |
| 4394 | else echo "$ac_t""no" 1>&6 |
| 4395 | fi |
| 4396 | fi |
| 4397 | |
| 4398 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4399 | # check for --with-libm=... |
| 4400 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 4401 | case $ac_sys_system in |
| 4402 | next) ;; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 4403 | BeOS) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 4404 | *) LIBM=-lm |
| 4405 | esac |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4406 | echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4407 | echo "configure:4408: checking for --with-libm=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4408 | # Check whether --with-libm or --without-libm was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4409 | if test "${with_libm+set}" = set; then |
| 4410 | withval="$with_libm" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4411 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4412 | if test "$withval" = no |
| 4413 | then LIBM= |
| 4414 | echo "$ac_t""force LIBM empty" 1>&6 |
| 4415 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4416 | then LIBM=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4417 | echo "$ac_t""set LIBM=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4418 | 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] | 4419 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4420 | else |
| 4421 | echo "$ac_t""default LIBM=\"$LIBM\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4422 | fi |
| 4423 | |
| 4424 | |
| 4425 | # check for --with-libc=... |
| 4426 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4427 | echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4428 | echo "configure:4429: checking for --with-libc=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4429 | # Check whether --with-libc or --without-libc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4430 | if test "${with_libc+set}" = set; then |
| 4431 | withval="$with_libc" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4432 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4433 | if test "$withval" = no |
| 4434 | then LIBC= |
| 4435 | echo "$ac_t""force LIBC empty" 1>&6 |
| 4436 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4437 | then LIBC=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4438 | echo "$ac_t""set LIBC=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4439 | 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] | 4440 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 4441 | else |
| 4442 | echo "$ac_t""default LIBC=\"$LIBC\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4443 | fi |
| 4444 | |
| 4445 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4446 | # check for hypot() in math library |
| 4447 | LIBS_SAVE=$LIBS |
| 4448 | LIBS="$LIBS $LIBM" |
| 4449 | for ac_func in hypot |
| 4450 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4451 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4452 | echo "configure:4453: checking for $ac_func" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4453 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 4454 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4455 | else |
| 4456 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4457 | #line 4458 "configure" |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4458 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4459 | /* System header to define __stub macros and hopefully few prototypes, |
| 4460 | which can conflict with char $ac_func(); below. */ |
| 4461 | #include <assert.h> |
| 4462 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4463 | /* We use char because int might match the return type of a gcc2 |
| 4464 | builtin and then its argument prototype would still apply. */ |
| 4465 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4466 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4467 | int main() { |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4468 | |
| 4469 | /* The GNU C library defines this for functions which it implements |
| 4470 | to always fail with ENOSYS. Some functions are actually named |
| 4471 | something starting with __ and the normal name is an alias. */ |
| 4472 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4473 | choke me |
| 4474 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4475 | $ac_func(); |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4476 | #endif |
| 4477 | |
| 4478 | ; return 0; } |
| 4479 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4480 | if { (eval echo configure:4481: \"$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] | 4481 | rm -rf conftest* |
| 4482 | eval "ac_cv_func_$ac_func=yes" |
| 4483 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4484 | echo "configure: failed program was:" >&5 |
| 4485 | cat conftest.$ac_ext >&5 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4486 | rm -rf conftest* |
| 4487 | eval "ac_cv_func_$ac_func=no" |
| 4488 | fi |
| 4489 | rm -f conftest* |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4490 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4491 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4492 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4493 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4494 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4495 | cat >> confdefs.h <<EOF |
| 4496 | #define $ac_tr_func 1 |
| 4497 | EOF |
| 4498 | |
| 4499 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4500 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4501 | fi |
| 4502 | done |
| 4503 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4504 | for ac_func in hypot |
| 4505 | do |
| 4506 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4507 | echo "configure:4508: checking for $ac_func" >&5 |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4508 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 4509 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4510 | else |
| 4511 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4512 | #line 4513 "configure" |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4513 | #include "confdefs.h" |
| 4514 | /* System header to define __stub macros and hopefully few prototypes, |
| 4515 | which can conflict with char $ac_func(); below. */ |
| 4516 | #include <assert.h> |
| 4517 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4518 | /* We use char because int might match the return type of a gcc2 |
| 4519 | builtin and then its argument prototype would still apply. */ |
| 4520 | char $ac_func(); |
| 4521 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4522 | int main() { |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4523 | |
| 4524 | /* The GNU C library defines this for functions which it implements |
| 4525 | to always fail with ENOSYS. Some functions are actually named |
| 4526 | something starting with __ and the normal name is an alias. */ |
| 4527 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4528 | choke me |
| 4529 | #else |
| 4530 | $ac_func(); |
| 4531 | #endif |
| 4532 | |
| 4533 | ; return 0; } |
| 4534 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4535 | if { (eval echo configure:4536: \"$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] | 4536 | rm -rf conftest* |
| 4537 | eval "ac_cv_func_$ac_func=yes" |
| 4538 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4539 | echo "configure: failed program was:" >&5 |
| 4540 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4541 | rm -rf conftest* |
| 4542 | eval "ac_cv_func_$ac_func=no" |
| 4543 | fi |
| 4544 | rm -f conftest* |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4545 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4546 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4547 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4548 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4549 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4550 | cat >> confdefs.h <<EOF |
| 4551 | #define $ac_tr_func 1 |
| 4552 | EOF |
| 4553 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4554 | else |
| 4555 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4556 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4557 | fi |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 4558 | done |
| 4559 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4560 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 4561 | LIBS=$LIBS_SAVE |
| 4562 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4563 | # check for getopt |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4564 | echo $ac_n "checking for genuine getopt""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4565 | echo "configure:4566: checking for genuine getopt" >&5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4566 | if eval "test \"`echo '$''{'ac_cv_func_getopt'+set}'`\" = set"; then |
| 4567 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4568 | else |
| 4569 | if test "$cross_compiling" = yes; then |
| 4570 | ac_cv_func_getopt=no |
| 4571 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4572 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4573 | #line 4574 "configure" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4574 | #include "confdefs.h" |
| 4575 | #include <stdio.h> |
| 4576 | extern int optind, opterr, getopt(); |
| 4577 | extern char* optarg; |
| 4578 | int main() { |
| 4579 | char* av[] = { "testprog", "parameter", "-fFlag", NULL }; |
| 4580 | opterr = 0; |
| 4581 | if (getopt(3, av, "f:") == 'f') { exit(1); } |
| 4582 | exit(0); |
| 4583 | } |
| 4584 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4585 | if { (eval echo configure:4586: \"$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] | 4586 | then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4587 | ac_cv_func_getopt=yes |
| 4588 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4589 | echo "configure: failed program was:" >&5 |
| 4590 | cat conftest.$ac_ext >&5 |
| 4591 | rm -fr conftest* |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4592 | ac_cv_func_getopt=no |
| 4593 | fi |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4594 | rm -fr conftest* |
| 4595 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4596 | |
| 4597 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4598 | echo "$ac_t""$ac_cv_func_getopt" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4599 | test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o" |
| 4600 | |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 4601 | # check whether malloc(0) returns NULL or not |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 4602 | echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6 |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4603 | echo "configure:4604: checking what malloc(0) returns" >&5 |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 4604 | if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then |
| 4605 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4606 | else |
| 4607 | if test "$cross_compiling" = yes; then |
| 4608 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 4609 | else |
| 4610 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4611 | #line 4612 "configure" |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 4612 | #include "confdefs.h" |
| 4613 | #include <stdio.h> |
| 4614 | #ifdef HAVE_STDLIB |
| 4615 | #include <stdlib.h> |
| 4616 | #else |
| 4617 | char *malloc(), *realloc(); |
| 4618 | int *free(); |
| 4619 | #endif |
| 4620 | main() { |
| 4621 | char *p; |
| 4622 | p = malloc(0); |
| 4623 | if (p == NULL) exit(1); |
| 4624 | p = realloc(p, 0); |
| 4625 | if (p == NULL) exit(1); |
| 4626 | free(p); |
| 4627 | exit(0); |
| 4628 | } |
| 4629 | EOF |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 4630 | if { (eval echo configure:4631: \"$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] | 4631 | then |
| 4632 | ac_cv_malloc_zero=nonnull |
| 4633 | else |
| 4634 | echo "configure: failed program was:" >&5 |
| 4635 | cat conftest.$ac_ext >&5 |
| 4636 | rm -fr conftest* |
| 4637 | ac_cv_malloc_zero=null |
| 4638 | fi |
| 4639 | rm -fr conftest* |
| 4640 | fi |
| 4641 | |
| 4642 | fi |
| 4643 | |
| 4644 | echo "$ac_t""$ac_cv_malloc_zero" 1>&6 |
| 4645 | if test "$ac_cv_malloc_zero" = null |
| 4646 | then |
| 4647 | cat >> confdefs.h <<\EOF |
| 4648 | #define MALLOC_ZERO_RETURNS_NULL 1 |
| 4649 | EOF |
| 4650 | |
| 4651 | fi |
| 4652 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4653 | # generate output files |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4654 | trap '' 1 2 15 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4655 | cat > confcache <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4656 | # This file is a shell script that caches the results of configure |
| 4657 | # tests run on this system so they can be shared between configure |
| 4658 | # scripts and configure runs. It is not useful on other systems. |
| 4659 | # If it contains results you don't want to keep, you may remove or edit it. |
| 4660 | # |
| 4661 | # By default, configure uses ./config.cache as the cache file, |
| 4662 | # creating it if it does not exist already. You can give configure |
| 4663 | # the --cache-file=FILE option to use a different cache file; that is |
| 4664 | # what configure does when it calls configure scripts in |
| 4665 | # subdirectories, so they share the cache. |
| 4666 | # Giving --cache-file=/dev/null disables caching, for debugging configure. |
| 4667 | # config.status only pays attention to the cache file if you give it the |
| 4668 | # --recheck option to rerun configure. |
| 4669 | # |
| 4670 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4671 | # The following way of writing the cache mishandles newlines in values, |
| 4672 | # but we know of no workaround that is simple, portable, and efficient. |
| 4673 | # So, don't put newlines in cache variables' values. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4674 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 4675 | # 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] | 4676 | (set) 2>&1 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4677 | case `(ac_space=' '; set | grep ac_space) 2>&1` in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4678 | *ac_space=\ *) |
| 4679 | # `set' does not quote correctly, so add quotes (double-quote substitution |
| 4680 | # turns \\\\ into \\, and sed turns \\ into \). |
| 4681 | sed -n \ |
| 4682 | -e "s/'/'\\\\''/g" \ |
| 4683 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" |
| 4684 | ;; |
| 4685 | *) |
| 4686 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
| 4687 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' |
| 4688 | ;; |
| 4689 | esac >> confcache |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4690 | if cmp -s $cache_file confcache; then |
| 4691 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4692 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4693 | if test -w $cache_file; then |
| 4694 | echo "updating cache $cache_file" |
| 4695 | cat confcache > $cache_file |
| 4696 | else |
| 4697 | echo "not updating unwritable cache $cache_file" |
| 4698 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4699 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4700 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 4701 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4702 | 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] | 4703 | |
| 4704 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 4705 | # Let make expand exec_prefix. |
| 4706 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 4707 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4708 | # Any assignment to VPATH causes Sun make to only execute |
| 4709 | # the first set of double-colon rules, so remove it if not needed. |
| 4710 | # If there is a colon in the path, we need to keep it. |
| 4711 | if test "x$srcdir" = x.; then |
| 4712 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
| 4713 | fi |
| 4714 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4715 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4716 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4717 | DEFS=-DHAVE_CONFIG_H |
| 4718 | |
| 4719 | # Without the "./", some shells look in PATH for config.status. |
| 4720 | : ${CONFIG_STATUS=./config.status} |
| 4721 | |
| 4722 | echo creating $CONFIG_STATUS |
| 4723 | rm -f $CONFIG_STATUS |
| 4724 | cat > $CONFIG_STATUS <<EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4725 | #! /bin/sh |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4726 | # Generated automatically by configure. |
| 4727 | # Run this file to recreate the current configuration. |
| 4728 | # This directory was configured as follows, |
| 4729 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
| 4730 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4731 | # $0 $ac_configure_args |
| 4732 | # |
| 4733 | # Compiler output produced by configure, useful for debugging |
| 4734 | # configure, is in ./config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4735 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4736 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4737 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4738 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4739 | case "\$ac_option" in |
| 4740 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4741 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
| 4742 | 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] | 4743 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4744 | echo "$CONFIG_STATUS generated by autoconf version 2.13" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4745 | exit 0 ;; |
| 4746 | -help | --help | --hel | --he | --h) |
| 4747 | echo "\$ac_cs_usage"; exit 0 ;; |
| 4748 | *) echo "\$ac_cs_usage"; exit 1 ;; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4749 | esac |
| 4750 | done |
| 4751 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4752 | ac_given_srcdir=$srcdir |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4753 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 4754 | trap 'rm -fr `echo "Makefile \ |
| 4755 | Objects/Makefile \ |
| 4756 | Parser/Makefile \ |
| 4757 | Python/Makefile \ |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 4758 | Modules/Makefile.pre \ |
| 4759 | 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] | 4760 | EOF |
| 4761 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4762 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4763 | # Protect against being on the right side of a sed subst in config.status. |
| 4764 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; |
| 4765 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4766 | $ac_vpsub |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4767 | $extrasub |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4768 | s%@SHELL@%$SHELL%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4769 | s%@CFLAGS@%$CFLAGS%g |
| 4770 | s%@CPPFLAGS@%$CPPFLAGS%g |
| 4771 | s%@CXXFLAGS@%$CXXFLAGS%g |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4772 | s%@FFLAGS@%$FFLAGS%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4773 | s%@DEFS@%$DEFS%g |
| 4774 | s%@LDFLAGS@%$LDFLAGS%g |
| 4775 | s%@LIBS@%$LIBS%g |
| 4776 | s%@exec_prefix@%$exec_prefix%g |
| 4777 | s%@prefix@%$prefix%g |
| 4778 | s%@program_transform_name@%$program_transform_name%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4779 | s%@bindir@%$bindir%g |
| 4780 | s%@sbindir@%$sbindir%g |
| 4781 | s%@libexecdir@%$libexecdir%g |
| 4782 | s%@datadir@%$datadir%g |
| 4783 | s%@sysconfdir@%$sysconfdir%g |
| 4784 | s%@sharedstatedir@%$sharedstatedir%g |
| 4785 | s%@localstatedir@%$localstatedir%g |
| 4786 | s%@libdir@%$libdir%g |
| 4787 | s%@includedir@%$includedir%g |
| 4788 | s%@oldincludedir@%$oldincludedir%g |
| 4789 | s%@infodir@%$infodir%g |
| 4790 | s%@mandir@%$mandir%g |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 4791 | s%@VERSION@%$VERSION%g |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 4792 | s%@MACHDEP@%$MACHDEP%g |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 4793 | s%@SGI_ABI@%$SGI_ABI%g |
| 4794 | s%@SET_CCC@%$SET_CCC%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4795 | s%@CC@%$CC%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 4796 | s%@MAKE_LDLIBRARY@%$MAKE_LDLIBRARY%g |
| 4797 | s%@LDLIBRARY@%$LDLIBRARY%g |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 4798 | s%@LINKCC@%$LINKCC%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4799 | s%@RANLIB@%$RANLIB%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4800 | s%@AR@%$AR%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 4801 | s%@INSTALL@%$INSTALL%g |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4802 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
| 4803 | s%@INSTALL_DATA@%$INSTALL_DATA%g |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 4804 | s%@LN@%$LN%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 4805 | s%@OPT@%$OPT%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4806 | s%@CPP@%$CPP%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 4807 | s%@LIBTOOL_CRUFT@%$LIBTOOL_CRUFT%g |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 4808 | s%@SO@%$SO%g |
| 4809 | s%@LDSHARED@%$LDSHARED%g |
| 4810 | s%@CCSHARED@%$CCSHARED%g |
| 4811 | s%@LINKFORSHARED@%$LINKFORSHARED%g |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 4812 | s%@USE_THREAD_MODULE@%$USE_THREAD_MODULE%g |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 4813 | s%@LDLAST@%$LDLAST%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4814 | s%@DLINCLDIR@%$DLINCLDIR%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4815 | s%@LIBOBJS@%$LIBOBJS%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4816 | s%@HAVE_GETHOSTBYNAME_R_6_ARG@%$HAVE_GETHOSTBYNAME_R_6_ARG%g |
| 4817 | s%@HAVE_GETHOSTBYNAME_R_5_ARG@%$HAVE_GETHOSTBYNAME_R_5_ARG%g |
| 4818 | 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] | 4819 | s%@HAVE_GETHOSTBYNAME_R@%$HAVE_GETHOSTBYNAME_R%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 4820 | s%@HAVE_GETHOSTBYNAME@%$HAVE_GETHOSTBYNAME%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4821 | s%@LIBM@%$LIBM%g |
| 4822 | s%@LIBC@%$LIBC%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4823 | |
| 4824 | CEOF |
| 4825 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4826 | |
| 4827 | cat >> $CONFIG_STATUS <<\EOF |
| 4828 | |
| 4829 | # Split the substitutions into bite-sized pieces for seds with |
| 4830 | # small command number limits, like on Digital OSF/1 and HP-UX. |
| 4831 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. |
| 4832 | ac_file=1 # Number of current file. |
| 4833 | ac_beg=1 # First line for current file. |
| 4834 | ac_end=$ac_max_sed_cmds # Line after last line for current file. |
| 4835 | ac_more_lines=: |
| 4836 | ac_sed_cmds="" |
| 4837 | while $ac_more_lines; do |
| 4838 | if test $ac_beg -gt 1; then |
| 4839 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file |
| 4840 | else |
| 4841 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file |
| 4842 | fi |
| 4843 | if test ! -s conftest.s$ac_file; then |
| 4844 | ac_more_lines=false |
| 4845 | rm -f conftest.s$ac_file |
| 4846 | else |
| 4847 | if test -z "$ac_sed_cmds"; then |
| 4848 | ac_sed_cmds="sed -f conftest.s$ac_file" |
| 4849 | else |
| 4850 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" |
| 4851 | fi |
| 4852 | ac_file=`expr $ac_file + 1` |
| 4853 | ac_beg=$ac_end |
| 4854 | ac_end=`expr $ac_end + $ac_max_sed_cmds` |
| 4855 | fi |
| 4856 | done |
| 4857 | if test -z "$ac_sed_cmds"; then |
| 4858 | ac_sed_cmds=cat |
| 4859 | fi |
| 4860 | EOF |
| 4861 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4862 | cat >> $CONFIG_STATUS <<EOF |
| 4863 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 4864 | CONFIG_FILES=\${CONFIG_FILES-"Makefile \ |
| 4865 | Objects/Makefile \ |
| 4866 | Parser/Makefile \ |
| 4867 | Python/Makefile \ |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 4868 | Modules/Makefile.pre \ |
| 4869 | Modules/Setup.thread"} |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4870 | EOF |
| 4871 | cat >> $CONFIG_STATUS <<\EOF |
| 4872 | 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] | 4873 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4874 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4875 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4876 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 4877 | *) ac_file_in="${ac_file}.in" ;; |
| 4878 | esac |
| 4879 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4880 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4881 | |
| 4882 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 4883 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 4884 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 4885 | # The file is in a subdirectory. |
| 4886 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4887 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4888 | # A "../" for each directory in $ac_dir_suffix. |
| 4889 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
| 4890 | else |
| 4891 | ac_dir_suffix= ac_dots= |
| 4892 | fi |
| 4893 | |
| 4894 | case "$ac_given_srcdir" in |
| 4895 | .) srcdir=. |
| 4896 | if test -z "$ac_dots"; then top_srcdir=. |
| 4897 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; |
| 4898 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; |
| 4899 | *) # Relative path. |
| 4900 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
| 4901 | top_srcdir="$ac_dots$ac_given_srcdir" ;; |
| 4902 | esac |
| 4903 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4904 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4905 | echo creating "$ac_file" |
| 4906 | rm -f "$ac_file" |
| 4907 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." |
| 4908 | case "$ac_file" in |
| 4909 | *Makefile*) ac_comsub="1i\\ |
| 4910 | # $configure_input" ;; |
| 4911 | *) ac_comsub= ;; |
| 4912 | esac |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4913 | |
| 4914 | 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] | 4915 | sed -e "$ac_comsub |
| 4916 | s%@configure_input@%$configure_input%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4917 | s%@srcdir@%$srcdir%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4918 | s%@top_srcdir@%$top_srcdir%g |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4919 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4920 | fi; done |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4921 | rm -f conftest.s* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4922 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4923 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
| 4924 | # 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] | 4925 | # |
| 4926 | # ac_d sets the value in "#define NAME VALUE" lines. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4927 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
| 4928 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4929 | ac_dC='\3' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4930 | ac_dD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4931 | # 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] | 4932 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 4933 | ac_uB='\([ ]\)%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4934 | ac_uC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4935 | ac_uD='\4%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4936 | # 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] | 4937 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 4938 | ac_eB='$%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4939 | ac_eC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4940 | ac_eD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4941 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4942 | if test "${CONFIG_HEADERS+set}" != set; then |
| 4943 | EOF |
| 4944 | cat >> $CONFIG_STATUS <<EOF |
| 4945 | CONFIG_HEADERS="config.h" |
| 4946 | EOF |
| 4947 | cat >> $CONFIG_STATUS <<\EOF |
| 4948 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4949 | 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] | 4950 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4951 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4952 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4953 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 4954 | *) ac_file_in="${ac_file}.in" ;; |
| 4955 | esac |
| 4956 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4957 | echo creating $ac_file |
| 4958 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4959 | rm -f conftest.frag conftest.in conftest.out |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4960 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
| 4961 | cat $ac_file_inputs > conftest.in |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4962 | |
| 4963 | EOF |
| 4964 | |
| 4965 | # Transform confdefs.h into a sed script conftest.vals that substitutes |
| 4966 | # 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] | 4967 | # 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] | 4968 | # Protect against being in an unquoted here document in config.status. |
| 4969 | rm -f conftest.vals |
| 4970 | cat > conftest.hdr <<\EOF |
| 4971 | s/[\\&%]/\\&/g |
| 4972 | s%[\\$`]%\\&%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4973 | 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] | 4974 | s%ac_d%ac_u%gp |
| 4975 | s%ac_u%ac_e%gp |
| 4976 | EOF |
| 4977 | sed -n -f conftest.hdr confdefs.h > conftest.vals |
| 4978 | rm -f conftest.hdr |
| 4979 | |
| 4980 | # This sed command replaces #undef with comments. This is necessary, for |
| 4981 | # example, in the case of _POSIX_SOURCE, which is predefined and required |
| 4982 | # on some systems where configure will not decide to define it. |
| 4983 | cat >> conftest.vals <<\EOF |
| 4984 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% |
| 4985 | EOF |
| 4986 | |
| 4987 | # Break up conftest.vals because some shells have a limit on |
| 4988 | # 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] | 4989 | |
| 4990 | rm -f conftest.tail |
| 4991 | while : |
| 4992 | do |
| 4993 | ac_lines=`grep -c . conftest.vals` |
| 4994 | # grep -c gives empty output for an empty file on some AIX systems. |
| 4995 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi |
| 4996 | # Write a limited-size here document to conftest.frag. |
| 4997 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS |
| 4998 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS |
| 4999 | echo 'CEOF |
| 5000 | sed -f conftest.frag conftest.in > conftest.out |
| 5001 | rm -f conftest.in |
| 5002 | mv conftest.out conftest.in |
| 5003 | ' >> $CONFIG_STATUS |
| 5004 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
| 5005 | rm -f conftest.vals |
| 5006 | mv conftest.tail conftest.vals |
| 5007 | done |
| 5008 | rm -f conftest.vals |
| 5009 | |
| 5010 | cat >> $CONFIG_STATUS <<\EOF |
| 5011 | rm -f conftest.frag conftest.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5012 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5013 | cat conftest.in >> conftest.h |
| 5014 | rm -f conftest.in |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5015 | if cmp -s $ac_file conftest.h 2>/dev/null; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5016 | echo "$ac_file is unchanged" |
| 5017 | rm -f conftest.h |
| 5018 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5019 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 5020 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 5021 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 5022 | # The file is in a subdirectory. |
| 5023 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
| 5024 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5025 | rm -f $ac_file |
| 5026 | mv conftest.h $ac_file |
| 5027 | fi |
| 5028 | fi; done |
| 5029 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5030 | EOF |
| 5031 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5032 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5033 | EOF |
| 5034 | cat >> $CONFIG_STATUS <<\EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5035 | |
| 5036 | exit 0 |
| 5037 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5038 | chmod +x $CONFIG_STATUS |
| 5039 | rm -fr confdefs* $ac_clean_files |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5040 | 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] | 5041 | |