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