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 | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3 | # From configure.in Revision: 1.40 |
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 | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6 | # Generated automatically using autoconf version 2.10 |
| 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 | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 19 | --without-gcc never use gcc" |
| 20 | ac_help="$ac_help |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 21 | --with-libs='lib1 ...' link against additional libs" |
| 22 | ac_help="$ac_help |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 23 | --with-readline[=DIRECTORY] use GNU readline library" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 24 | ac_help="$ac_help |
| 25 | --with-thread[=DIRECTORY] make interpreter thread-safe" |
| 26 | ac_help="$ac_help |
| 27 | --with-sgi-dl=DIRECTORY IRIX 4 dynamic linking" |
| 28 | ac_help="$ac_help |
| 29 | --with-dl-dld=DL_DIR,DLD_DIR GNU dynamic linking" |
| 30 | ac_help="$ac_help |
| 31 | --with-libm=STRING math library" |
| 32 | ac_help="$ac_help |
| 33 | --with-libc=STRING C library" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 34 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 35 | # Initialize some variables set by options. |
| 36 | # The variables have the same names as the options, with |
| 37 | # dashes changed to underlines. |
| 38 | build=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 39 | cache_file=./config.cache |
| 40 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 41 | host=NONE |
| 42 | no_create= |
| 43 | nonopt=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 44 | no_recursion= |
| 45 | prefix=NONE |
| 46 | program_prefix=NONE |
| 47 | program_suffix=NONE |
| 48 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 49 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 50 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 51 | srcdir= |
| 52 | target=NONE |
| 53 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 54 | x_includes=NONE |
| 55 | x_libraries=NONE |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 56 | bindir='${exec_prefix}/bin' |
| 57 | sbindir='${exec_prefix}/sbin' |
| 58 | libexecdir='${exec_prefix}/libexec' |
| 59 | datadir='${prefix}/share' |
| 60 | sysconfdir='${prefix}/etc' |
| 61 | sharedstatedir='${prefix}/com' |
| 62 | localstatedir='${prefix}/var' |
| 63 | libdir='${exec_prefix}/lib' |
| 64 | includedir='${prefix}/include' |
| 65 | oldincludedir='/usr/include' |
| 66 | infodir='${prefix}/info' |
| 67 | mandir='${prefix}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 68 | |
| 69 | # Initialize some other variables. |
| 70 | subdirs= |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 71 | MFLAGS= MAKEFLAGS= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 72 | |
| 73 | ac_prev= |
| 74 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 75 | do |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 76 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 77 | # If the previous option needs an argument, assign it. |
| 78 | if test -n "$ac_prev"; then |
| 79 | eval "$ac_prev=\$ac_option" |
| 80 | ac_prev= |
| 81 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 82 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 83 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 84 | case "$ac_option" in |
| 85 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; |
| 86 | *) ac_optarg= ;; |
| 87 | esac |
| 88 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 89 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 90 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 91 | case "$ac_option" in |
| 92 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 93 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 94 | ac_prev=bindir ;; |
| 95 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
| 96 | bindir="$ac_optarg" ;; |
| 97 | |
| 98 | -build | --build | --buil | --bui | --bu) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 99 | ac_prev=build ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 100 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 101 | build="$ac_optarg" ;; |
| 102 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 103 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 104 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 105 | ac_prev=cache_file ;; |
| 106 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 107 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
| 108 | cache_file="$ac_optarg" ;; |
| 109 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 110 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
| 111 | ac_prev=datadir ;; |
| 112 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ |
| 113 | | --da=*) |
| 114 | datadir="$ac_optarg" ;; |
| 115 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 116 | -disable-* | --disable-*) |
| 117 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 118 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 119 | 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] | 120 | { 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] | 121 | fi |
| 122 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 123 | eval "enable_${ac_feature}=no" ;; |
| 124 | |
| 125 | -enable-* | --enable-*) |
| 126 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 127 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 128 | 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] | 129 | { 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] | 130 | fi |
| 131 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 132 | case "$ac_option" in |
| 133 | *=*) ;; |
| 134 | *) ac_optarg=yes ;; |
| 135 | esac |
| 136 | eval "enable_${ac_feature}='$ac_optarg'" ;; |
| 137 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 138 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 139 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 140 | | --exec | --exe | --ex) |
| 141 | ac_prev=exec_prefix ;; |
| 142 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 143 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 144 | | --exec=* | --exe=* | --ex=*) |
| 145 | exec_prefix="$ac_optarg" ;; |
| 146 | |
| 147 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 148 | # Obsolete; use --with-gas. |
| 149 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 150 | |
| 151 | -help | --help | --hel | --he) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 152 | # Omit some internal or obsolete options to make the list less imposing. |
| 153 | # 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] | 154 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 155 | Usage: configure [options] [host] |
| 156 | Options: [defaults in brackets after descriptions] |
| 157 | Configuration: |
| 158 | --cache-file=FILE cache test results in FILE |
| 159 | --help print this message |
| 160 | --no-create do not create output files |
| 161 | --quiet, --silent do not print \`checking...' messages |
| 162 | --version print the version of autoconf that created configure |
| 163 | Directory and file names: |
| 164 | --prefix=PREFIX install architecture-independent files in PREFIX |
| 165 | [$ac_default_prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 166 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 167 | [same as prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 168 | --bindir=DIR user executables in DIR [EPREFIX/bin] |
| 169 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] |
| 170 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] |
| 171 | --datadir=DIR read-only architecture-independent data in DIR |
| 172 | [PREFIX/share] |
| 173 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] |
| 174 | --sharedstatedir=DIR modifiable architecture-independent data in DIR |
| 175 | [PREFIX/com] |
| 176 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] |
| 177 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] |
| 178 | --includedir=DIR C header files in DIR [PREFIX/include] |
| 179 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] |
| 180 | --infodir=DIR info documentation in DIR [PREFIX/info] |
| 181 | --mandir=DIR man documentation in DIR [PREFIX/man] |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 182 | --srcdir=DIR find the sources in DIR [configure dir or ..] |
| 183 | --program-prefix=PREFIX prepend PREFIX to installed program names |
| 184 | --program-suffix=SUFFIX append SUFFIX to installed program names |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 185 | --program-transform-name=PROGRAM |
| 186 | run sed PROGRAM on installed program names |
| 187 | EOF |
| 188 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 189 | Host type: |
| 190 | --build=BUILD configure for building on BUILD [BUILD=HOST] |
| 191 | --host=HOST configure for HOST [guessed] |
| 192 | --target=TARGET configure for TARGET [TARGET=HOST] |
| 193 | Features and packages: |
| 194 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 195 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
| 196 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 197 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
| 198 | --x-includes=DIR X include files are in DIR |
| 199 | --x-libraries=DIR X library files are in DIR |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 200 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 201 | if test -n "$ac_help"; then |
| 202 | echo "--enable and --with options recognized:$ac_help" |
| 203 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 204 | exit 0 ;; |
| 205 | |
| 206 | -host | --host | --hos | --ho) |
| 207 | ac_prev=host ;; |
| 208 | -host=* | --host=* | --hos=* | --ho=*) |
| 209 | host="$ac_optarg" ;; |
| 210 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 211 | -includedir | --includedir | --includedi | --included | --include \ |
| 212 | | --includ | --inclu | --incl | --inc) |
| 213 | ac_prev=includedir ;; |
| 214 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 215 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
| 216 | includedir="$ac_optarg" ;; |
| 217 | |
| 218 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 219 | ac_prev=infodir ;; |
| 220 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
| 221 | infodir="$ac_optarg" ;; |
| 222 | |
| 223 | -libdir | --libdir | --libdi | --libd) |
| 224 | ac_prev=libdir ;; |
| 225 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
| 226 | libdir="$ac_optarg" ;; |
| 227 | |
| 228 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 229 | | --libexe | --libex | --libe) |
| 230 | ac_prev=libexecdir ;; |
| 231 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 232 | | --libexe=* | --libex=* | --libe=*) |
| 233 | libexecdir="$ac_optarg" ;; |
| 234 | |
| 235 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
| 236 | | --localstate | --localstat | --localsta | --localst \ |
| 237 | | --locals | --local | --loca | --loc | --lo) |
| 238 | ac_prev=localstatedir ;; |
| 239 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
| 240 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ |
| 241 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) |
| 242 | localstatedir="$ac_optarg" ;; |
| 243 | |
| 244 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 245 | ac_prev=mandir ;; |
| 246 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
| 247 | mandir="$ac_optarg" ;; |
| 248 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 249 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 250 | # Obsolete; use --without-fp. |
| 251 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 252 | |
| 253 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 254 | | --no-cr | --no-c) |
| 255 | no_create=yes ;; |
| 256 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 257 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 258 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 259 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 260 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 261 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 262 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 263 | | --oldin | --oldi | --old | --ol | --o) |
| 264 | ac_prev=oldincludedir ;; |
| 265 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 266 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 267 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
| 268 | oldincludedir="$ac_optarg" ;; |
| 269 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 270 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 271 | ac_prev=prefix ;; |
| 272 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
| 273 | prefix="$ac_optarg" ;; |
| 274 | |
| 275 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 276 | | --program-pre | --program-pr | --program-p) |
| 277 | ac_prev=program_prefix ;; |
| 278 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 279 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
| 280 | program_prefix="$ac_optarg" ;; |
| 281 | |
| 282 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 283 | | --program-suf | --program-su | --program-s) |
| 284 | ac_prev=program_suffix ;; |
| 285 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 286 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
| 287 | program_suffix="$ac_optarg" ;; |
| 288 | |
| 289 | -program-transform-name | --program-transform-name \ |
| 290 | | --program-transform-nam | --program-transform-na \ |
| 291 | | --program-transform-n | --program-transform- \ |
| 292 | | --program-transform | --program-transfor \ |
| 293 | | --program-transfo | --program-transf \ |
| 294 | | --program-trans | --program-tran \ |
| 295 | | --progr-tra | --program-tr | --program-t) |
| 296 | ac_prev=program_transform_name ;; |
| 297 | -program-transform-name=* | --program-transform-name=* \ |
| 298 | | --program-transform-nam=* | --program-transform-na=* \ |
| 299 | | --program-transform-n=* | --program-transform-=* \ |
| 300 | | --program-transform=* | --program-transfor=* \ |
| 301 | | --program-transfo=* | --program-transf=* \ |
| 302 | | --program-trans=* | --program-tran=* \ |
| 303 | | --progr-tra=* | --program-tr=* | --program-t=*) |
| 304 | program_transform_name="$ac_optarg" ;; |
| 305 | |
| 306 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 307 | | -silent | --silent | --silen | --sile | --sil) |
| 308 | silent=yes ;; |
| 309 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 310 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 311 | ac_prev=sbindir ;; |
| 312 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 313 | | --sbi=* | --sb=*) |
| 314 | sbindir="$ac_optarg" ;; |
| 315 | |
| 316 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 317 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 318 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 319 | | --sha | --sh) |
| 320 | ac_prev=sharedstatedir ;; |
| 321 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 322 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 323 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 324 | | --sha=* | --sh=*) |
| 325 | sharedstatedir="$ac_optarg" ;; |
| 326 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 327 | -site | --site | --sit) |
| 328 | ac_prev=site ;; |
| 329 | -site=* | --site=* | --sit=*) |
| 330 | site="$ac_optarg" ;; |
| 331 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 332 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 333 | ac_prev=srcdir ;; |
| 334 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
| 335 | srcdir="$ac_optarg" ;; |
| 336 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 337 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 338 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 339 | ac_prev=sysconfdir ;; |
| 340 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 341 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
| 342 | sysconfdir="$ac_optarg" ;; |
| 343 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 344 | -target | --target | --targe | --targ | --tar | --ta | --t) |
| 345 | ac_prev=target ;; |
| 346 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
| 347 | target="$ac_optarg" ;; |
| 348 | |
| 349 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 350 | verbose=yes ;; |
| 351 | |
| 352 | -version | --version | --versio | --versi | --vers) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 353 | echo "configure generated by autoconf version 2.10" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 354 | exit 0 ;; |
| 355 | |
| 356 | -with-* | --with-*) |
| 357 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 358 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 359 | 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] | 360 | { 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] | 361 | fi |
| 362 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 363 | case "$ac_option" in |
| 364 | *=*) ;; |
| 365 | *) ac_optarg=yes ;; |
| 366 | esac |
| 367 | eval "with_${ac_package}='$ac_optarg'" ;; |
| 368 | |
| 369 | -without-* | --without-*) |
| 370 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` |
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 | eval "with_${ac_package}=no" ;; |
| 377 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 378 | --x) |
| 379 | # Obsolete; use --with-x. |
| 380 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 381 | |
| 382 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 383 | | --x-incl | --x-inc | --x-in | --x-i) |
| 384 | ac_prev=x_includes ;; |
| 385 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 386 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
| 387 | x_includes="$ac_optarg" ;; |
| 388 | |
| 389 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 390 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 391 | ac_prev=x_libraries ;; |
| 392 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 393 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
| 394 | x_libraries="$ac_optarg" ;; |
| 395 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 396 | -*) { 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] | 397 | ;; |
| 398 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 399 | *) |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 400 | 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] | 401 | echo "configure: warning: $ac_option: invalid host type" 1>&2 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 402 | fi |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 403 | if test "x$nonopt" != xNONE; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 404 | { 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] | 405 | fi |
| 406 | nonopt="$ac_option" |
| 407 | ;; |
| 408 | |
| 409 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 410 | done |
| 411 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 412 | if test -n "$ac_prev"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 413 | { 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] | 414 | fi |
| 415 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 416 | 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] | 417 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 418 | # File descriptor usage: |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 419 | # 0 standard input |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 420 | # 1 file creation |
| 421 | # 2 errors and warnings |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 422 | # 3 some systems may open it to /dev/tty |
| 423 | # 4 used on the Kubota Titan |
| 424 | # 6 checking for... messages and results |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 425 | # 5 compiler messages saved in config.log |
| 426 | if test "$silent" = yes; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 427 | exec 6>/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 428 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 429 | exec 6>&1 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 430 | fi |
| 431 | exec 5>./config.log |
| 432 | |
| 433 | echo "\ |
| 434 | This file contains any messages produced by compilers while |
| 435 | running configure, to aid debugging if configure makes a mistake. |
| 436 | " 1>&5 |
| 437 | |
| 438 | # Strip out --no-create and --no-recursion so they do not pile up. |
| 439 | # Also quote any args containing shell metacharacters. |
| 440 | ac_configure_args= |
| 441 | for ac_arg |
| 442 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 443 | case "$ac_arg" in |
| 444 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 445 | | --no-cr | --no-c) ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 446 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 447 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; |
| 448 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) |
| 449 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; |
| 450 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 451 | esac |
| 452 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 453 | |
| 454 | # NLS nuisances. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 455 | # Only set LANG and LC_ALL to C if already set. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 456 | # These must not be set unconditionally because not all systems understand |
| 457 | # e.g. LANG=C (notably SCO). |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 458 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi |
| 459 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 460 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 461 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
| 462 | rm -rf conftest* confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 463 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. |
| 464 | echo > confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 465 | |
| 466 | # A filename unique to this package, relative to the directory that |
| 467 | # 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] | 468 | ac_unique_file=Include/object.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 469 | |
| 470 | # Find the source files, if location was not specified. |
| 471 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 472 | ac_srcdir_defaulted=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 473 | # Try the directory containing this script, then its parent. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 474 | ac_prog=$0 |
| 475 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` |
| 476 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
| 477 | srcdir=$ac_confdir |
| 478 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 479 | srcdir=.. |
| 480 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 481 | else |
| 482 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 483 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 484 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 485 | if test "$ac_srcdir_defaulted" = yes; then |
| 486 | { 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] | 487 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 488 | { 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] | 489 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 490 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 491 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` |
| 492 | |
| 493 | # Prefer explicitly selected file to automatically selected ones. |
| 494 | if test -z "$CONFIG_SITE"; then |
| 495 | if test "x$prefix" != xNONE; then |
| 496 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" |
| 497 | else |
| 498 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" |
| 499 | fi |
| 500 | fi |
| 501 | for ac_site_file in $CONFIG_SITE; do |
| 502 | if test -r "$ac_site_file"; then |
| 503 | echo "loading site script $ac_site_file" |
| 504 | . "$ac_site_file" |
| 505 | fi |
| 506 | done |
| 507 | |
| 508 | if test -r "$cache_file"; then |
| 509 | echo "loading cache $cache_file" |
| 510 | . $cache_file |
| 511 | else |
| 512 | echo "creating cache $cache_file" |
| 513 | > $cache_file |
| 514 | fi |
| 515 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 516 | ac_ext=c |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 517 | # 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] | 518 | ac_cpp='$CPP $CPPFLAGS' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 519 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 520 | ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 521 | |
| 522 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then |
| 523 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. |
| 524 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then |
| 525 | ac_n= ac_c=' |
| 526 | ' ac_t=' ' |
| 527 | else |
| 528 | ac_n=-n ac_c= ac_t= |
| 529 | fi |
| 530 | else |
| 531 | ac_n= ac_c='\c' ac_t= |
| 532 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 533 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 534 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 535 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 536 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 537 | # NEXTSTEP stuff |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 538 | if test -f /usr/lib/NextStep/software_version; then |
| 539 | |
| 540 | echo $ac_n "checking for --with-next-archs""... $ac_c" 1>&6 |
| 541 | # Check whether --with-next-archs or --without-next-archs was given. |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 542 | if test "${with_next_archs+set}" = set; then |
| 543 | withval="$with_next_archs" |
| 544 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 545 | if test -n "$withval"; then |
| 546 | ac_arch_flags=`/usr/lib/arch_tool -archify_list $withval` |
| 547 | # GCC does not currently support multi archs on the NeXT |
| 548 | with_gcc=no |
| 549 | fi |
| 550 | echo "$ac_t""$with_next_archs" 1>&6 |
| 551 | |
| 552 | else |
| 553 | echo "$ac_t""none: using `arch`" 1>&6 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 554 | fi |
| 555 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 556 | |
| 557 | if test -z "$MACHDEP" |
| 558 | then |
| 559 | set X `hostinfo | grep 'NeXT Mach.*:' | \ |
| 560 | sed -e 's/://' -e 's/\./_/'` && \ |
| 561 | ac_sys_system=next && ac_sys_release=$4 |
| 562 | |
| 563 | MACHDEP="$ac_sys_system$ac_sys_release" |
| 564 | fi |
| 565 | fi |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 566 | |
| 567 | # Set name for machine-dependent library files |
| 568 | |
| 569 | echo $ac_n "checking MACHDEP""... $ac_c" 1>&6 |
| 570 | if test -z "$MACHDEP" |
| 571 | then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 572 | ac_sys_system=`uname -s` |
| 573 | if test "$ac_sys_system" = "AIX" ; then |
| 574 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 575 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 576 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 577 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 578 | ac_md_system=`echo $ac_sys_system | |
| 579 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 580 | ac_md_release=`echo $ac_sys_release | |
| 581 | tr -d '/ ' | sed 's/\..*//'` |
| 582 | MACHDEP="$ac_md_system$ac_md_release" |
| 583 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 584 | case MACHDEP in |
| 585 | '') MACHDEP=unknown;; |
| 586 | esac |
| 587 | fi |
| 588 | echo "$ac_t""$MACHDEP" 1>&6 |
| 589 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 590 | # checks for alternative programs |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 591 | echo $ac_n "checking for --without-gcc""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 592 | # Check whether --with-gcc or --without-gcc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 593 | if test "${with_gcc+set}" = set; then |
| 594 | withval="$with_gcc" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 595 | |
| 596 | case $withval in |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 597 | no) CC=cc |
| 598 | without_gcc=yes;; |
| 599 | yes) CC=gcc |
| 600 | without_gcc=no;; |
| 601 | *) CC=$withval |
| 602 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 603 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 604 | else |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 605 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 606 | case $ac_sys_system in |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 607 | OSF1) CC=cc |
| 608 | without_gcc=;; |
| 609 | *) without_gcc=no;; |
| 610 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 611 | fi |
| 612 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 613 | echo "$ac_t""$without_gcc" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 614 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 615 | # If the user switches compilers, we can't believe the cache |
| 616 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 617 | then |
| 618 | { echo "configure: error: cached CC is different -- throw away $cache_file |
| 619 | (it is also a good idea to do 'make clean' before compiling)" 1>&2; exit 1; } |
| 620 | fi |
| 621 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 622 | # Extract the first word of "gcc", so it can be a program name with args. |
| 623 | set dummy gcc; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 624 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 625 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
| 626 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 627 | else |
| 628 | if test -n "$CC"; then |
| 629 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 630 | else |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 631 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
| 632 | for ac_dir in $PATH; do |
| 633 | test -z "$ac_dir" && ac_dir=. |
| 634 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 635 | ac_cv_prog_CC="gcc" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 636 | break |
| 637 | fi |
| 638 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 639 | IFS="$ac_save_ifs" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 640 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 641 | fi |
| 642 | CC="$ac_cv_prog_CC" |
| 643 | if test -n "$CC"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 644 | echo "$ac_t""$CC" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 645 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 646 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 647 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 648 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 649 | if test -z "$CC"; then |
| 650 | # Extract the first word of "cc", so it can be a program name with args. |
| 651 | set dummy cc; ac_word=$2 |
| 652 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 653 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
| 654 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 655 | else |
| 656 | if test -n "$CC"; then |
| 657 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 658 | else |
| 659 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
| 660 | ac_prog_rejected=no |
| 661 | for ac_dir in $PATH; do |
| 662 | test -z "$ac_dir" && ac_dir=. |
| 663 | if test -f $ac_dir/$ac_word; then |
| 664 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then |
| 665 | ac_prog_rejected=yes |
| 666 | continue |
| 667 | fi |
| 668 | ac_cv_prog_CC="cc" |
| 669 | break |
| 670 | fi |
| 671 | done |
| 672 | IFS="$ac_save_ifs" |
| 673 | if test $ac_prog_rejected = yes; then |
| 674 | # We found a bogon in the path, so make sure we never use it. |
| 675 | set dummy $ac_cv_prog_CC |
| 676 | shift |
| 677 | if test $# -gt 0; then |
| 678 | # We chose a different compiler from the bogus one. |
| 679 | # However, it has the same basename, so the bogon will be chosen |
| 680 | # first if we set CC to just the basename; use the full file name. |
| 681 | shift |
| 682 | set dummy "$ac_dir/$ac_word" "$@" |
| 683 | shift |
| 684 | ac_cv_prog_CC="$@" |
| 685 | fi |
| 686 | fi |
| 687 | fi |
| 688 | fi |
| 689 | CC="$ac_cv_prog_CC" |
| 690 | if test -n "$CC"; then |
| 691 | echo "$ac_t""$CC" 1>&6 |
| 692 | else |
| 693 | echo "$ac_t""no" 1>&6 |
| 694 | fi |
| 695 | |
| 696 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } |
| 697 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 698 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 699 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 |
| 700 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
| 701 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 702 | else |
| 703 | cat > conftest.c <<EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 704 | #ifdef __GNUC__ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 705 | yes; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 706 | #endif |
| 707 | EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 708 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:709: \"$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] | 709 | ac_cv_prog_gcc=yes |
| 710 | else |
| 711 | ac_cv_prog_gcc=no |
| 712 | fi |
| 713 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 714 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 715 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 716 | if test $ac_cv_prog_gcc = yes; then |
| 717 | GCC=yes |
| 718 | if test "${CFLAGS+set}" != set; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 719 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 |
| 720 | if eval "test \"`echo '$''{'ac_cv_prog_gcc_g'+set}'`\" = set"; then |
| 721 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 722 | else |
| 723 | echo 'void f(){}' > conftest.c |
| 724 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then |
| 725 | ac_cv_prog_gcc_g=yes |
| 726 | else |
| 727 | ac_cv_prog_gcc_g=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 728 | fi |
| 729 | rm -f conftest* |
| 730 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 731 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 732 | |
| 733 | echo "$ac_t""$ac_cv_prog_gcc_g" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 734 | if test $ac_cv_prog_gcc_g = yes; then |
| 735 | CFLAGS="-g -O" |
| 736 | else |
| 737 | CFLAGS="-O" |
| 738 | fi |
| 739 | fi |
| 740 | else |
| 741 | GCC= |
| 742 | test "${CFLAGS+set}" = set || CFLAGS="-g" |
| 743 | fi |
| 744 | |
| 745 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 746 | set dummy ranlib; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 747 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 748 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
| 749 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 750 | else |
| 751 | if test -n "$RANLIB"; then |
| 752 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 753 | else |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 754 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
| 755 | for ac_dir in $PATH; do |
| 756 | test -z "$ac_dir" && ac_dir=. |
| 757 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 758 | ac_cv_prog_RANLIB="ranlib" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 759 | break |
| 760 | fi |
| 761 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 762 | IFS="$ac_save_ifs" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 763 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 764 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 765 | fi |
| 766 | RANLIB="$ac_cv_prog_RANLIB" |
| 767 | if test -n "$RANLIB"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 768 | echo "$ac_t""$RANLIB" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 769 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 770 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 771 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 772 | |
| 773 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 774 | for ac_prog in ar aal |
| 775 | do |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 776 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 777 | set dummy $ac_prog; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 778 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 779 | if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then |
| 780 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 781 | else |
| 782 | if test -n "$AR"; then |
| 783 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 784 | else |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 785 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" |
| 786 | for ac_dir in $PATH; do |
| 787 | test -z "$ac_dir" && ac_dir=. |
| 788 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 789 | ac_cv_prog_AR="$ac_prog" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 790 | break |
| 791 | fi |
| 792 | done |
| 793 | IFS="$ac_save_ifs" |
| 794 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 795 | fi |
| 796 | AR="$ac_cv_prog_AR" |
| 797 | if test -n "$AR"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 798 | echo "$ac_t""$AR" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 799 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 800 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 801 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 802 | |
| 803 | test -n "$AR" && break |
| 804 | done |
| 805 | test -n "$AR" || AR="ar" |
| 806 | |
| 807 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 808 | |
| 809 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 810 | # Install just never works :-( |
| 811 | if test -z "$INSTALL" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 812 | then |
| 813 | INSTALL=cp |
| 814 | INSTALL_PROGRAM=cp |
| 815 | INSTALL_DATA=cp |
| 816 | else |
| 817 | INSTALL_PROGRAM="$INSTALL" |
| 818 | INSTALL_DATA="$INSTALL -m 644" |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 819 | fi |
| 820 | |
| 821 | # Optimizer/debugger flags passed between Makefiles |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 822 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 823 | if test -z "$OPT" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 824 | then |
| 825 | case $ac_sys_system in |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 826 | *) OPT="-O";; |
| 827 | esac |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 828 | fi |
| 829 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 830 | if test "$ac_arch_flags" |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 831 | then |
| 832 | OPT="$OPT $ac_arch_flags" |
| 833 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 834 | # checks for UNIX variants that set C preprocessor variables |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 835 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 836 | # On Suns, sometimes $CPP names a directory. |
| 837 | if test -n "$CPP" && test -d "$CPP"; then |
| 838 | CPP= |
| 839 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 840 | if test -z "$CPP"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 841 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then |
| 842 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 843 | else |
| 844 | # This must be in double quotes, not single quotes, because CPP may get |
| 845 | # substituted into the Makefile and "${CC-cc}" will confuse make. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 846 | CPP="${CC-cc} -E" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 847 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 848 | # not just through cpp. |
| 849 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 850 | #line 851 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 851 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 852 | #include <assert.h> |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 853 | Syntax Error |
| 854 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 855 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 856 | { (eval echo configure:857: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 857 | ac_err=`grep -v '^ *+' conftest.out` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 858 | if test -z "$ac_err"; then |
| 859 | : |
| 860 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 861 | echo "$ac_err" >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 862 | rm -rf conftest* |
| 863 | CPP="${CC-cc} -E -traditional-cpp" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 864 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 865 | #line 866 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 866 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 867 | #include <assert.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 868 | Syntax Error |
| 869 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 870 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 871 | { (eval echo configure:872: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 872 | ac_err=`grep -v '^ *+' conftest.out` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 873 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 874 | : |
| 875 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 876 | echo "$ac_err" >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 877 | rm -rf conftest* |
| 878 | CPP=/lib/cpp |
| 879 | fi |
| 880 | rm -f conftest* |
| 881 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 882 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 883 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 884 | fi |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 885 | CPP="$ac_cv_prog_CPP" |
| 886 | else |
| 887 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 888 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 889 | echo "$ac_t""$CPP" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 890 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 891 | echo $ac_n "checking for AIX""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 892 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 893 | #line 894 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 894 | #include "confdefs.h" |
| 895 | #ifdef _AIX |
| 896 | yes |
| 897 | #endif |
| 898 | |
| 899 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 900 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 901 | egrep "yes" >/dev/null 2>&1; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 902 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 903 | echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 904 | #define _ALL_SOURCE 1 |
| 905 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 906 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 907 | else |
| 908 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 909 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 910 | fi |
| 911 | rm -f conftest* |
| 912 | |
| 913 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 914 | ac_safe=`echo "minix/config.h" | tr './\055' '___'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 915 | echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6 |
| 916 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 917 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 918 | else |
| 919 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 920 | #line 921 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 921 | #include "confdefs.h" |
| 922 | #include <minix/config.h> |
| 923 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 924 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 925 | { (eval echo configure:926: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 926 | ac_err=`grep -v '^ *+' conftest.out` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 927 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 928 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 929 | eval "ac_cv_header_$ac_safe=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 930 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 931 | echo "$ac_err" >&5 |
| 932 | rm -rf conftest* |
| 933 | eval "ac_cv_header_$ac_safe=no" |
| 934 | fi |
| 935 | rm -f conftest* |
| 936 | fi |
| 937 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 938 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 939 | MINIX=yes |
| 940 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 941 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 942 | MINIX= |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 943 | fi |
| 944 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 945 | if test "$MINIX" = yes; then |
| 946 | cat >> confdefs.h <<\EOF |
| 947 | #define _POSIX_SOURCE 1 |
| 948 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 949 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 950 | cat >> confdefs.h <<\EOF |
| 951 | #define _POSIX_1_SOURCE 2 |
| 952 | EOF |
| 953 | |
| 954 | cat >> confdefs.h <<\EOF |
| 955 | #define _MINIX 1 |
| 956 | EOF |
| 957 | |
| 958 | fi |
| 959 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 960 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 961 | # check for ANSI or K&R ("traditional") preprocessor |
| 962 | echo $ac_n "checking for C preprocessor type""... $ac_c" 1>&6 |
| 963 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 964 | #line 965 "configure" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 965 | #include "confdefs.h" |
| 966 | |
| 967 | #define spam(name, doc) {#name, &name, #name "() -- " doc} |
| 968 | int foo; |
| 969 | struct {char *name; int *addr; char *doc;} desc = spam(foo, "something"); |
| 970 | |
| 971 | int main() { return 0; } |
| 972 | int t() { |
| 973 | ; |
| 974 | ; return 0; } |
| 975 | EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 976 | if { (eval echo configure:977: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 977 | rm -rf conftest* |
| 978 | cpp_type=ansi |
| 979 | else |
| 980 | rm -rf conftest* |
| 981 | cat >> confdefs.h <<\EOF |
| 982 | #define HAVE_OLD_CPP 1 |
| 983 | EOF |
| 984 | cpp_type=traditional |
| 985 | fi |
| 986 | rm -f conftest* |
| 987 | |
| 988 | echo "$ac_t""$cpp_type" 1>&6 |
| 989 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 990 | # checks for header files |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 991 | # If we cannot run a trivial program, we must be cross compiling. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 992 | echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6 |
| 993 | if eval "test \"`echo '$''{'ac_cv_c_cross'+set}'`\" = set"; then |
| 994 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 995 | else |
| 996 | if test "$cross_compiling" = yes; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 997 | ac_cv_c_cross=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 998 | else |
| 999 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1000 | #line 1001 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1001 | #include "confdefs.h" |
| 1002 | main(){return(0);} |
| 1003 | EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1004 | { (eval echo configure:1005: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1005 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
| 1006 | ac_cv_c_cross=no |
| 1007 | else |
| 1008 | ac_cv_c_cross=yes |
| 1009 | fi |
| 1010 | fi |
| 1011 | rm -fr conftest* |
| 1012 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1013 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1014 | echo "$ac_t""$ac_cv_c_cross" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1015 | cross_compiling=$ac_cv_c_cross |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1016 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1017 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 |
| 1018 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
| 1019 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1020 | else |
| 1021 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1022 | #line 1023 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1023 | #include "confdefs.h" |
| 1024 | #include <stdlib.h> |
| 1025 | #include <stdarg.h> |
| 1026 | #include <string.h> |
| 1027 | #include <float.h> |
| 1028 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1029 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1030 | { (eval echo configure:1031: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1031 | ac_err=`grep -v '^ *+' conftest.out` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1032 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1033 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1034 | ac_cv_header_stdc=yes |
| 1035 | else |
| 1036 | echo "$ac_err" >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1037 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1038 | ac_cv_header_stdc=no |
| 1039 | fi |
| 1040 | rm -f conftest* |
| 1041 | |
| 1042 | if test $ac_cv_header_stdc = yes; then |
| 1043 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 1044 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1045 | #line 1046 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1046 | #include "confdefs.h" |
| 1047 | #include <string.h> |
| 1048 | EOF |
| 1049 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1050 | egrep "memchr" >/dev/null 2>&1; then |
| 1051 | : |
| 1052 | else |
| 1053 | rm -rf conftest* |
| 1054 | ac_cv_header_stdc=no |
| 1055 | fi |
| 1056 | rm -f conftest* |
| 1057 | |
| 1058 | fi |
| 1059 | |
| 1060 | if test $ac_cv_header_stdc = yes; then |
| 1061 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 1062 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1063 | #line 1064 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1064 | #include "confdefs.h" |
| 1065 | #include <stdlib.h> |
| 1066 | EOF |
| 1067 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1068 | egrep "free" >/dev/null 2>&1; then |
| 1069 | : |
| 1070 | else |
| 1071 | rm -rf conftest* |
| 1072 | ac_cv_header_stdc=no |
| 1073 | fi |
| 1074 | rm -f conftest* |
| 1075 | |
| 1076 | fi |
| 1077 | |
| 1078 | if test $ac_cv_header_stdc = yes; then |
| 1079 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 1080 | if test "$cross_compiling" = yes; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1081 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1082 | else |
| 1083 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1084 | #line 1085 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1085 | #include "confdefs.h" |
| 1086 | #include <ctype.h> |
| 1087 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 1088 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1089 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1090 | int main () { int i; for (i = 0; i < 256; i++) |
| 1091 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); |
| 1092 | exit (0); } |
| 1093 | |
| 1094 | EOF |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1095 | { (eval echo configure:1096: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1096 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1097 | : |
| 1098 | else |
| 1099 | ac_cv_header_stdc=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1100 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1101 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1102 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1103 | fi |
| 1104 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1105 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1106 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1107 | if test $ac_cv_header_stdc = yes; then |
| 1108 | cat >> confdefs.h <<\EOF |
| 1109 | #define STDC_HEADERS 1 |
| 1110 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1111 | |
| 1112 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1113 | |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 1114 | for ac_hdr in dlfcn.h fcntl.h limits.h ncurses.h \ |
| 1115 | 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^] | 1116 | sys/audioio.h sys/file.h sys/lock.h \ |
| 1117 | 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] | 1118 | sys/un.h sys/utsname.h sys/wait.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1119 | do |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1120 | ac_safe=`echo "$ac_hdr" | tr './\055' '___'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1121 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 1122 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 1123 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1124 | else |
| 1125 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1126 | #line 1127 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1127 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1128 | #include <$ac_hdr> |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1129 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1130 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1131 | { (eval echo configure:1132: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1132 | ac_err=`grep -v '^ *+' conftest.out` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1133 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1134 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1135 | eval "ac_cv_header_$ac_safe=yes" |
| 1136 | else |
| 1137 | echo "$ac_err" >&5 |
| 1138 | rm -rf conftest* |
| 1139 | eval "ac_cv_header_$ac_safe=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1140 | fi |
| 1141 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1142 | fi |
| 1143 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1144 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1145 | ac_tr_hdr=HAVE_`echo $ac_hdr | tr 'abcdefghijklmnopqrstuvwxyz./\055' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ___'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1146 | cat >> confdefs.h <<EOF |
| 1147 | #define $ac_tr_hdr 1 |
| 1148 | EOF |
| 1149 | |
| 1150 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1151 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1152 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1153 | done |
| 1154 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1155 | ac_header_dirent=no |
| 1156 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h |
| 1157 | do |
| 1158 | ac_safe=`echo "$ac_hdr" | tr './\055' '___'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1159 | echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6 |
| 1160 | if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then |
| 1161 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1162 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1163 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1164 | #line 1165 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1165 | #include "confdefs.h" |
| 1166 | #include <sys/types.h> |
| 1167 | #include <$ac_hdr> |
| 1168 | int main() { return 0; } |
| 1169 | int t() { |
| 1170 | DIR *dirp = 0; |
| 1171 | ; return 0; } |
| 1172 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1173 | if { (eval echo configure:1174: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1174 | rm -rf conftest* |
| 1175 | eval "ac_cv_header_dirent_$ac_safe=yes" |
| 1176 | else |
| 1177 | rm -rf conftest* |
| 1178 | eval "ac_cv_header_dirent_$ac_safe=no" |
| 1179 | fi |
| 1180 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1181 | |
| 1182 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1183 | 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] | 1184 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1185 | ac_tr_hdr=HAVE_`echo $ac_hdr | tr 'abcdedfghijklmnopqrstuvwxyz./\055' 'ABCDEDFGHIJKLMNOPQRSTUVWXYZ___'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1186 | cat >> confdefs.h <<EOF |
| 1187 | #define $ac_tr_hdr 1 |
| 1188 | EOF |
| 1189 | ac_header_dirent=$ac_hdr; break |
| 1190 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1191 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1192 | fi |
| 1193 | done |
| 1194 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 1195 | if test $ac_header_dirent = dirent.h; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1196 | echo $ac_n "checking for -ldir""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1197 | ac_lib_var=`echo dir'_'opendir | tr './+\055' '__p_'` |
| 1198 | 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] | 1199 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1200 | else |
| 1201 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1202 | LIBS="-ldir $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1203 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1204 | #line 1205 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1205 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1206 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1207 | /* We use char because int might match the return type of a gcc2 |
| 1208 | builtin and then its argument prototype would still apply. */ |
| 1209 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1210 | |
| 1211 | int main() { return 0; } |
| 1212 | int t() { |
| 1213 | opendir() |
| 1214 | ; return 0; } |
| 1215 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1216 | if { (eval echo configure:1217: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1217 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1218 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1219 | else |
| 1220 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1221 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1222 | fi |
| 1223 | rm -f conftest* |
| 1224 | LIBS="$ac_save_LIBS" |
| 1225 | |
| 1226 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1227 | 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] | 1228 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1229 | LIBS="$LIBS -ldir" |
| 1230 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1231 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1232 | fi |
| 1233 | |
| 1234 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1235 | echo $ac_n "checking for -lx""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1236 | ac_lib_var=`echo x'_'opendir | tr './+\055' '__p_'` |
| 1237 | 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] | 1238 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1239 | else |
| 1240 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1241 | LIBS="-lx $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1242 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1243 | #line 1244 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1244 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1245 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1246 | /* We use char because int might match the return type of a gcc2 |
| 1247 | builtin and then its argument prototype would still apply. */ |
| 1248 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1249 | |
| 1250 | int main() { return 0; } |
| 1251 | int t() { |
| 1252 | opendir() |
| 1253 | ; return 0; } |
| 1254 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1255 | if { (eval echo configure:1256: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1256 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1257 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1258 | else |
| 1259 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1260 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1261 | fi |
| 1262 | rm -f conftest* |
| 1263 | LIBS="$ac_save_LIBS" |
| 1264 | |
| 1265 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1266 | 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] | 1267 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1268 | LIBS="$LIBS -lx" |
| 1269 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1270 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1271 | fi |
| 1272 | |
| 1273 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1274 | |
| 1275 | |
| 1276 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1277 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1278 | echo $ac_n "checking for clock_t in time.h""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1279 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1280 | #line 1281 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1281 | #include "confdefs.h" |
| 1282 | #include <time.h> |
| 1283 | EOF |
| 1284 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1285 | egrep "clock_t" >/dev/null 2>&1; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1286 | rm -rf conftest* |
| 1287 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1288 | else |
| 1289 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1290 | cat >> confdefs.h <<\EOF |
| 1291 | #define clock_t long |
| 1292 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1293 | |
| 1294 | fi |
| 1295 | rm -f conftest* |
| 1296 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1297 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1298 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1299 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 1300 | cat >> confdefs.h <<\EOF |
| 1301 | #if defined(SCO_DS) |
| 1302 | #undef _OFF_T |
| 1303 | #endif |
| 1304 | EOF |
| 1305 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1306 | echo $ac_n "checking for mode_t""... $ac_c" 1>&6 |
| 1307 | if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then |
| 1308 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1309 | else |
| 1310 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1311 | #line 1312 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1312 | #include "confdefs.h" |
| 1313 | #include <sys/types.h> |
| 1314 | #if STDC_HEADERS |
| 1315 | #include <stdlib.h> |
| 1316 | #endif |
| 1317 | EOF |
| 1318 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1319 | egrep "mode_t" >/dev/null 2>&1; then |
| 1320 | rm -rf conftest* |
| 1321 | ac_cv_type_mode_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1322 | else |
| 1323 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1324 | ac_cv_type_mode_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1325 | fi |
| 1326 | rm -f conftest* |
| 1327 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1328 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1329 | echo "$ac_t""$ac_cv_type_mode_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1330 | if test $ac_cv_type_mode_t = no; then |
| 1331 | cat >> confdefs.h <<\EOF |
| 1332 | #define mode_t int |
| 1333 | EOF |
| 1334 | |
| 1335 | fi |
| 1336 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1337 | echo $ac_n "checking for off_t""... $ac_c" 1>&6 |
| 1338 | if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then |
| 1339 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1340 | else |
| 1341 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1342 | #line 1343 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1343 | #include "confdefs.h" |
| 1344 | #include <sys/types.h> |
| 1345 | #if STDC_HEADERS |
| 1346 | #include <stdlib.h> |
| 1347 | #endif |
| 1348 | EOF |
| 1349 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1350 | egrep "off_t" >/dev/null 2>&1; then |
| 1351 | rm -rf conftest* |
| 1352 | ac_cv_type_off_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1353 | else |
| 1354 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1355 | ac_cv_type_off_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1356 | fi |
| 1357 | rm -f conftest* |
| 1358 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1359 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1360 | echo "$ac_t""$ac_cv_type_off_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1361 | if test $ac_cv_type_off_t = no; then |
| 1362 | cat >> confdefs.h <<\EOF |
| 1363 | #define off_t long |
| 1364 | EOF |
| 1365 | |
| 1366 | fi |
| 1367 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1368 | echo $ac_n "checking for pid_t""... $ac_c" 1>&6 |
| 1369 | if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then |
| 1370 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1371 | else |
| 1372 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1373 | #line 1374 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1374 | #include "confdefs.h" |
| 1375 | #include <sys/types.h> |
| 1376 | #if STDC_HEADERS |
| 1377 | #include <stdlib.h> |
| 1378 | #endif |
| 1379 | EOF |
| 1380 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1381 | egrep "pid_t" >/dev/null 2>&1; then |
| 1382 | rm -rf conftest* |
| 1383 | ac_cv_type_pid_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1384 | else |
| 1385 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1386 | ac_cv_type_pid_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1387 | fi |
| 1388 | rm -f conftest* |
| 1389 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1390 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1391 | echo "$ac_t""$ac_cv_type_pid_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1392 | if test $ac_cv_type_pid_t = no; then |
| 1393 | cat >> confdefs.h <<\EOF |
| 1394 | #define pid_t int |
| 1395 | EOF |
| 1396 | |
| 1397 | fi |
| 1398 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1399 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 |
| 1400 | if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then |
| 1401 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1402 | else |
| 1403 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1404 | #line 1405 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1405 | #include "confdefs.h" |
| 1406 | #include <sys/types.h> |
| 1407 | #include <signal.h> |
| 1408 | #ifdef signal |
| 1409 | #undef signal |
| 1410 | #endif |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1411 | #ifdef __cplusplus |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1412 | extern "C" void (*signal (int, void (*)(int)))(int); |
| 1413 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1414 | void (*signal ()) (); |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1415 | #endif |
| 1416 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1417 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1418 | int t() { |
| 1419 | int i; |
| 1420 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1421 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1422 | if { (eval echo configure:1423: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1423 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1424 | ac_cv_type_signal=void |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1425 | else |
| 1426 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1427 | ac_cv_type_signal=int |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1428 | fi |
| 1429 | rm -f conftest* |
| 1430 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1431 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1432 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1433 | echo "$ac_t""$ac_cv_type_signal" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1434 | cat >> confdefs.h <<EOF |
| 1435 | #define RETSIGTYPE $ac_cv_type_signal |
| 1436 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1437 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1438 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1439 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 |
| 1440 | if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then |
| 1441 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1442 | else |
| 1443 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1444 | #line 1445 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1445 | #include "confdefs.h" |
| 1446 | #include <sys/types.h> |
| 1447 | #if STDC_HEADERS |
| 1448 | #include <stdlib.h> |
| 1449 | #endif |
| 1450 | EOF |
| 1451 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1452 | egrep "size_t" >/dev/null 2>&1; then |
| 1453 | rm -rf conftest* |
| 1454 | ac_cv_type_size_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1455 | else |
| 1456 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1457 | ac_cv_type_size_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1458 | fi |
| 1459 | rm -f conftest* |
| 1460 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1461 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1462 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1463 | if test $ac_cv_type_size_t = no; then |
| 1464 | cat >> confdefs.h <<\EOF |
| 1465 | #define size_t unsigned |
| 1466 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1467 | |
| 1468 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1469 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1470 | echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 |
| 1471 | if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then |
| 1472 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1473 | else |
| 1474 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1475 | #line 1476 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1476 | #include "confdefs.h" |
| 1477 | #include <sys/types.h> |
| 1478 | EOF |
| 1479 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1480 | egrep "uid_t" >/dev/null 2>&1; then |
| 1481 | rm -rf conftest* |
| 1482 | ac_cv_type_uid_t=yes |
| 1483 | else |
| 1484 | rm -rf conftest* |
| 1485 | ac_cv_type_uid_t=no |
| 1486 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1487 | rm -f conftest* |
| 1488 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1489 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1490 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1491 | echo "$ac_t""$ac_cv_type_uid_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1492 | if test $ac_cv_type_uid_t = no; then |
| 1493 | cat >> confdefs.h <<\EOF |
| 1494 | #define uid_t int |
| 1495 | EOF |
| 1496 | |
| 1497 | cat >> confdefs.h <<\EOF |
| 1498 | #define gid_t int |
| 1499 | EOF |
| 1500 | |
| 1501 | fi |
| 1502 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1503 | |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1504 | echo $ac_n "checking size of int""... $ac_c" 1>&6 |
| 1505 | if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then |
| 1506 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1507 | else |
| 1508 | if test "$cross_compiling" = yes; then |
| 1509 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1510 | else |
| 1511 | cat > conftest.$ac_ext <<EOF |
| 1512 | #line 1513 "configure" |
| 1513 | #include "confdefs.h" |
| 1514 | #include <stdio.h> |
| 1515 | main() |
| 1516 | { |
| 1517 | FILE *f=fopen("conftestval", "w"); |
| 1518 | if (!f) exit(1); |
| 1519 | fprintf(f, "%d\n", sizeof(int)); |
| 1520 | exit(0); |
| 1521 | } |
| 1522 | EOF |
| 1523 | { (eval echo configure:1524: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
| 1524 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
| 1525 | ac_cv_sizeof_int=`cat conftestval` |
| 1526 | else |
| 1527 | ac_cv_sizeof_int=0 |
| 1528 | fi |
| 1529 | fi |
| 1530 | rm -fr conftest* |
| 1531 | fi |
| 1532 | echo "$ac_t""$ac_cv_sizeof_int" 1>&6 |
| 1533 | cat >> confdefs.h <<EOF |
| 1534 | #define SIZEOF_INT $ac_cv_sizeof_int |
| 1535 | EOF |
| 1536 | |
| 1537 | |
| 1538 | echo $ac_n "checking size of long""... $ac_c" 1>&6 |
| 1539 | if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then |
| 1540 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1541 | else |
| 1542 | if test "$cross_compiling" = yes; then |
| 1543 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1544 | else |
| 1545 | cat > conftest.$ac_ext <<EOF |
| 1546 | #line 1547 "configure" |
| 1547 | #include "confdefs.h" |
| 1548 | #include <stdio.h> |
| 1549 | main() |
| 1550 | { |
| 1551 | FILE *f=fopen("conftestval", "w"); |
| 1552 | if (!f) exit(1); |
| 1553 | fprintf(f, "%d\n", sizeof(long)); |
| 1554 | exit(0); |
| 1555 | } |
| 1556 | EOF |
| 1557 | { (eval echo configure:1558: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
| 1558 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
| 1559 | ac_cv_sizeof_long=`cat conftestval` |
| 1560 | else |
| 1561 | ac_cv_sizeof_long=0 |
| 1562 | fi |
| 1563 | fi |
| 1564 | rm -fr conftest* |
| 1565 | fi |
| 1566 | echo "$ac_t""$ac_cv_sizeof_long" 1>&6 |
| 1567 | cat >> confdefs.h <<EOF |
| 1568 | #define SIZEOF_LONG $ac_cv_sizeof_long |
| 1569 | EOF |
| 1570 | |
| 1571 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1572 | |
| 1573 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1574 | |
| 1575 | |
| 1576 | |
| 1577 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1578 | # SO is the extension of shared libraries `(including the dot!) |
| 1579 | # -- usually .so, .sl on HP-UX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1580 | echo $ac_n "checking SO""... $ac_c" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1581 | if test -z "$SO" |
| 1582 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1583 | case $ac_sys_system in |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1584 | hp*|HP*) SO=.sl;; |
| 1585 | *) SO=.so;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1586 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1587 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1588 | echo "$ac_t""$SO" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1589 | # LDSHARED is the ld *command* used to create shared library |
| 1590 | # -- "ld" on SunOS 4.x.x, "ld -G" on SunOS 5.x, "ld -shared" on IRIX 5 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1591 | echo $ac_n "checking LDSHARED""... $ac_c" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1592 | if test -z "$LDSHARED" |
| 1593 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1594 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1595 | AIX*) LDSHARED="ld_so_aix \$(CC)";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1596 | IRIX*) LDSHARED="ld -shared";; |
| 1597 | SunOS/4*) LDSHARED="ld";; |
| 1598 | SunOS/5*) LDSHARED="ld -G";; |
| 1599 | hp*|HP*) LDSHARED="ld -b";; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1600 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
| 1601 | DYNIX/ptx*) LDSHARED="ld -G";; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1602 | next/*) LDSHARED='$(CC) $(CFLAGS) -nostdlib -r';; |
Guido van Rossum | 81652ab | 1996-07-21 02:53:27 +0000 | [diff] [blame] | 1603 | Linux*) LDSHARED="gcc -shared";; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1604 | FreeBSD*) LDSHARED="ld -Bshareable";; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1605 | SCO_SV*) LDSHARED="cc -G -KPIC -Ki486 -belf -Wl,-Bexport";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1606 | *) LDSHARED="ld";; |
| 1607 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1608 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1609 | echo "$ac_t""$LDSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1610 | # CCSHARED are the C *flags* used to create objects to go into a shared |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1611 | # library -- this is only needed for a few systems |
| 1612 | echo $ac_n "checking CCSHARED""... $ac_c" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1613 | if test -z "$CCSHARED" |
| 1614 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1615 | case $ac_sys_system in |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 1616 | hp*|HP*) if test "$GCC" = yes; |
| 1617 | then CCSHARED="-fpic"; |
| 1618 | else CCSHARED="+z"; |
| 1619 | fi;; |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1620 | Linux*) CCSHARED="-fpic";; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1621 | FreeBSD*) CCSHARED="-fpic";; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1622 | SCO_SV*) CCSHARED="-KPIC -dy -Bdynamic";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1623 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1624 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1625 | echo "$ac_t""$CCSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1626 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1627 | # the python executable -- this is only needed for a few systems |
| 1628 | echo $ac_n "checking LINKFORSHARED""... $ac_c" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1629 | if test -z "$LINKFORSHARED" |
| 1630 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1631 | case $ac_sys_system in |
Guido van Rossum | 42dcad3 | 1996-07-31 22:48:44 +0000 | [diff] [blame] | 1632 | AIX*) LINKFORSHARED="-Wl,-bE:python.exp";; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1633 | hp*|HP*) |
| 1634 | LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/sharedmodules";; |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1635 | Linux*) LINKFORSHARED="-rdynamic";; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1636 | next) LINKFORSHARED="-u libsys_s";; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1637 | SCO_SV*) LINKFORSHARED="-Bdynamic -dy -Wl,-Bexport";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1638 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1639 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1640 | echo "$ac_t""$LINKFORSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1641 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1642 | # checks for libraries |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1643 | echo $ac_n "checking for -ldl""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1644 | ac_lib_var=`echo dl'_'dlopen | tr './+\055' '__p_'` |
| 1645 | 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] | 1646 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1647 | else |
| 1648 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1649 | LIBS="-ldl $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1650 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1651 | #line 1652 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1652 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1653 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1654 | /* We use char because int might match the return type of a gcc2 |
| 1655 | builtin and then its argument prototype would still apply. */ |
| 1656 | char dlopen(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1657 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1658 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1659 | int t() { |
| 1660 | dlopen() |
| 1661 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1662 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1663 | if { (eval echo configure:1664: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1664 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1665 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1666 | else |
| 1667 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1668 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1669 | fi |
| 1670 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1671 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1672 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1673 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1674 | 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] | 1675 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1676 | ac_tr_lib=HAVE_LIB`echo dl | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1677 | cat >> confdefs.h <<EOF |
| 1678 | #define $ac_tr_lib 1 |
| 1679 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1680 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1681 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1682 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1683 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1684 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1685 | fi |
| 1686 | # Dynamic linking for SunOS/Solaris and SYSV |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1687 | echo $ac_n "checking for -ldld""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1688 | ac_lib_var=`echo dld'_'shl_load | tr './+\055' '__p_'` |
| 1689 | 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] | 1690 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1691 | else |
| 1692 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1693 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1694 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1695 | #line 1696 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1696 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1697 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1698 | /* We use char because int might match the return type of a gcc2 |
| 1699 | builtin and then its argument prototype would still apply. */ |
| 1700 | char shl_load(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1701 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1702 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1703 | int t() { |
| 1704 | shl_load() |
| 1705 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1706 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1707 | if { (eval echo configure:1708: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1708 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1709 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1710 | else |
| 1711 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1712 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1713 | fi |
| 1714 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1715 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1716 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1717 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1718 | 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] | 1719 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1720 | ac_tr_lib=HAVE_LIB`echo dld | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1721 | cat >> confdefs.h <<EOF |
| 1722 | #define $ac_tr_lib 1 |
| 1723 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1724 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1725 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1726 | |
| 1727 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1728 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1729 | fi |
| 1730 | # Dynamic linking for HP-UX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1731 | echo $ac_n "checking for -lsun""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1732 | ac_lib_var=`echo sun'_'getpwnam | tr './+\055' '__p_'` |
| 1733 | 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] | 1734 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1735 | else |
| 1736 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1737 | LIBS="-lsun $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1738 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1739 | #line 1740 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1740 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1741 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1742 | /* We use char because int might match the return type of a gcc2 |
| 1743 | builtin and then its argument prototype would still apply. */ |
| 1744 | char getpwnam(); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1745 | |
| 1746 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1747 | int t() { |
| 1748 | getpwnam() |
| 1749 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1750 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1751 | if { (eval echo configure:1752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1752 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1753 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1754 | else |
| 1755 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1756 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1757 | fi |
| 1758 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1759 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1760 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1761 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1762 | 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] | 1763 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1764 | ac_tr_lib=HAVE_LIB`echo sun | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1765 | cat >> confdefs.h <<EOF |
| 1766 | #define $ac_tr_lib 1 |
| 1767 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1768 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1769 | LIBS="-lsun $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1770 | |
| 1771 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1772 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1773 | fi |
| 1774 | # NIS (== YP) interface for IRIX 4 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1775 | # The following three (nsl,inet,socket) are needed on Sequent; |
| 1776 | # the order of checking must be this. Most SVR4 platforms will |
| 1777 | # need -lsocket and -lnsl. However on SGI IRIX 5, these exist but |
| 1778 | # broken. I see no elegant solution (probably CHECK_LIB should be |
| 1779 | # fixed to only add the library if the given entry point is not |
| 1780 | # satisfied without it). |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 1781 | if test "$ac_sys_system" != IRIX |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1782 | then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1783 | echo $ac_n "checking for -lnsl""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1784 | ac_lib_var=`echo nsl'_'t_open | tr './+\055' '__p_'` |
| 1785 | 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] | 1786 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1787 | else |
| 1788 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1789 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1790 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1791 | #line 1792 "configure" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1792 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1793 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1794 | /* We use char because int might match the return type of a gcc2 |
| 1795 | builtin and then its argument prototype would still apply. */ |
| 1796 | char t_open(); |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1797 | |
| 1798 | int main() { return 0; } |
| 1799 | int t() { |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 1800 | t_open() |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1801 | ; return 0; } |
| 1802 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1803 | if { (eval echo configure:1804: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1804 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1805 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1806 | else |
| 1807 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1808 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1809 | fi |
| 1810 | rm -f conftest* |
| 1811 | LIBS="$ac_save_LIBS" |
| 1812 | |
| 1813 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1814 | 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] | 1815 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1816 | LIBS="-lnsl $LIBS" |
| 1817 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1818 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1819 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 1820 | # SVR4 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1821 | echo $ac_n "checking for -linet""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1822 | ac_lib_var=`echo inet'_'gethostbyname | tr './+\055' '__p_'` |
| 1823 | 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] | 1824 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1825 | else |
| 1826 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1827 | LIBS="-linet -lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1828 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1829 | #line 1830 "configure" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1830 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1831 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1832 | /* We use char because int might match the return type of a gcc2 |
| 1833 | builtin and then its argument prototype would still apply. */ |
| 1834 | char gethostbyname(); |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1835 | |
| 1836 | int main() { return 0; } |
| 1837 | int t() { |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 1838 | gethostbyname() |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1839 | ; return 0; } |
| 1840 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1841 | if { (eval echo configure:1842: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1842 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1843 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1844 | else |
| 1845 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1846 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1847 | fi |
| 1848 | rm -f conftest* |
| 1849 | LIBS="$ac_save_LIBS" |
| 1850 | |
| 1851 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1852 | 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] | 1853 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1854 | LIBS="-linet $LIBS" |
| 1855 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1856 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1857 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 1858 | # Sequent |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1859 | echo $ac_n "checking for -lsocket""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1860 | ac_lib_var=`echo socket'_'socket | tr './+\055' '__p_'` |
| 1861 | 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] | 1862 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1863 | else |
| 1864 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1865 | LIBS="-lsocket $LIBS $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1866 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1867 | #line 1868 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1868 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1869 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1870 | /* We use char because int might match the return type of a gcc2 |
| 1871 | builtin and then its argument prototype would still apply. */ |
| 1872 | char socket(); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1873 | |
| 1874 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1875 | int t() { |
| 1876 | socket() |
| 1877 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1878 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1879 | if { (eval echo configure:1880: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1880 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1881 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1882 | else |
| 1883 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1884 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1885 | fi |
| 1886 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1887 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1888 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1889 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1890 | 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] | 1891 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1892 | LIBS="-lsocket $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1893 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1894 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1895 | fi |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1896 | # SVR4 sockets |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1897 | fi |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 1898 | echo $ac_n "checking for --with-libs""... $ac_c" 1>&6 |
| 1899 | # Check whether --with-libs or --without-libs was given. |
| 1900 | if test "${with_libs+set}" = set; then |
| 1901 | withval="$with_libs" |
| 1902 | |
| 1903 | echo "$ac_t""$withval" 1>&6 |
| 1904 | LIBS="$withval $LIBS" |
| 1905 | |
| 1906 | else |
| 1907 | echo "$ac_t""no" 1>&6 |
| 1908 | fi |
| 1909 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1910 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1911 | echo $ac_n "checking for --with-readline""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1912 | # Check whether --with-readline or --without-readline was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1913 | if test "${with_readline+set}" = set; then |
| 1914 | withval="$with_readline" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1915 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1916 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1917 | cat >> confdefs.h <<\EOF |
| 1918 | #define WITH_READLINE 1 |
| 1919 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1920 | |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 1921 | if test -d "$withval" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1922 | then LDFLAGS="$LDFLAGS -L$withval" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1923 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1924 | # first check if we can compile without lib termcap |
| 1925 | echo $ac_n "checking for -lreadline without -ltermcap""... $ac_c" 1>&6 |
| 1926 | # check if a libreadline exists |
| 1927 | LIBS="$LIBS -lreadline" |
| 1928 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1929 | #line 1930 "configure" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1930 | #include "confdefs.h" |
| 1931 | extern char *readline(); |
| 1932 | int main() { return 0; } |
| 1933 | int t() { |
| 1934 | char *line=readline(); |
| 1935 | ; return 0; } |
| 1936 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1937 | if { (eval echo configure:1938: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1938 | rm -rf conftest* |
| 1939 | |
| 1940 | echo "$ac_t""yes" 1>&6 |
| 1941 | else |
| 1942 | rm -rf conftest* |
| 1943 | |
| 1944 | echo "$ac_t""no" 1>&6 |
| 1945 | echo "checking for -lreadline that needs -ltermcap" 1>&6 |
| 1946 | termcap= |
| 1947 | echo $ac_n "checking for -ltermcap""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1948 | ac_lib_var=`echo termcap'_'tgetent | tr './+\055' '__p_'` |
| 1949 | 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] | 1950 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1951 | else |
| 1952 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1953 | LIBS="-ltermcap $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1954 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1955 | #line 1956 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1956 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1957 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1958 | /* We use char because int might match the return type of a gcc2 |
| 1959 | builtin and then its argument prototype would still apply. */ |
| 1960 | char tgetent(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1961 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1962 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1963 | int t() { |
| 1964 | tgetent() |
| 1965 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1966 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1967 | if { (eval echo configure:1968: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1968 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1969 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1970 | else |
| 1971 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1972 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1973 | fi |
| 1974 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1975 | LIBS="$ac_save_LIBS" |
| 1976 | |
| 1977 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1978 | 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] | 1979 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1980 | termcap=termcap |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1981 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1982 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1983 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1984 | echo $ac_n "checking for -ltermlib""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1985 | ac_lib_var=`echo termlib'_'tgetent | tr './+\055' '__p_'` |
| 1986 | 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] | 1987 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1988 | else |
| 1989 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1990 | LIBS="-ltermlib $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1991 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 1992 | #line 1993 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1993 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1994 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1995 | /* We use char because int might match the return type of a gcc2 |
| 1996 | builtin and then its argument prototype would still apply. */ |
| 1997 | char tgetent(); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1998 | |
| 1999 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2000 | int t() { |
| 2001 | tgetent() |
| 2002 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2003 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2004 | if { (eval echo configure:2005: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2005 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2006 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2007 | else |
| 2008 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2009 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2010 | fi |
| 2011 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2012 | LIBS="$ac_save_LIBS" |
| 2013 | |
| 2014 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2015 | 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] | 2016 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2017 | termcap=termlib |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2018 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2019 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2020 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2021 | { echo "configure: error: no working -ltermcap/termlib found -- do not use --with-readline" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2022 | fi |
| 2023 | |
| 2024 | fi |
| 2025 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2026 | # Avoid possible conflict between shared libraries termcap and gl |
| 2027 | # on IRIX 5: both contain a routine called clear. |
| 2028 | if test -f /usr/lib/lib$termcap.a |
| 2029 | then LIBS="$LIBS /usr/lib/lib$termcap.a" |
| 2030 | else LIBS="$LIBS -l$termcap" |
| 2031 | fi |
| 2032 | echo $ac_n "checking for -lreadline""... $ac_c" 1>&6 |
| 2033 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2034 | #line 2035 "configure" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2035 | #include "confdefs.h" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2036 | extern char *readline(); |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2037 | int main() { return 0; } |
| 2038 | int t() { |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2039 | char *line=readline(); |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2040 | ; return 0; } |
| 2041 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2042 | if { (eval echo configure:2043: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2043 | rm -rf conftest* |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2044 | |
| 2045 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2046 | else |
| 2047 | rm -rf conftest* |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2048 | |
| 2049 | { echo "configure: error: no working GNU readline library found -- do not use --with-readline" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2050 | fi |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2051 | rm -f conftest* |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2052 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2053 | |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2054 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2055 | rm -f conftest* |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2056 | |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2057 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2058 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2059 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2060 | fi |
| 2061 | |
| 2062 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2063 | echo $ac_n "checking for --with-thread""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2064 | # Check whether --with-thread or --without-thread was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2065 | if test "${with_thread+set}" = set; then |
| 2066 | withval="$with_thread" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2067 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2068 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2069 | if test -d "$withval" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2070 | then LDFLAGS="$LDFLAGS -L$withval" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2071 | fi |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 2072 | cat >> confdefs.h <<\EOF |
| 2073 | #define _REENTRANT 1 |
| 2074 | EOF |
| 2075 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2076 | ac_safe=`echo "mach/cthreads.h" | tr './\055' '___'` |
| 2077 | echo $ac_n "checking for mach/cthreads.h""... $ac_c" 1>&6 |
| 2078 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 2079 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2080 | else |
| 2081 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2082 | #line 2083 "configure" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2083 | #include "confdefs.h" |
| 2084 | #include <mach/cthreads.h> |
| 2085 | EOF |
| 2086 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2087 | { (eval echo configure:2088: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2088 | ac_err=`grep -v '^ *+' conftest.out` |
| 2089 | if test -z "$ac_err"; then |
| 2090 | rm -rf conftest* |
| 2091 | eval "ac_cv_header_$ac_safe=yes" |
| 2092 | else |
| 2093 | echo "$ac_err" >&5 |
| 2094 | rm -rf conftest* |
| 2095 | eval "ac_cv_header_$ac_safe=no" |
| 2096 | fi |
| 2097 | rm -f conftest* |
| 2098 | fi |
| 2099 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 2100 | echo "$ac_t""yes" 1>&6 |
| 2101 | cat >> confdefs.h <<\EOF |
| 2102 | #define WITH_THREAD 1 |
| 2103 | EOF |
| 2104 | |
| 2105 | cat >> confdefs.h <<\EOF |
| 2106 | #define C_THREADS 1 |
| 2107 | EOF |
| 2108 | |
| 2109 | LIBOBJS="$LIBOBJS thread.o" |
| 2110 | else |
| 2111 | echo "$ac_t""no" 1>&6 |
| 2112 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2113 | echo $ac_n "checking for -lpthreads""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2114 | ac_lib_var=`echo pthreads'_'pthread_create | tr './+\055' '__p_'` |
| 2115 | 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] | 2116 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2117 | else |
| 2118 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2119 | LIBS="-lpthreads $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2120 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2121 | #line 2122 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2122 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2123 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2124 | /* We use char because int might match the return type of a gcc2 |
| 2125 | builtin and then its argument prototype would still apply. */ |
| 2126 | char pthread_create(); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2127 | |
| 2128 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2129 | int t() { |
| 2130 | pthread_create() |
| 2131 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2132 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2133 | if { (eval echo configure:2134: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2134 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2135 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2136 | else |
| 2137 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2138 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2139 | fi |
| 2140 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2141 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2142 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2143 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2144 | 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] | 2145 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2146 | cat >> confdefs.h <<\EOF |
| 2147 | #define WITH_THREAD 1 |
| 2148 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2149 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2150 | cat >> confdefs.h <<\EOF |
| 2151 | #define _POSIX_THREADS 1 |
| 2152 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2153 | |
| 2154 | LIBS="$LIBS -lpthreads" |
| 2155 | LIBOBJS="$LIBOBJS thread.o" |
| 2156 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2157 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2158 | |
| 2159 | echo $ac_n "checking for -lpthread""... $ac_c" 1>&6 |
| 2160 | ac_lib_var=`echo pthread'_'pthread_create | tr './+\055' '__p_'` |
| 2161 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 2162 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2163 | else |
| 2164 | ac_save_LIBS="$LIBS" |
| 2165 | LIBS="-lpthread $LIBS" |
| 2166 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2167 | #line 2168 "configure" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2168 | #include "confdefs.h" |
| 2169 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2170 | /* We use char because int might match the return type of a gcc2 |
| 2171 | builtin and then its argument prototype would still apply. */ |
| 2172 | char pthread_create(); |
| 2173 | |
| 2174 | int main() { return 0; } |
| 2175 | int t() { |
| 2176 | pthread_create() |
| 2177 | ; return 0; } |
| 2178 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2179 | if { (eval echo configure:2180: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2180 | rm -rf conftest* |
| 2181 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2182 | else |
| 2183 | rm -rf conftest* |
| 2184 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2185 | fi |
| 2186 | rm -f conftest* |
| 2187 | LIBS="$ac_save_LIBS" |
| 2188 | |
| 2189 | fi |
| 2190 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2191 | echo "$ac_t""yes" 1>&6 |
| 2192 | cat >> confdefs.h <<\EOF |
| 2193 | #define WITH_THREAD 1 |
| 2194 | EOF |
| 2195 | |
| 2196 | cat >> confdefs.h <<\EOF |
| 2197 | #define _POSIX_THREADS 1 |
| 2198 | EOF |
| 2199 | |
| 2200 | LIBS="$LIBS -lpthread" |
| 2201 | LIBOBJS="$LIBOBJS thread.o" |
| 2202 | else |
| 2203 | echo "$ac_t""no" 1>&6 |
| 2204 | fi |
| 2205 | |
| 2206 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2207 | fi |
| 2208 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2209 | fi |
| 2210 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2211 | echo $ac_n "checking for -lmpc""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2212 | ac_lib_var=`echo mpc'_'usconfig | tr './+\055' '__p_'` |
| 2213 | 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] | 2214 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2215 | else |
| 2216 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2217 | LIBS="-lmpc $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2218 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2219 | #line 2220 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2220 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2221 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2222 | /* We use char because int might match the return type of a gcc2 |
| 2223 | builtin and then its argument prototype would still apply. */ |
| 2224 | char usconfig(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2225 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2226 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2227 | int t() { |
| 2228 | usconfig() |
| 2229 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2230 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2231 | if { (eval echo configure:2232: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2232 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2233 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2234 | else |
| 2235 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2236 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2237 | fi |
| 2238 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2239 | LIBS="$ac_save_LIBS" |
| 2240 | |
| 2241 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2242 | 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] | 2243 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2244 | cat >> confdefs.h <<\EOF |
| 2245 | #define WITH_THREAD 1 |
| 2246 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2247 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2248 | LIBS="$LIBS -lmpc" |
| 2249 | LIBOBJS="$LIBOBJS thread.o" |
| 2250 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2251 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2252 | fi |
| 2253 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2254 | echo $ac_n "checking for -lthread""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2255 | ac_lib_var=`echo thread'_'thr_create | tr './+\055' '__p_'` |
| 2256 | 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] | 2257 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2258 | else |
| 2259 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2260 | LIBS="-lthread $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2261 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2262 | #line 2263 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2263 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2264 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2265 | /* We use char because int might match the return type of a gcc2 |
| 2266 | builtin and then its argument prototype would still apply. */ |
| 2267 | char thr_create(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2268 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2269 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2270 | int t() { |
| 2271 | thr_create() |
| 2272 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2273 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2274 | if { (eval echo configure:2275: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2275 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2276 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2277 | else |
| 2278 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2279 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2280 | fi |
| 2281 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2282 | LIBS="$ac_save_LIBS" |
| 2283 | |
| 2284 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2285 | 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] | 2286 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2287 | cat >> confdefs.h <<\EOF |
| 2288 | #define WITH_THREAD 1 |
| 2289 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2290 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2291 | LIBS="$LIBS -lthread" |
| 2292 | LIBOBJS="$LIBOBJS thread.o" |
| 2293 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2294 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2295 | fi |
| 2296 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2297 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2298 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2299 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2300 | fi |
| 2301 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2302 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2303 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2304 | |
| 2305 | DLINCLDIR=/ |
| 2306 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2307 | echo $ac_n "checking for --with-sgi-dl""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2308 | # Check whether --with-sgi-dl or --without-sgi-dl was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2309 | if test "${with_sgi_dl+set}" = set; then |
| 2310 | withval="$with_sgi_dl" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2311 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2312 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2313 | cat >> confdefs.h <<\EOF |
| 2314 | #define WITH_SGI_DL 1 |
| 2315 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2316 | |
| 2317 | dldir=$withval |
| 2318 | if test -d "$dldir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2319 | then LDFLAGS="$LDFLAGS -L$dldir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2320 | 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] | 2321 | fi |
| 2322 | DLINCLDIR=${dldir} |
| 2323 | LIBS="$LIBS -ldl -lmld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2324 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2325 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2326 | fi |
| 2327 | |
| 2328 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2329 | echo $ac_n "checking for --with-dl-dld""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2330 | # Check whether --with-dl-dld or --without-dl-dld was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2331 | if test "${with_dl_dld+set}" = set; then |
| 2332 | withval="$with_dl_dld" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2333 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2334 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2335 | cat >> confdefs.h <<\EOF |
| 2336 | #define WITH_DL_DLD 1 |
| 2337 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2338 | |
| 2339 | dldir=`echo "$withval" | sed 's/,.*//'` |
| 2340 | dlddir=`echo "$withval" | sed 's/.*,//'` |
| 2341 | if test -d "$dldir" -a -d "$dlddir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2342 | then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2343 | 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] | 2344 | fi |
| 2345 | DLINCLDIR=${dldir} |
| 2346 | LIBS="$LIBS -ldl -ldld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2347 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2348 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2349 | fi |
| 2350 | |
| 2351 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2352 | # checks for library functions |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 2353 | for ac_func in chown clock dlopen flock ftime ftruncate \ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2354 | gethostname_r getpeername getpgrp getpid gettimeofday getwd \ |
Guido van Rossum | 57d0915 | 1996-07-24 02:42:38 +0000 | [diff] [blame] | 2355 | link lstat mkfifo nice plock putenv readlink \ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2356 | select setgid setuid setsid setpgid setpgrp setvbuf \ |
| 2357 | sigaction siginterrupt sigrelse strftime symlink \ |
| 2358 | tcgetpgrp tcsetpgrp times truncate uname waitpid |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2359 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2360 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 2361 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 2362 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2363 | else |
| 2364 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2365 | #line 2366 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2366 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2367 | /* System header to define __stub macros and hopefully few prototypes, |
| 2368 | which can conflict with char $ac_func(); below. */ |
| 2369 | #include <assert.h> |
| 2370 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2371 | /* We use char because int might match the return type of a gcc2 |
| 2372 | builtin and then its argument prototype would still apply. */ |
| 2373 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2374 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2375 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2376 | int t() { |
| 2377 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2378 | /* The GNU C library defines this for functions which it implements |
| 2379 | to always fail with ENOSYS. Some functions are actually named |
| 2380 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2381 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2382 | choke me |
| 2383 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2384 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2385 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2386 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2387 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2388 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2389 | if { (eval echo configure:2390: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2390 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2391 | eval "ac_cv_func_$ac_func=yes" |
| 2392 | else |
| 2393 | rm -rf conftest* |
| 2394 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2395 | fi |
| 2396 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2397 | |
| 2398 | fi |
| 2399 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2400 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2401 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2402 | cat >> confdefs.h <<EOF |
| 2403 | #define $ac_tr_func 1 |
| 2404 | EOF |
| 2405 | |
| 2406 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2407 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2408 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2409 | done |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2410 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 2411 | for ac_func in dup2 getcwd strdup strerror memmove |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2412 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2413 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 2414 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 2415 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2416 | else |
| 2417 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2418 | #line 2419 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2419 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2420 | /* System header to define __stub macros and hopefully few prototypes, |
| 2421 | which can conflict with char $ac_func(); below. */ |
| 2422 | #include <assert.h> |
| 2423 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2424 | /* We use char because int might match the return type of a gcc2 |
| 2425 | builtin and then its argument prototype would still apply. */ |
| 2426 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2427 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2428 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2429 | int t() { |
| 2430 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2431 | /* The GNU C library defines this for functions which it implements |
| 2432 | to always fail with ENOSYS. Some functions are actually named |
| 2433 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2434 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2435 | choke me |
| 2436 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2437 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2438 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2439 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2440 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2441 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2442 | if { (eval echo configure:2443: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2443 | rm -rf conftest* |
| 2444 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2445 | else |
| 2446 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2447 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2448 | fi |
| 2449 | rm -f conftest* |
| 2450 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2451 | fi |
| 2452 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2453 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2454 | : |
| 2455 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2456 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2457 | LIBOBJS="$LIBOBJS ${ac_func}.o" |
| 2458 | fi |
| 2459 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2460 | done |
| 2461 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2462 | echo $ac_n "checking for getpgrp""... $ac_c" 1>&6 |
| 2463 | if eval "test \"`echo '$''{'ac_cv_func_getpgrp'+set}'`\" = set"; then |
| 2464 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2465 | else |
| 2466 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2467 | #line 2468 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2468 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2469 | /* System header to define __stub macros and hopefully few prototypes, |
| 2470 | which can conflict with char getpgrp(); below. */ |
| 2471 | #include <assert.h> |
| 2472 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2473 | /* We use char because int might match the return type of a gcc2 |
| 2474 | builtin and then its argument prototype would still apply. */ |
| 2475 | char getpgrp(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2476 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2477 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2478 | int t() { |
| 2479 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2480 | /* The GNU C library defines this for functions which it implements |
| 2481 | to always fail with ENOSYS. Some functions are actually named |
| 2482 | something starting with __ and the normal name is an alias. */ |
| 2483 | #if defined (__stub_getpgrp) || defined (__stub___getpgrp) |
| 2484 | choke me |
| 2485 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2486 | getpgrp(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2487 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2488 | |
| 2489 | ; return 0; } |
| 2490 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2491 | if { (eval echo configure:2492: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2492 | rm -rf conftest* |
| 2493 | eval "ac_cv_func_getpgrp=yes" |
| 2494 | else |
| 2495 | rm -rf conftest* |
| 2496 | eval "ac_cv_func_getpgrp=no" |
| 2497 | fi |
| 2498 | rm -f conftest* |
| 2499 | |
| 2500 | fi |
| 2501 | if eval "test \"`echo '$ac_cv_func_'getpgrp`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2502 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2503 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2504 | #line 2505 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2505 | #include "confdefs.h" |
| 2506 | #include <unistd.h> |
| 2507 | int main() { return 0; } |
| 2508 | int t() { |
| 2509 | getpgrp(0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2510 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2511 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2512 | if { (eval echo configure:2513: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2513 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2514 | cat >> confdefs.h <<\EOF |
| 2515 | #define GETPGRP_HAVE_ARG 1 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2516 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2517 | |
| 2518 | fi |
| 2519 | rm -f conftest* |
| 2520 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2521 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2522 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2523 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2524 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2525 | echo $ac_n "checking for setpgrp""... $ac_c" 1>&6 |
| 2526 | if eval "test \"`echo '$''{'ac_cv_func_setpgrp'+set}'`\" = set"; then |
| 2527 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2528 | else |
| 2529 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2530 | #line 2531 "configure" |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2531 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2532 | /* System header to define __stub macros and hopefully few prototypes, |
| 2533 | which can conflict with char setpgrp(); below. */ |
| 2534 | #include <assert.h> |
| 2535 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2536 | /* We use char because int might match the return type of a gcc2 |
| 2537 | builtin and then its argument prototype would still apply. */ |
| 2538 | char setpgrp(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2539 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2540 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2541 | int t() { |
| 2542 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2543 | /* The GNU C library defines this for functions which it implements |
| 2544 | to always fail with ENOSYS. Some functions are actually named |
| 2545 | something starting with __ and the normal name is an alias. */ |
| 2546 | #if defined (__stub_setpgrp) || defined (__stub___setpgrp) |
| 2547 | choke me |
| 2548 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2549 | setpgrp(); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2550 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2551 | |
| 2552 | ; return 0; } |
| 2553 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2554 | if { (eval echo configure:2555: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2555 | rm -rf conftest* |
| 2556 | eval "ac_cv_func_setpgrp=yes" |
| 2557 | else |
| 2558 | rm -rf conftest* |
| 2559 | eval "ac_cv_func_setpgrp=no" |
| 2560 | fi |
| 2561 | rm -f conftest* |
| 2562 | |
| 2563 | fi |
| 2564 | if eval "test \"`echo '$ac_cv_func_'setpgrp`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2565 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2566 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2567 | #line 2568 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2568 | #include "confdefs.h" |
| 2569 | #include <unistd.h> |
| 2570 | int main() { return 0; } |
| 2571 | int t() { |
| 2572 | setpgrp(0,0); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2573 | ; return 0; } |
| 2574 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2575 | if { (eval echo configure:2576: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2576 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2577 | cat >> confdefs.h <<\EOF |
| 2578 | #define SETPGRP_HAVE_ARG 1 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2579 | EOF |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2580 | |
| 2581 | fi |
| 2582 | rm -f conftest* |
| 2583 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2584 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2585 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2586 | fi |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2587 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2588 | echo $ac_n "checking for gettimeofday""... $ac_c" 1>&6 |
| 2589 | if eval "test \"`echo '$''{'ac_cv_func_gettimeofday'+set}'`\" = set"; then |
| 2590 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2591 | else |
| 2592 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2593 | #line 2594 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2594 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2595 | /* System header to define __stub macros and hopefully few prototypes, |
| 2596 | which can conflict with char gettimeofday(); below. */ |
| 2597 | #include <assert.h> |
| 2598 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2599 | /* We use char because int might match the return type of a gcc2 |
| 2600 | builtin and then its argument prototype would still apply. */ |
| 2601 | char gettimeofday(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2602 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2603 | int main() { return 0; } |
| 2604 | int t() { |
| 2605 | |
| 2606 | /* The GNU C library defines this for functions which it implements |
| 2607 | to always fail with ENOSYS. Some functions are actually named |
| 2608 | something starting with __ and the normal name is an alias. */ |
| 2609 | #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday) |
| 2610 | choke me |
| 2611 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2612 | gettimeofday(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2613 | #endif |
| 2614 | |
| 2615 | ; return 0; } |
| 2616 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2617 | if { (eval echo configure:2618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2618 | rm -rf conftest* |
| 2619 | eval "ac_cv_func_gettimeofday=yes" |
| 2620 | else |
| 2621 | rm -rf conftest* |
| 2622 | eval "ac_cv_func_gettimeofday=no" |
| 2623 | fi |
| 2624 | rm -f conftest* |
| 2625 | |
| 2626 | fi |
| 2627 | if eval "test \"`echo '$ac_cv_func_'gettimeofday`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2628 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2629 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2630 | #line 2631 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2631 | #include "confdefs.h" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2632 | #include <sys/time.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2633 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2634 | int t() { |
| 2635 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
| 2636 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2637 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2638 | if { (eval echo configure:2639: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2639 | : |
| 2640 | else |
| 2641 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2642 | cat >> confdefs.h <<\EOF |
| 2643 | #define GETTIMEOFDAY_NO_TZ 1 |
| 2644 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2645 | |
| 2646 | fi |
| 2647 | rm -f conftest* |
| 2648 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2649 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2650 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2651 | fi |
| 2652 | |
| 2653 | |
| 2654 | # checks for structures |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2655 | echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 |
| 2656 | if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then |
| 2657 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2658 | else |
| 2659 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2660 | #line 2661 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2661 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2662 | #include <sys/types.h> |
| 2663 | #include <sys/time.h> |
| 2664 | #include <time.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2665 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2666 | int t() { |
| 2667 | struct tm *tp; |
| 2668 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2669 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2670 | if { (eval echo configure:2671: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2671 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2672 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2673 | else |
| 2674 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2675 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2676 | fi |
| 2677 | rm -f conftest* |
| 2678 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2679 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2680 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2681 | echo "$ac_t""$ac_cv_header_time" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2682 | if test $ac_cv_header_time = yes; then |
| 2683 | cat >> confdefs.h <<\EOF |
| 2684 | #define TIME_WITH_SYS_TIME 1 |
| 2685 | EOF |
| 2686 | |
| 2687 | fi |
| 2688 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2689 | echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 |
| 2690 | if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then |
| 2691 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2692 | else |
| 2693 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2694 | #line 2695 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2695 | #include "confdefs.h" |
| 2696 | #include <sys/types.h> |
| 2697 | #include <time.h> |
| 2698 | int main() { return 0; } |
| 2699 | int t() { |
| 2700 | struct tm *tp; tp->tm_sec; |
| 2701 | ; return 0; } |
| 2702 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2703 | if { (eval echo configure:2704: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2704 | rm -rf conftest* |
| 2705 | ac_cv_struct_tm=time.h |
| 2706 | else |
| 2707 | rm -rf conftest* |
| 2708 | ac_cv_struct_tm=sys/time.h |
| 2709 | fi |
| 2710 | rm -f conftest* |
| 2711 | |
| 2712 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2713 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2714 | echo "$ac_t""$ac_cv_struct_tm" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2715 | if test $ac_cv_struct_tm = sys/time.h; then |
| 2716 | cat >> confdefs.h <<\EOF |
| 2717 | #define TM_IN_SYS_TIME 1 |
| 2718 | EOF |
| 2719 | |
| 2720 | fi |
| 2721 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2722 | echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 |
| 2723 | if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then |
| 2724 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2725 | else |
| 2726 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2727 | #line 2728 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2728 | #include "confdefs.h" |
| 2729 | #include <sys/types.h> |
| 2730 | #include <$ac_cv_struct_tm> |
| 2731 | int main() { return 0; } |
| 2732 | int t() { |
| 2733 | struct tm tm; tm.tm_zone; |
| 2734 | ; return 0; } |
| 2735 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2736 | if { (eval echo configure:2737: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2737 | rm -rf conftest* |
| 2738 | ac_cv_struct_tm_zone=yes |
| 2739 | else |
| 2740 | rm -rf conftest* |
| 2741 | ac_cv_struct_tm_zone=no |
| 2742 | fi |
| 2743 | rm -f conftest* |
| 2744 | |
| 2745 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2746 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2747 | echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2748 | if test "$ac_cv_struct_tm_zone" = yes; then |
| 2749 | cat >> confdefs.h <<\EOF |
| 2750 | #define HAVE_TM_ZONE 1 |
| 2751 | EOF |
| 2752 | |
| 2753 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2754 | echo $ac_n "checking for tzname""... $ac_c" 1>&6 |
| 2755 | if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then |
| 2756 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2757 | else |
| 2758 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2759 | #line 2760 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2760 | #include "confdefs.h" |
| 2761 | #include <time.h> |
| 2762 | #ifndef tzname /* For SGI. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2763 | extern char *tzname[]; /* RS6000 and others reject char **tzname. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2764 | #endif |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2765 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2766 | int t() { |
| 2767 | atoi(*tzname); |
| 2768 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2769 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2770 | if { (eval echo configure:2771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2771 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2772 | ac_cv_var_tzname=yes |
| 2773 | else |
| 2774 | rm -rf conftest* |
| 2775 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2776 | fi |
| 2777 | rm -f conftest* |
| 2778 | |
| 2779 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2780 | |
| 2781 | echo "$ac_t""$ac_cv_var_tzname" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2782 | if test $ac_cv_var_tzname = yes; then |
| 2783 | cat >> confdefs.h <<\EOF |
| 2784 | #define HAVE_TZNAME 1 |
| 2785 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2786 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2787 | fi |
| 2788 | fi |
| 2789 | |
| 2790 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2791 | echo $ac_n "checking for time.h that defines altzone""... $ac_c" 1>&6 |
| 2792 | if eval "test \"`echo '$''{'ac_cv_header_time_altzone'+set}'`\" = set"; then |
| 2793 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2794 | else |
| 2795 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2796 | #line 2797 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2797 | #include "confdefs.h" |
| 2798 | #include <time.h> |
| 2799 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2800 | int t() { |
| 2801 | return altzone; |
| 2802 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2803 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2804 | if { (eval echo configure:2805: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2805 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2806 | ac_cv_header_time_altzone=yes |
| 2807 | else |
| 2808 | rm -rf conftest* |
| 2809 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2810 | fi |
| 2811 | rm -f conftest* |
| 2812 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2813 | fi |
| 2814 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2815 | echo "$ac_t""$ac_cv_header_time_altzone" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2816 | if test $ac_cv_header_time_altzone = yes; then |
| 2817 | cat >> confdefs.h <<\EOF |
| 2818 | #define HAVE_ALTZONE 1 |
| 2819 | EOF |
| 2820 | |
| 2821 | fi |
| 2822 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2823 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2824 | echo $ac_n "checking whether sys/select.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2825 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2826 | #line 2827 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2827 | #include "confdefs.h" |
| 2828 | |
| 2829 | #include <sys/types.h> |
| 2830 | #include <sys/select.h> |
| 2831 | #include <sys/time.h> |
| 2832 | |
| 2833 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2834 | int t() { |
| 2835 | ; |
| 2836 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2837 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2838 | if { (eval echo configure:2839: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2839 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2840 | cat >> confdefs.h <<\EOF |
| 2841 | #define SYS_SELECT_WITH_SYS_TIME 1 |
| 2842 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2843 | was_it_defined=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2844 | fi |
| 2845 | rm -f conftest* |
| 2846 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2847 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2848 | |
| 2849 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2850 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2851 | echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6 |
| 2852 | if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then |
| 2853 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2854 | else |
| 2855 | if test "$GCC" = yes; then |
| 2856 | # GCC predefines this symbol on systems where it applies. |
| 2857 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2858 | #line 2859 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2859 | #include "confdefs.h" |
| 2860 | #ifdef __CHAR_UNSIGNED__ |
| 2861 | yes |
| 2862 | #endif |
| 2863 | |
| 2864 | EOF |
| 2865 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 2866 | egrep "yes" >/dev/null 2>&1; then |
| 2867 | rm -rf conftest* |
| 2868 | ac_cv_c_char_unsigned=yes |
| 2869 | else |
| 2870 | rm -rf conftest* |
| 2871 | ac_cv_c_char_unsigned=no |
| 2872 | fi |
| 2873 | rm -f conftest* |
| 2874 | |
| 2875 | else |
| 2876 | if test "$cross_compiling" = yes; then |
| 2877 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2878 | else |
| 2879 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2880 | #line 2881 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2881 | #include "confdefs.h" |
| 2882 | /* volatile prevents gcc2 from optimizing the test away on sparcs. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2883 | #if !defined(__STDC__) || __STDC__ != 1 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2884 | #define volatile |
| 2885 | #endif |
| 2886 | main() { |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2887 | volatile char c = 255; exit(c < 0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2888 | } |
| 2889 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2890 | { (eval echo configure:2891: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2891 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2892 | ac_cv_c_char_unsigned=yes |
| 2893 | else |
| 2894 | ac_cv_c_char_unsigned=no |
| 2895 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2896 | fi |
| 2897 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2898 | fi |
| 2899 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2900 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2901 | echo "$ac_t""$ac_cv_c_char_unsigned" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2902 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
| 2903 | cat >> confdefs.h <<\EOF |
| 2904 | #define __CHAR_UNSIGNED__ 1 |
| 2905 | EOF |
| 2906 | |
| 2907 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2908 | |
| 2909 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2910 | echo $ac_n "checking for working const""... $ac_c" 1>&6 |
| 2911 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
| 2912 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2913 | else |
| 2914 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2915 | #line 2916 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2916 | #include "confdefs.h" |
| 2917 | |
| 2918 | int main() { return 0; } |
| 2919 | int t() { |
| 2920 | |
| 2921 | /* Ultrix mips cc rejects this. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2922 | typedef int charset[2]; const charset x; |
| 2923 | /* SunOS 4.1.1 cc rejects this. */ |
| 2924 | char const *const *ccp; |
| 2925 | char **p; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2926 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 2927 | struct point {int x, y;}; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2928 | static struct point const zero = {0,0}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2929 | /* AIX XL C 1.02.0.0 rejects this. |
| 2930 | It does not let you subtract one const X* pointer from another in an arm |
| 2931 | of an if-expression whose if-part is not a constant expression */ |
| 2932 | const char *g = "string"; |
| 2933 | ccp = &g + (g ? g-g : 0); |
| 2934 | /* HPUX 7.0 cc rejects these. */ |
| 2935 | ++ccp; |
| 2936 | p = (char**) ccp; |
| 2937 | ccp = (char const *const *) p; |
| 2938 | { /* SCO 3.2v4 cc rejects this. */ |
| 2939 | char *t; |
| 2940 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
| 2941 | |
| 2942 | *t++ = 0; |
| 2943 | } |
| 2944 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2945 | int x[] = {25, 17}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2946 | const int *foo = &x[0]; |
| 2947 | ++foo; |
| 2948 | } |
| 2949 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 2950 | typedef const int *iptr; |
| 2951 | iptr p = 0; |
| 2952 | ++p; |
| 2953 | } |
| 2954 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 2955 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 2956 | struct s { int j; const int *ap[3]; }; |
| 2957 | struct s *b; b->j = 5; |
| 2958 | } |
| 2959 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 2960 | const int foo = 10; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2961 | } |
| 2962 | |
| 2963 | ; return 0; } |
| 2964 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2965 | if { (eval echo configure:2966: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2966 | rm -rf conftest* |
| 2967 | ac_cv_c_const=yes |
| 2968 | else |
| 2969 | rm -rf conftest* |
| 2970 | ac_cv_c_const=no |
| 2971 | fi |
| 2972 | rm -f conftest* |
| 2973 | |
| 2974 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2975 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2976 | echo "$ac_t""$ac_cv_c_const" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2977 | if test $ac_cv_c_const = no; then |
| 2978 | cat >> confdefs.h <<\EOF |
| 2979 | #define const |
| 2980 | EOF |
| 2981 | |
| 2982 | fi |
| 2983 | |
| 2984 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2985 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2986 | echo $ac_n "checking for working volatile""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2987 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2988 | #line 2989 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2989 | #include "confdefs.h" |
| 2990 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2991 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2992 | int t() { |
| 2993 | volatile int x; x = 0; |
| 2994 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2995 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 2996 | if { (eval echo configure:2997: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2997 | rm -rf conftest* |
| 2998 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2999 | else |
| 3000 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3001 | cat >> confdefs.h <<\EOF |
| 3002 | #define volatile |
| 3003 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3004 | |
| 3005 | fi |
| 3006 | rm -f conftest* |
| 3007 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3008 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3009 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3010 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3011 | echo $ac_n "checking for working signed char""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3012 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3013 | #line 3014 "configure" |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 3014 | #include "confdefs.h" |
| 3015 | |
| 3016 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3017 | int t() { |
| 3018 | signed char c; |
| 3019 | ; return 0; } |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 3020 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3021 | if { (eval echo configure:3022: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3022 | rm -rf conftest* |
| 3023 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 3024 | else |
| 3025 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3026 | cat >> confdefs.h <<\EOF |
| 3027 | #define signed |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3028 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3029 | |
| 3030 | fi |
| 3031 | rm -f conftest* |
| 3032 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3033 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3034 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3035 | have_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3036 | echo $ac_n "checking for prototypes""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3037 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3038 | #line 3039 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3039 | #include "confdefs.h" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3040 | int foo(int x) { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3041 | int main() { return 0; } |
| 3042 | int t() { |
| 3043 | return foo(10); |
| 3044 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3045 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3046 | if { (eval echo configure:3047: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3047 | rm -rf conftest* |
| 3048 | cat >> confdefs.h <<\EOF |
| 3049 | #define HAVE_PROTOTYPES 1 |
| 3050 | EOF |
| 3051 | have_prototypes=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3052 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3053 | rm -f conftest* |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3054 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3055 | echo "$ac_t""$have_prototypes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3056 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3057 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3058 | echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3059 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3060 | #line 3061 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3061 | #include "confdefs.h" |
| 3062 | |
| 3063 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 3064 | int foo(int x, ...) { |
| 3065 | va_list va; |
| 3066 | va_start(va, x); |
| 3067 | va_arg(va, int); |
| 3068 | va_arg(va, char *); |
| 3069 | va_arg(va, double); |
| 3070 | return 0; |
| 3071 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3072 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3073 | int main() { return 0; } |
| 3074 | int t() { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 3075 | return foo(10, "", 3.14); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3076 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3077 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3078 | if { (eval echo configure:3079: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3079 | rm -rf conftest* |
| 3080 | cat >> confdefs.h <<\EOF |
| 3081 | #define HAVE_STDARG_PROTOTYPES 1 |
| 3082 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3083 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3084 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3085 | rm -f conftest* |
| 3086 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3087 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3088 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3089 | if test "$have_prototypes" = yes; then |
| 3090 | bad_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3091 | echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3092 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3093 | #line 3094 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3094 | #include "confdefs.h" |
| 3095 | #include <unistd.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3096 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3097 | int t() { |
| 3098 | char **t;execve("@",t,t); |
| 3099 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3100 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3101 | if { (eval echo configure:3102: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3102 | : |
| 3103 | else |
| 3104 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3105 | cat >> confdefs.h <<\EOF |
| 3106 | #define BAD_EXEC_PROTOTYPES 1 |
| 3107 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3108 | bad_prototypes=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3109 | fi |
| 3110 | rm -f conftest* |
| 3111 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3112 | echo "$ac_t""$bad_prototypes" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3113 | fi |
| 3114 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3115 | bad_forward=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3116 | echo $ac_n "checking for bad static forward""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3117 | if test "$cross_compiling" = yes; then |
| 3118 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 3119 | else |
| 3120 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3121 | #line 3122 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3122 | #include "confdefs.h" |
| 3123 | |
| 3124 | struct s { int a; int b; }; |
| 3125 | static struct s foo; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3126 | int foobar() { |
| 3127 | static int random; |
| 3128 | random = (int) &foo; |
| 3129 | return random; |
| 3130 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3131 | static struct s foo = { 1, 2 }; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3132 | main() { |
| 3133 | exit(!((int)&foo == foobar())); |
| 3134 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3135 | |
| 3136 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3137 | { (eval echo configure:3138: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3138 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
| 3139 | : |
| 3140 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3141 | cat >> confdefs.h <<\EOF |
| 3142 | #define BAD_STATIC_FORWARD 1 |
| 3143 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3144 | bad_forward=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3145 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3146 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3147 | rm -fr conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3148 | echo "$ac_t""$bad_forward" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3149 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3150 | va_list_is_array=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3151 | echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3152 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3153 | #line 3154 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3154 | #include "confdefs.h" |
| 3155 | |
| 3156 | #ifdef HAVE_STDARG_PROTOTYPES |
| 3157 | #include <stdarg.h> |
| 3158 | #else |
| 3159 | #include <varargs.h> |
| 3160 | #endif |
| 3161 | |
| 3162 | int main() { return 0; } |
| 3163 | int t() { |
| 3164 | va_list list1, list2; list1 = list2; |
| 3165 | ; return 0; } |
| 3166 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3167 | if { (eval echo configure:3168: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3168 | : |
| 3169 | else |
| 3170 | rm -rf conftest* |
| 3171 | cat >> confdefs.h <<\EOF |
| 3172 | #define VA_LIST_IS_ARRAY 1 |
| 3173 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3174 | va_list_is_array=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3175 | fi |
| 3176 | rm -f conftest* |
| 3177 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3178 | echo "$ac_t""$va_list_is_array" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3179 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3180 | # checks for system services |
| 3181 | # (none yet) |
| 3182 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3183 | # Linux requires this for correct f.p. operations |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3184 | echo $ac_n "checking for -lieee""... $ac_c" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3185 | ac_lib_var=`echo ieee'_'__fpu_control | tr './+\055' '__p_'` |
| 3186 | 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] | 3187 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3188 | else |
| 3189 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3190 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3191 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3192 | #line 3193 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3193 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3194 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3195 | /* We use char because int might match the return type of a gcc2 |
| 3196 | builtin and then its argument prototype would still apply. */ |
| 3197 | char __fpu_control(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3198 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3199 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3200 | int t() { |
| 3201 | __fpu_control() |
| 3202 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3203 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3204 | if { (eval echo configure:3205: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3205 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3206 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3207 | else |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3208 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3209 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3210 | fi |
| 3211 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3212 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3213 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3214 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3215 | 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] | 3216 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3217 | ac_tr_lib=HAVE_LIB`echo ieee | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3218 | cat >> confdefs.h <<EOF |
| 3219 | #define $ac_tr_lib 1 |
| 3220 | EOF |
| 3221 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3222 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3223 | |
| 3224 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3225 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3226 | fi |
| 3227 | |
| 3228 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3229 | # check for --with-libm=... |
| 3230 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3231 | case $ac_sys_system in |
| 3232 | next) ;; |
| 3233 | *) LIBM=-lm |
| 3234 | esac |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3235 | # Check whether --with-libm or --without-libm was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3236 | if test "${with_libm+set}" = set; then |
| 3237 | withval="$with_libm" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3238 | |
| 3239 | if test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3240 | then LIBM=$withval |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3241 | 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] | 3242 | fi |
| 3243 | fi |
| 3244 | |
| 3245 | |
| 3246 | # check for --with-libc=... |
| 3247 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3248 | # Check whether --with-libc or --without-libc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3249 | if test "${with_libc+set}" = set; then |
| 3250 | withval="$with_libc" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3251 | |
| 3252 | if test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3253 | then LIBC=$withval |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3254 | 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] | 3255 | fi |
| 3256 | fi |
| 3257 | |
| 3258 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 3259 | # check for hypot() in math library |
| 3260 | LIBS_SAVE=$LIBS |
| 3261 | LIBS="$LIBS $LIBM" |
| 3262 | for ac_func in hypot |
| 3263 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3264 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 3265 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 3266 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 3267 | else |
| 3268 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3269 | #line 3270 "configure" |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 3270 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3271 | /* System header to define __stub macros and hopefully few prototypes, |
| 3272 | which can conflict with char $ac_func(); below. */ |
| 3273 | #include <assert.h> |
| 3274 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3275 | /* We use char because int might match the return type of a gcc2 |
| 3276 | builtin and then its argument prototype would still apply. */ |
| 3277 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3278 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 3279 | int main() { return 0; } |
| 3280 | int t() { |
| 3281 | |
| 3282 | /* The GNU C library defines this for functions which it implements |
| 3283 | to always fail with ENOSYS. Some functions are actually named |
| 3284 | something starting with __ and the normal name is an alias. */ |
| 3285 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 3286 | choke me |
| 3287 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3288 | $ac_func(); |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 3289 | #endif |
| 3290 | |
| 3291 | ; return 0; } |
| 3292 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3293 | if { (eval echo configure:3294: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 3294 | rm -rf conftest* |
| 3295 | eval "ac_cv_func_$ac_func=yes" |
| 3296 | else |
| 3297 | rm -rf conftest* |
| 3298 | eval "ac_cv_func_$ac_func=no" |
| 3299 | fi |
| 3300 | rm -f conftest* |
| 3301 | |
| 3302 | fi |
| 3303 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3304 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3305 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 3306 | cat >> confdefs.h <<EOF |
| 3307 | #define $ac_tr_func 1 |
| 3308 | EOF |
| 3309 | |
| 3310 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3311 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 3312 | fi |
| 3313 | done |
| 3314 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 3315 | for ac_func in hypot |
| 3316 | do |
| 3317 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 3318 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 3319 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3320 | else |
| 3321 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3322 | #line 3323 "configure" |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 3323 | #include "confdefs.h" |
| 3324 | /* System header to define __stub macros and hopefully few prototypes, |
| 3325 | which can conflict with char $ac_func(); below. */ |
| 3326 | #include <assert.h> |
| 3327 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3328 | /* We use char because int might match the return type of a gcc2 |
| 3329 | builtin and then its argument prototype would still apply. */ |
| 3330 | char $ac_func(); |
| 3331 | |
| 3332 | int main() { return 0; } |
| 3333 | int t() { |
| 3334 | |
| 3335 | /* The GNU C library defines this for functions which it implements |
| 3336 | to always fail with ENOSYS. Some functions are actually named |
| 3337 | something starting with __ and the normal name is an alias. */ |
| 3338 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 3339 | choke me |
| 3340 | #else |
| 3341 | $ac_func(); |
| 3342 | #endif |
| 3343 | |
| 3344 | ; return 0; } |
| 3345 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3346 | if { (eval echo configure:3347: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 3347 | rm -rf conftest* |
| 3348 | eval "ac_cv_func_$ac_func=yes" |
| 3349 | else |
| 3350 | rm -rf conftest* |
| 3351 | eval "ac_cv_func_$ac_func=no" |
| 3352 | fi |
| 3353 | rm -f conftest* |
| 3354 | |
| 3355 | fi |
| 3356 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 3357 | echo "$ac_t""yes" 1>&6 |
| 3358 | : |
| 3359 | else |
| 3360 | echo "$ac_t""no" 1>&6 |
| 3361 | LIBOBJS="$LIBOBJS ${ac_func}.o" |
| 3362 | fi |
| 3363 | |
| 3364 | done |
| 3365 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 3366 | LIBS=$LIBS_SAVE |
| 3367 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3368 | # check for getopt |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3369 | echo $ac_n "checking for genuine getopt""... $ac_c" 1>&6 |
| 3370 | if eval "test \"`echo '$''{'ac_cv_func_getopt'+set}'`\" = set"; then |
| 3371 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3372 | else |
| 3373 | if test "$cross_compiling" = yes; then |
| 3374 | ac_cv_func_getopt=no |
| 3375 | else |
| 3376 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3377 | #line 3378 "configure" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3378 | #include "confdefs.h" |
| 3379 | #include <stdio.h> |
| 3380 | extern int optind, opterr, getopt(); |
| 3381 | extern char* optarg; |
| 3382 | int main() { |
| 3383 | char* av[] = { "testprog", "parameter", "-fFlag", NULL }; |
| 3384 | opterr = 0; |
| 3385 | if (getopt(3, av, "f:") == 'f') { exit(1); } |
| 3386 | exit(0); |
| 3387 | } |
| 3388 | EOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame^] | 3389 | { (eval echo configure:3390: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3390 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
| 3391 | ac_cv_func_getopt=yes |
| 3392 | else |
| 3393 | ac_cv_func_getopt=no |
| 3394 | fi |
| 3395 | fi |
| 3396 | rm -fr conftest* |
| 3397 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3398 | echo "$ac_t""$ac_cv_func_getopt" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3399 | test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o" |
| 3400 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3401 | # generate output files |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3402 | trap '' 1 2 15 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3403 | cat > confcache <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3404 | # This file is a shell script that caches the results of configure |
| 3405 | # tests run on this system so they can be shared between configure |
| 3406 | # scripts and configure runs. It is not useful on other systems. |
| 3407 | # If it contains results you don't want to keep, you may remove or edit it. |
| 3408 | # |
| 3409 | # By default, configure uses ./config.cache as the cache file, |
| 3410 | # creating it if it does not exist already. You can give configure |
| 3411 | # the --cache-file=FILE option to use a different cache file; that is |
| 3412 | # what configure does when it calls configure scripts in |
| 3413 | # subdirectories, so they share the cache. |
| 3414 | # Giving --cache-file=/dev/null disables caching, for debugging configure. |
| 3415 | # config.status only pays attention to the cache file if you give it the |
| 3416 | # --recheck option to rerun configure. |
| 3417 | # |
| 3418 | EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3419 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 3420 | # 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] | 3421 | (set) 2>&1 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3422 | sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \ |
| 3423 | >> confcache |
| 3424 | if cmp -s $cache_file confcache; then |
| 3425 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3426 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3427 | if test -w $cache_file; then |
| 3428 | echo "updating cache $cache_file" |
| 3429 | cat confcache > $cache_file |
| 3430 | else |
| 3431 | echo "not updating unwritable cache $cache_file" |
| 3432 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3433 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3434 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3435 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3436 | 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] | 3437 | |
| 3438 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 3439 | # Let make expand exec_prefix. |
| 3440 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3441 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3442 | # Any assignment to VPATH causes Sun make to only execute |
| 3443 | # the first set of double-colon rules, so remove it if not needed. |
| 3444 | # If there is a colon in the path, we need to keep it. |
| 3445 | if test "x$srcdir" = x.; then |
| 3446 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
| 3447 | fi |
| 3448 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3449 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3450 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3451 | DEFS=-DHAVE_CONFIG_H |
| 3452 | |
| 3453 | # Without the "./", some shells look in PATH for config.status. |
| 3454 | : ${CONFIG_STATUS=./config.status} |
| 3455 | |
| 3456 | echo creating $CONFIG_STATUS |
| 3457 | rm -f $CONFIG_STATUS |
| 3458 | cat > $CONFIG_STATUS <<EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3459 | #! /bin/sh |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3460 | # Generated automatically by configure. |
| 3461 | # Run this file to recreate the current configuration. |
| 3462 | # This directory was configured as follows, |
| 3463 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
| 3464 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3465 | # $0 $ac_configure_args |
| 3466 | # |
| 3467 | # Compiler output produced by configure, useful for debugging |
| 3468 | # configure, is in ./config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3469 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3470 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3471 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3472 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3473 | case "\$ac_option" in |
| 3474 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3475 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
| 3476 | 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] | 3477 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3478 | echo "$CONFIG_STATUS generated by autoconf version 2.10" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3479 | exit 0 ;; |
| 3480 | -help | --help | --hel | --he | --h) |
| 3481 | echo "\$ac_cs_usage"; exit 0 ;; |
| 3482 | *) echo "\$ac_cs_usage"; exit 1 ;; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3483 | esac |
| 3484 | done |
| 3485 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3486 | ac_given_srcdir=$srcdir |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3487 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3488 | trap 'rm -fr `echo "Makefile \ |
| 3489 | Objects/Makefile \ |
| 3490 | Parser/Makefile \ |
| 3491 | Python/Makefile \ |
| 3492 | Modules/Makefile.pre config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3493 | EOF |
| 3494 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3495 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3496 | # Protect against being on the right side of a sed subst in config.status. |
| 3497 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; |
| 3498 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3499 | $ac_vpsub |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3500 | $extrasub |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3501 | s%@CFLAGS@%$CFLAGS%g |
| 3502 | s%@CPPFLAGS@%$CPPFLAGS%g |
| 3503 | s%@CXXFLAGS@%$CXXFLAGS%g |
| 3504 | s%@DEFS@%$DEFS%g |
| 3505 | s%@LDFLAGS@%$LDFLAGS%g |
| 3506 | s%@LIBS@%$LIBS%g |
| 3507 | s%@exec_prefix@%$exec_prefix%g |
| 3508 | s%@prefix@%$prefix%g |
| 3509 | s%@program_transform_name@%$program_transform_name%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3510 | s%@bindir@%$bindir%g |
| 3511 | s%@sbindir@%$sbindir%g |
| 3512 | s%@libexecdir@%$libexecdir%g |
| 3513 | s%@datadir@%$datadir%g |
| 3514 | s%@sysconfdir@%$sysconfdir%g |
| 3515 | s%@sharedstatedir@%$sharedstatedir%g |
| 3516 | s%@localstatedir@%$localstatedir%g |
| 3517 | s%@libdir@%$libdir%g |
| 3518 | s%@includedir@%$includedir%g |
| 3519 | s%@oldincludedir@%$oldincludedir%g |
| 3520 | s%@infodir@%$infodir%g |
| 3521 | s%@mandir@%$mandir%g |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3522 | s%@MACHDEP@%$MACHDEP%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3523 | s%@CC@%$CC%g |
| 3524 | s%@RANLIB@%$RANLIB%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3525 | s%@AR@%$AR%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 3526 | s%@INSTALL@%$INSTALL%g |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3527 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
| 3528 | s%@INSTALL_DATA@%$INSTALL_DATA%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 3529 | s%@OPT@%$OPT%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3530 | s%@CPP@%$CPP%g |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3531 | s%@SO@%$SO%g |
| 3532 | s%@LDSHARED@%$LDSHARED%g |
| 3533 | s%@CCSHARED@%$CCSHARED%g |
| 3534 | s%@LINKFORSHARED@%$LINKFORSHARED%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3535 | s%@DLINCLDIR@%$DLINCLDIR%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3536 | s%@LIBOBJS@%$LIBOBJS%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3537 | s%@LIBM@%$LIBM%g |
| 3538 | s%@LIBC@%$LIBC%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3539 | |
| 3540 | CEOF |
| 3541 | EOF |
| 3542 | cat >> $CONFIG_STATUS <<EOF |
| 3543 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3544 | CONFIG_FILES=\${CONFIG_FILES-"Makefile \ |
| 3545 | Objects/Makefile \ |
| 3546 | Parser/Makefile \ |
| 3547 | Python/Makefile \ |
| 3548 | Modules/Makefile.pre"} |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3549 | EOF |
| 3550 | cat >> $CONFIG_STATUS <<\EOF |
| 3551 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then |
| 3552 | # Support "outfile[:infile]", defaulting infile="outfile.in". |
| 3553 | case "$ac_file" in |
| 3554 | *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'` |
| 3555 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 3556 | *) ac_file_in="${ac_file}.in" ;; |
| 3557 | esac |
| 3558 | |
| 3559 | # Adjust relative srcdir, etc. for subdirectories. |
| 3560 | |
| 3561 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 3562 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 3563 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 3564 | # The file is in a subdirectory. |
| 3565 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3566 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3567 | # A "../" for each directory in $ac_dir_suffix. |
| 3568 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
| 3569 | else |
| 3570 | ac_dir_suffix= ac_dots= |
| 3571 | fi |
| 3572 | |
| 3573 | case "$ac_given_srcdir" in |
| 3574 | .) srcdir=. |
| 3575 | if test -z "$ac_dots"; then top_srcdir=. |
| 3576 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; |
| 3577 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; |
| 3578 | *) # Relative path. |
| 3579 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
| 3580 | top_srcdir="$ac_dots$ac_given_srcdir" ;; |
| 3581 | esac |
| 3582 | |
| 3583 | echo creating "$ac_file" |
| 3584 | rm -f "$ac_file" |
| 3585 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." |
| 3586 | case "$ac_file" in |
| 3587 | *Makefile*) ac_comsub="1i\\ |
| 3588 | # $configure_input" ;; |
| 3589 | *) ac_comsub= ;; |
| 3590 | esac |
| 3591 | sed -e "$ac_comsub |
| 3592 | s%@configure_input@%$configure_input%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3593 | s%@srcdir@%$srcdir%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3594 | s%@top_srcdir@%$top_srcdir%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3595 | " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3596 | fi; done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3597 | rm -f conftest.subs |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3598 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3599 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
| 3600 | # 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] | 3601 | # |
| 3602 | # ac_d sets the value in "#define NAME VALUE" lines. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3603 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
| 3604 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3605 | ac_dC='\3' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3606 | ac_dD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3607 | # 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] | 3608 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 3609 | ac_uB='\([ ]\)%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3610 | ac_uC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3611 | ac_uD='\4%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3612 | # 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] | 3613 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 3614 | ac_eB='$%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3615 | ac_eC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3616 | ac_eD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3617 | |
| 3618 | CONFIG_HEADERS=${CONFIG_HEADERS-"config.h"} |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3619 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then |
| 3620 | # Support "outfile[:infile]", defaulting infile="outfile.in". |
| 3621 | case "$ac_file" in |
| 3622 | *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'` |
| 3623 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 3624 | *) ac_file_in="${ac_file}.in" ;; |
| 3625 | esac |
| 3626 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3627 | echo creating $ac_file |
| 3628 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3629 | rm -f conftest.frag conftest.in conftest.out |
| 3630 | cp $ac_given_srcdir/$ac_file_in conftest.in |
| 3631 | |
| 3632 | EOF |
| 3633 | |
| 3634 | # Transform confdefs.h into a sed script conftest.vals that substitutes |
| 3635 | # 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] | 3636 | # 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] | 3637 | # Protect against being in an unquoted here document in config.status. |
| 3638 | rm -f conftest.vals |
| 3639 | cat > conftest.hdr <<\EOF |
| 3640 | s/[\\&%]/\\&/g |
| 3641 | s%[\\$`]%\\&%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3642 | 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] | 3643 | s%ac_d%ac_u%gp |
| 3644 | s%ac_u%ac_e%gp |
| 3645 | EOF |
| 3646 | sed -n -f conftest.hdr confdefs.h > conftest.vals |
| 3647 | rm -f conftest.hdr |
| 3648 | |
| 3649 | # This sed command replaces #undef with comments. This is necessary, for |
| 3650 | # example, in the case of _POSIX_SOURCE, which is predefined and required |
| 3651 | # on some systems where configure will not decide to define it. |
| 3652 | cat >> conftest.vals <<\EOF |
| 3653 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% |
| 3654 | EOF |
| 3655 | |
| 3656 | # Break up conftest.vals because some shells have a limit on |
| 3657 | # the size of here documents, and old seds have small limits too. |
| 3658 | # Maximum number of lines to put in a single here document. |
| 3659 | ac_max_here_lines=12 |
| 3660 | |
| 3661 | rm -f conftest.tail |
| 3662 | while : |
| 3663 | do |
| 3664 | ac_lines=`grep -c . conftest.vals` |
| 3665 | # grep -c gives empty output for an empty file on some AIX systems. |
| 3666 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi |
| 3667 | # Write a limited-size here document to conftest.frag. |
| 3668 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS |
| 3669 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS |
| 3670 | echo 'CEOF |
| 3671 | sed -f conftest.frag conftest.in > conftest.out |
| 3672 | rm -f conftest.in |
| 3673 | mv conftest.out conftest.in |
| 3674 | ' >> $CONFIG_STATUS |
| 3675 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
| 3676 | rm -f conftest.vals |
| 3677 | mv conftest.tail conftest.vals |
| 3678 | done |
| 3679 | rm -f conftest.vals |
| 3680 | |
| 3681 | cat >> $CONFIG_STATUS <<\EOF |
| 3682 | rm -f conftest.frag conftest.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3683 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3684 | cat conftest.in >> conftest.h |
| 3685 | rm -f conftest.in |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3686 | if cmp -s $ac_file conftest.h 2>/dev/null; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3687 | echo "$ac_file is unchanged" |
| 3688 | rm -f conftest.h |
| 3689 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3690 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 3691 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 3692 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 3693 | # The file is in a subdirectory. |
| 3694 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
| 3695 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3696 | rm -f $ac_file |
| 3697 | mv conftest.h $ac_file |
| 3698 | fi |
| 3699 | fi; done |
| 3700 | |
| 3701 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3702 | |
| 3703 | exit 0 |
| 3704 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3705 | chmod +x $CONFIG_STATUS |
| 3706 | rm -fr confdefs* $ac_clean_files |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3707 | 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] | 3708 | |