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 | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 778 | was_it_defined=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 779 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 780 | fi |
| 781 | rm -fr conftest* |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 782 | echo $ac_n "checking for NeXT""... $ac_c" 1>&4 |
| 783 | echo "$ac_t""$was_it_defined" 1>&4 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 784 | |
| 785 | # checks for header files |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 786 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&4 |
| 787 | if eval "test \"`echo '${'ac_cv_header_stdc'+set}'`\" = set"; then |
| 788 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 789 | else |
| 790 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 791 | #line 792 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 792 | #include "confdefs.h" |
| 793 | #include <stdlib.h> |
| 794 | #include <stdarg.h> |
| 795 | #include <string.h> |
| 796 | #include <float.h> |
| 797 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 798 | eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 799 | ac_err=`grep -v '^ *+' conftest.out` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 800 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 801 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 802 | ac_cv_header_stdc=yes |
| 803 | else |
| 804 | echo "$ac_err" >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 805 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 806 | ac_cv_header_stdc=no |
| 807 | fi |
| 808 | rm -f conftest* |
| 809 | |
| 810 | if test $ac_cv_header_stdc = yes; then |
| 811 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 812 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 813 | #line 814 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 814 | #include "confdefs.h" |
| 815 | #include <string.h> |
| 816 | EOF |
| 817 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 818 | egrep "memchr" >/dev/null 2>&1; then |
| 819 | : |
| 820 | else |
| 821 | rm -rf conftest* |
| 822 | ac_cv_header_stdc=no |
| 823 | fi |
| 824 | rm -f conftest* |
| 825 | |
| 826 | fi |
| 827 | |
| 828 | if test $ac_cv_header_stdc = yes; then |
| 829 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 830 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 831 | #line 832 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 832 | #include "confdefs.h" |
| 833 | #include <stdlib.h> |
| 834 | EOF |
| 835 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 836 | egrep "free" >/dev/null 2>&1; then |
| 837 | : |
| 838 | else |
| 839 | rm -rf conftest* |
| 840 | ac_cv_header_stdc=no |
| 841 | fi |
| 842 | rm -f conftest* |
| 843 | |
| 844 | fi |
| 845 | |
| 846 | if test $ac_cv_header_stdc = yes; then |
| 847 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 848 | if test "$cross_compiling" = yes; then |
| 849 | ac_cv_header_stdc=no |
| 850 | else |
| 851 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 852 | #line 853 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 853 | #include "confdefs.h" |
| 854 | #include <ctype.h> |
| 855 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 856 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 857 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 858 | int main () { int i; for (i = 0; i < 256; i++) |
| 859 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); |
| 860 | exit (0); } |
| 861 | |
| 862 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 863 | eval $ac_link |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 864 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 865 | : |
| 866 | else |
| 867 | ac_cv_header_stdc=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 868 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 869 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 870 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 871 | fi |
| 872 | fi |
| 873 | echo "$ac_t""$ac_cv_header_stdc" 1>&4 |
| 874 | if test $ac_cv_header_stdc = yes; then |
| 875 | cat >> confdefs.h <<\EOF |
| 876 | #define STDC_HEADERS 1 |
| 877 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 878 | |
| 879 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 880 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 881 | 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] | 882 | do |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 883 | ac_safe=`echo "$ac_hdr" | tr './\055' '___'` |
| 884 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&4 |
| 885 | if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 886 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 887 | else |
| 888 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 889 | #line 890 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 890 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 891 | #include <$ac_hdr> |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 892 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 893 | eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 894 | ac_err=`grep -v '^ *+' conftest.out` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 895 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 896 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 897 | eval "ac_cv_header_$ac_safe=yes" |
| 898 | else |
| 899 | echo "$ac_err" >&5 |
| 900 | rm -rf conftest* |
| 901 | eval "ac_cv_header_$ac_safe=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 902 | fi |
| 903 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 904 | fi |
| 905 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 906 | echo "$ac_t""yes" 1>&4 |
| 907 | ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'` |
| 908 | cat >> confdefs.h <<EOF |
| 909 | #define $ac_tr_hdr 1 |
| 910 | EOF |
| 911 | |
| 912 | else |
| 913 | echo "$ac_t""no" 1>&4 |
| 914 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 915 | done |
| 916 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 917 | ac_header_dirent=no |
| 918 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h |
| 919 | do |
| 920 | ac_safe=`echo "$ac_hdr" | tr './\055' '___'` |
| 921 | echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&4 |
| 922 | if eval "test \"`echo '${'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then |
| 923 | echo $ac_n "(cached) $ac_c" 1>&4 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 924 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 925 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 926 | #line 927 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 927 | #include "confdefs.h" |
| 928 | #include <sys/types.h> |
| 929 | #include <$ac_hdr> |
| 930 | int main() { return 0; } |
| 931 | int t() { |
| 932 | DIR *dirp = 0; |
| 933 | ; return 0; } |
| 934 | EOF |
| 935 | if eval $ac_compile; then |
| 936 | rm -rf conftest* |
| 937 | eval "ac_cv_header_dirent_$ac_safe=yes" |
| 938 | else |
| 939 | rm -rf conftest* |
| 940 | eval "ac_cv_header_dirent_$ac_safe=no" |
| 941 | fi |
| 942 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 943 | |
| 944 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 945 | if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then |
| 946 | echo "$ac_t""yes" 1>&4 |
| 947 | ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'` |
| 948 | cat >> confdefs.h <<EOF |
| 949 | #define $ac_tr_hdr 1 |
| 950 | EOF |
| 951 | ac_header_dirent=$ac_hdr; break |
| 952 | else |
| 953 | echo "$ac_t""no" 1>&4 |
| 954 | fi |
| 955 | done |
| 956 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 957 | if test $ac_header_dirent = dirent.h; then |
| 958 | echo $ac_n "checking for -ldir""... $ac_c" 1>&4 |
| 959 | if eval "test \"`echo '${'ac_cv_lib_dir'+set}'`\" = set"; then |
| 960 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 961 | else |
| 962 | ac_save_LIBS="$LIBS" |
| 963 | LIBS="$LIBS -ldir " |
| 964 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 965 | #line 966 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 966 | #include "confdefs.h" |
| 967 | |
| 968 | int main() { return 0; } |
| 969 | int t() { |
| 970 | opendir() |
| 971 | ; return 0; } |
| 972 | EOF |
| 973 | if eval $ac_link; then |
| 974 | rm -rf conftest* |
| 975 | eval "ac_cv_lib_dir=yes" |
| 976 | else |
| 977 | rm -rf conftest* |
| 978 | eval "ac_cv_lib_dir=no" |
| 979 | fi |
| 980 | rm -f conftest* |
| 981 | LIBS="$ac_save_LIBS" |
| 982 | |
| 983 | fi |
| 984 | if eval "test \"`echo '$ac_cv_lib_'dir`\" = yes"; then |
| 985 | echo "$ac_t""yes" 1>&4 |
| 986 | LIBS="$LIBS -ldir" |
| 987 | else |
| 988 | echo "$ac_t""no" 1>&4 |
| 989 | fi |
| 990 | |
| 991 | else |
| 992 | echo $ac_n "checking for -lx""... $ac_c" 1>&4 |
| 993 | if eval "test \"`echo '${'ac_cv_lib_x'+set}'`\" = set"; then |
| 994 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 995 | else |
| 996 | ac_save_LIBS="$LIBS" |
| 997 | LIBS="$LIBS -lx " |
| 998 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 999 | #line 1000 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1000 | #include "confdefs.h" |
| 1001 | |
| 1002 | int main() { return 0; } |
| 1003 | int t() { |
| 1004 | opendir() |
| 1005 | ; return 0; } |
| 1006 | EOF |
| 1007 | if eval $ac_link; then |
| 1008 | rm -rf conftest* |
| 1009 | eval "ac_cv_lib_x=yes" |
| 1010 | else |
| 1011 | rm -rf conftest* |
| 1012 | eval "ac_cv_lib_x=no" |
| 1013 | fi |
| 1014 | rm -f conftest* |
| 1015 | LIBS="$ac_save_LIBS" |
| 1016 | |
| 1017 | fi |
| 1018 | if eval "test \"`echo '$ac_cv_lib_'x`\" = yes"; then |
| 1019 | echo "$ac_t""yes" 1>&4 |
| 1020 | LIBS="$LIBS -lx" |
| 1021 | else |
| 1022 | echo "$ac_t""no" 1>&4 |
| 1023 | fi |
| 1024 | |
| 1025 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1026 | |
| 1027 | |
| 1028 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1029 | was_it_defined=no |
| 1030 | 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] | 1031 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1032 | #line 1033 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1033 | #include "confdefs.h" |
| 1034 | #include <time.h> |
| 1035 | EOF |
| 1036 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1037 | egrep "clock_t" >/dev/null 2>&1; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1038 | rm -rf conftest* |
| 1039 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1040 | else |
| 1041 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1042 | cat >> confdefs.h <<\EOF |
| 1043 | #define clock_t long |
| 1044 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1045 | |
| 1046 | fi |
| 1047 | rm -f conftest* |
| 1048 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1049 | echo "$ac_t""$was_it_defined" 1>&4 |
| 1050 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1051 | echo $ac_n "checking for mode_t""... $ac_c" 1>&4 |
| 1052 | if eval "test \"`echo '${'ac_cv_type_mode_t'+set}'`\" = set"; then |
| 1053 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1054 | else |
| 1055 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1056 | #line 1057 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1057 | #include "confdefs.h" |
| 1058 | #include <sys/types.h> |
| 1059 | #if STDC_HEADERS |
| 1060 | #include <stdlib.h> |
| 1061 | #endif |
| 1062 | EOF |
| 1063 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1064 | egrep "mode_t" >/dev/null 2>&1; then |
| 1065 | rm -rf conftest* |
| 1066 | ac_cv_type_mode_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1067 | else |
| 1068 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1069 | ac_cv_type_mode_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1070 | fi |
| 1071 | rm -f conftest* |
| 1072 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1073 | fi |
| 1074 | echo "$ac_t""$ac_cv_type_mode_t" 1>&4 |
| 1075 | if test $ac_cv_type_mode_t = no; then |
| 1076 | cat >> confdefs.h <<\EOF |
| 1077 | #define mode_t int |
| 1078 | EOF |
| 1079 | |
| 1080 | fi |
| 1081 | |
| 1082 | echo $ac_n "checking for off_t""... $ac_c" 1>&4 |
| 1083 | if eval "test \"`echo '${'ac_cv_type_off_t'+set}'`\" = set"; then |
| 1084 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1085 | else |
| 1086 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1087 | #line 1088 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1088 | #include "confdefs.h" |
| 1089 | #include <sys/types.h> |
| 1090 | #if STDC_HEADERS |
| 1091 | #include <stdlib.h> |
| 1092 | #endif |
| 1093 | EOF |
| 1094 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1095 | egrep "off_t" >/dev/null 2>&1; then |
| 1096 | rm -rf conftest* |
| 1097 | ac_cv_type_off_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1098 | else |
| 1099 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1100 | ac_cv_type_off_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1101 | fi |
| 1102 | rm -f conftest* |
| 1103 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1104 | fi |
| 1105 | echo "$ac_t""$ac_cv_type_off_t" 1>&4 |
| 1106 | if test $ac_cv_type_off_t = no; then |
| 1107 | cat >> confdefs.h <<\EOF |
| 1108 | #define off_t long |
| 1109 | EOF |
| 1110 | |
| 1111 | fi |
| 1112 | |
| 1113 | echo $ac_n "checking for pid_t""... $ac_c" 1>&4 |
| 1114 | if eval "test \"`echo '${'ac_cv_type_pid_t'+set}'`\" = set"; then |
| 1115 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1116 | else |
| 1117 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1118 | #line 1119 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1119 | #include "confdefs.h" |
| 1120 | #include <sys/types.h> |
| 1121 | #if STDC_HEADERS |
| 1122 | #include <stdlib.h> |
| 1123 | #endif |
| 1124 | EOF |
| 1125 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1126 | egrep "pid_t" >/dev/null 2>&1; then |
| 1127 | rm -rf conftest* |
| 1128 | ac_cv_type_pid_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1129 | else |
| 1130 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1131 | ac_cv_type_pid_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1132 | fi |
| 1133 | rm -f conftest* |
| 1134 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1135 | fi |
| 1136 | echo "$ac_t""$ac_cv_type_pid_t" 1>&4 |
| 1137 | if test $ac_cv_type_pid_t = no; then |
| 1138 | cat >> confdefs.h <<\EOF |
| 1139 | #define pid_t int |
| 1140 | EOF |
| 1141 | |
| 1142 | fi |
| 1143 | |
| 1144 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&4 |
| 1145 | if eval "test \"`echo '${'ac_cv_type_signal'+set}'`\" = set"; then |
| 1146 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1147 | else |
| 1148 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1149 | #line 1150 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1150 | #include "confdefs.h" |
| 1151 | #include <sys/types.h> |
| 1152 | #include <signal.h> |
| 1153 | #ifdef signal |
| 1154 | #undef signal |
| 1155 | #endif |
| 1156 | extern void (*signal ()) (); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1157 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1158 | int t() { |
| 1159 | int i; |
| 1160 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1161 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1162 | if eval $ac_compile; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1163 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1164 | ac_cv_type_signal=void |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1165 | else |
| 1166 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1167 | ac_cv_type_signal=int |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1168 | fi |
| 1169 | rm -f conftest* |
| 1170 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1171 | fi |
| 1172 | echo "$ac_t""$ac_cv_type_signal" 1>&4 |
| 1173 | cat >> confdefs.h <<EOF |
| 1174 | #define RETSIGTYPE $ac_cv_type_signal |
| 1175 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1176 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1177 | |
| 1178 | echo $ac_n "checking for size_t""... $ac_c" 1>&4 |
| 1179 | if eval "test \"`echo '${'ac_cv_type_size_t'+set}'`\" = set"; then |
| 1180 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1181 | else |
| 1182 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1183 | #line 1184 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1184 | #include "confdefs.h" |
| 1185 | #include <sys/types.h> |
| 1186 | #if STDC_HEADERS |
| 1187 | #include <stdlib.h> |
| 1188 | #endif |
| 1189 | EOF |
| 1190 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1191 | egrep "size_t" >/dev/null 2>&1; then |
| 1192 | rm -rf conftest* |
| 1193 | ac_cv_type_size_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1194 | else |
| 1195 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1196 | ac_cv_type_size_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1197 | fi |
| 1198 | rm -f conftest* |
| 1199 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1200 | fi |
| 1201 | echo "$ac_t""$ac_cv_type_size_t" 1>&4 |
| 1202 | if test $ac_cv_type_size_t = no; then |
| 1203 | cat >> confdefs.h <<\EOF |
| 1204 | #define size_t unsigned |
| 1205 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1206 | |
| 1207 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1208 | |
| 1209 | echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&4 |
| 1210 | if eval "test \"`echo '${'ac_cv_type_uid_t'+set}'`\" = set"; then |
| 1211 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1212 | else |
| 1213 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1214 | #line 1215 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1215 | #include "confdefs.h" |
| 1216 | #include <sys/types.h> |
| 1217 | EOF |
| 1218 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1219 | egrep "uid_t" >/dev/null 2>&1; then |
| 1220 | rm -rf conftest* |
| 1221 | ac_cv_type_uid_t=yes |
| 1222 | else |
| 1223 | rm -rf conftest* |
| 1224 | ac_cv_type_uid_t=no |
| 1225 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1226 | rm -f conftest* |
| 1227 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1228 | fi |
| 1229 | echo "$ac_t""$ac_cv_type_uid_t" 1>&4 |
| 1230 | if test $ac_cv_type_uid_t = no; then |
| 1231 | cat >> confdefs.h <<\EOF |
| 1232 | #define uid_t int |
| 1233 | EOF |
| 1234 | |
| 1235 | cat >> confdefs.h <<\EOF |
| 1236 | #define gid_t int |
| 1237 | EOF |
| 1238 | |
| 1239 | fi |
| 1240 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1241 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1242 | # Set name for machine-dependent library files |
| 1243 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1244 | echo $ac_n "checking MACHDEP""... $ac_c" 1>&4 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1245 | if test -z "$MACHDEP" |
| 1246 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1247 | ac_sys_system=`uname -s | tr -d ' ' | tr '[A-Z]' '[a-z]'` |
| 1248 | ac_sys_release=`uname -r | tr -d ' ' | sed 's/\..*//'` |
| 1249 | MACHDEP="$ac_sys_system$ac_sys_release" |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1250 | case MACHDEP in |
| 1251 | '') MACHDEP=unknown;; |
| 1252 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1253 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1254 | echo "$ac_t""$MACHDEP" 1>&4 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1255 | |
| 1256 | # Set info about shared libraries. |
| 1257 | # XXX This should try things out instead of testing uname! |
| 1258 | |
| 1259 | |
| 1260 | |
| 1261 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1262 | ac_sys_system=`uname -s` |
| 1263 | ac_sys_release=`uname -r` |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1264 | # SO is the extension of shared libraries `(including the dot!) |
| 1265 | # -- usually .so, .sl on HP-UX |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1266 | echo $ac_n "checking SO""... $ac_c" 1>&4 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1267 | if test -z "$SO" |
| 1268 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1269 | case $ac_sys_system in |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1270 | hp*|HP*) SO=.sl;; |
| 1271 | *) SO=.so;; |
| 1272 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1273 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1274 | echo "$ac_t""$SO" 1>&4 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1275 | # LDSHARED is the ld *command* used to create shared library |
| 1276 | # -- "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] | 1277 | echo $ac_n "checking LDSHARED""... $ac_c" 1>&4 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1278 | if test -z "$LDSHARED" |
| 1279 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1280 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1281 | IRIX*) LDSHARED="ld -shared";; |
| 1282 | SunOS/4*) LDSHARED="ld";; |
| 1283 | SunOS/5*) LDSHARED="ld -G";; |
| 1284 | hp*|HP*) LDSHARED="ld -b";; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1285 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
| 1286 | DYNIX/ptx*) LDSHARED="ld -G";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1287 | *) LDSHARED="ld";; |
| 1288 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1289 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1290 | echo "$ac_t""$LDSHARED" 1>&4 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1291 | # CCSHARED are the C *flags* used to create objects to go into a shared |
| 1292 | # library -- this is only needed for HP-UX |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1293 | echo $ac_n "checking CCSHARED""... $ac_c" 1>&4 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1294 | if test -z "$CCSHARED" |
| 1295 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1296 | case $ac_sys_system in |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1297 | hp*|HP*) CCSHARED="+z";; |
| 1298 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1299 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1300 | echo "$ac_t""$CCSHARED" 1>&4 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1301 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
| 1302 | # the python executable -- this is only needed for HP-UX |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1303 | echo $ac_n "checking LINKFORSHARED""... $ac_c" 1>&4 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1304 | if test -z "$LINKFORSHARED" |
| 1305 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1306 | case $ac_sys_system in |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1307 | hp*|HP*) LINKFORSHARED="-Wl,-E";; |
| 1308 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1309 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1310 | echo "$ac_t""$LINKFORSHARED" 1>&4 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 1311 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1312 | # checks for libraries |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1313 | echo $ac_n "checking for -ldl""... $ac_c" 1>&4 |
| 1314 | if eval "test \"`echo '${'ac_cv_lib_dl'+set}'`\" = set"; then |
| 1315 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1316 | else |
| 1317 | ac_save_LIBS="$LIBS" |
| 1318 | LIBS="$LIBS -ldl " |
| 1319 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1320 | #line 1321 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1321 | #include "confdefs.h" |
| 1322 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1323 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1324 | int t() { |
| 1325 | dlopen() |
| 1326 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1327 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1328 | if eval $ac_link; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1329 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1330 | eval "ac_cv_lib_dl=yes" |
| 1331 | else |
| 1332 | rm -rf conftest* |
| 1333 | eval "ac_cv_lib_dl=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1334 | fi |
| 1335 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1336 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1337 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1338 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1339 | if eval "test \"`echo '$ac_cv_lib_'dl`\" = yes"; then |
| 1340 | echo "$ac_t""yes" 1>&4 |
| 1341 | ac_tr_lib=HAVE_LIB`echo dl | tr '[a-z]' '[A-Z]'` |
| 1342 | cat >> confdefs.h <<EOF |
| 1343 | #define $ac_tr_lib 1 |
| 1344 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1345 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1346 | LIBS="$LIBS -ldl" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1347 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1348 | else |
| 1349 | echo "$ac_t""no" 1>&4 |
| 1350 | fi |
| 1351 | # Dynamic linking for SunOS/Solaris and SYSV |
| 1352 | echo $ac_n "checking for -ldld""... $ac_c" 1>&4 |
| 1353 | if eval "test \"`echo '${'ac_cv_lib_dld'+set}'`\" = set"; then |
| 1354 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1355 | else |
| 1356 | ac_save_LIBS="$LIBS" |
| 1357 | LIBS="$LIBS -ldld " |
| 1358 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1359 | #line 1360 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1360 | #include "confdefs.h" |
| 1361 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1362 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1363 | int t() { |
| 1364 | shl_load() |
| 1365 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1366 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1367 | if eval $ac_link; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1368 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1369 | eval "ac_cv_lib_dld=yes" |
| 1370 | else |
| 1371 | rm -rf conftest* |
| 1372 | eval "ac_cv_lib_dld=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1373 | fi |
| 1374 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1375 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1376 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1377 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1378 | if eval "test \"`echo '$ac_cv_lib_'dld`\" = yes"; then |
| 1379 | echo "$ac_t""yes" 1>&4 |
| 1380 | ac_tr_lib=HAVE_LIB`echo dld | tr '[a-z]' '[A-Z]'` |
| 1381 | cat >> confdefs.h <<EOF |
| 1382 | #define $ac_tr_lib 1 |
| 1383 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1384 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1385 | LIBS="$LIBS -ldld" |
| 1386 | |
| 1387 | else |
| 1388 | echo "$ac_t""no" 1>&4 |
| 1389 | fi |
| 1390 | # Dynamic linking for HP-UX |
| 1391 | echo $ac_n "checking for -lsun""... $ac_c" 1>&4 |
| 1392 | if eval "test \"`echo '${'ac_cv_lib_sun'+set}'`\" = set"; then |
| 1393 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1394 | else |
| 1395 | ac_save_LIBS="$LIBS" |
| 1396 | LIBS="$LIBS -lsun " |
| 1397 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1398 | #line 1399 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1399 | #include "confdefs.h" |
| 1400 | |
| 1401 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1402 | int t() { |
| 1403 | getpwnam() |
| 1404 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1405 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1406 | if eval $ac_link; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1407 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1408 | eval "ac_cv_lib_sun=yes" |
| 1409 | else |
| 1410 | rm -rf conftest* |
| 1411 | eval "ac_cv_lib_sun=no" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1412 | fi |
| 1413 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1414 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1415 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1416 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1417 | if eval "test \"`echo '$ac_cv_lib_'sun`\" = yes"; then |
| 1418 | echo "$ac_t""yes" 1>&4 |
| 1419 | ac_tr_lib=HAVE_LIB`echo sun | tr '[a-z]' '[A-Z]'` |
| 1420 | cat >> confdefs.h <<EOF |
| 1421 | #define $ac_tr_lib 1 |
| 1422 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1423 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1424 | LIBS="$LIBS -lsun" |
| 1425 | |
| 1426 | else |
| 1427 | echo "$ac_t""no" 1>&4 |
| 1428 | fi |
| 1429 | # NIS (== YP) interface for IRIX 4 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1430 | # The following three (nsl,inet,socket) are needed on Sequent; |
| 1431 | # the order of checking must be this. Most SVR4 platforms will |
| 1432 | # need -lsocket and -lnsl. However on SGI IRIX 5, these exist but |
| 1433 | # broken. I see no elegant solution (probably CHECK_LIB should be |
| 1434 | # fixed to only add the library if the given entry point is not |
| 1435 | # satisfied without it). |
| 1436 | if test "`uname -s`" != IRIX |
| 1437 | then |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1438 | echo $ac_n "checking for -lnsl""... $ac_c" 1>&4 |
| 1439 | if eval "test \"`echo '${'ac_cv_lib_nsl'+set}'`\" = set"; then |
| 1440 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1441 | else |
| 1442 | ac_save_LIBS="$LIBS" |
| 1443 | LIBS="$LIBS -lnsl " |
| 1444 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1445 | #line 1446 "configure" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1446 | #include "confdefs.h" |
| 1447 | |
| 1448 | int main() { return 0; } |
| 1449 | int t() { |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 1450 | t_open() |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1451 | ; return 0; } |
| 1452 | EOF |
| 1453 | if eval $ac_link; then |
| 1454 | rm -rf conftest* |
| 1455 | eval "ac_cv_lib_nsl=yes" |
| 1456 | else |
| 1457 | rm -rf conftest* |
| 1458 | eval "ac_cv_lib_nsl=no" |
| 1459 | fi |
| 1460 | rm -f conftest* |
| 1461 | LIBS="$ac_save_LIBS" |
| 1462 | |
| 1463 | fi |
| 1464 | if eval "test \"`echo '$ac_cv_lib_'nsl`\" = yes"; then |
| 1465 | echo "$ac_t""yes" 1>&4 |
| 1466 | LIBS="-lnsl $LIBS" |
| 1467 | else |
| 1468 | echo "$ac_t""no" 1>&4 |
| 1469 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 1470 | # SVR4 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1471 | echo $ac_n "checking for -linet""... $ac_c" 1>&4 |
| 1472 | if eval "test \"`echo '${'ac_cv_lib_inet'+set}'`\" = set"; then |
| 1473 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1474 | else |
| 1475 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 1476 | LIBS="$LIBS -linet -lnsl" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1477 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1478 | #line 1479 "configure" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1479 | #include "confdefs.h" |
| 1480 | |
| 1481 | int main() { return 0; } |
| 1482 | int t() { |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 1483 | gethostbyname() |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1484 | ; return 0; } |
| 1485 | EOF |
| 1486 | if eval $ac_link; then |
| 1487 | rm -rf conftest* |
| 1488 | eval "ac_cv_lib_inet=yes" |
| 1489 | else |
| 1490 | rm -rf conftest* |
| 1491 | eval "ac_cv_lib_inet=no" |
| 1492 | fi |
| 1493 | rm -f conftest* |
| 1494 | LIBS="$ac_save_LIBS" |
| 1495 | |
| 1496 | fi |
| 1497 | if eval "test \"`echo '$ac_cv_lib_'inet`\" = yes"; then |
| 1498 | echo "$ac_t""yes" 1>&4 |
| 1499 | LIBS="-linet $LIBS" |
| 1500 | else |
| 1501 | echo "$ac_t""no" 1>&4 |
| 1502 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 1503 | # Sequent |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1504 | echo $ac_n "checking for -lsocket""... $ac_c" 1>&4 |
| 1505 | if eval "test \"`echo '${'ac_cv_lib_socket'+set}'`\" = set"; then |
| 1506 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1507 | else |
| 1508 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 1509 | LIBS="$LIBS -lsocket $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1510 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1511 | #line 1512 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1512 | #include "confdefs.h" |
| 1513 | |
| 1514 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1515 | int t() { |
| 1516 | socket() |
| 1517 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1518 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1519 | if eval $ac_link; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1520 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1521 | eval "ac_cv_lib_socket=yes" |
| 1522 | else |
| 1523 | rm -rf conftest* |
| 1524 | eval "ac_cv_lib_socket=no" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1525 | fi |
| 1526 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1527 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1528 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1529 | fi |
| 1530 | if eval "test \"`echo '$ac_cv_lib_'socket`\" = yes"; then |
| 1531 | echo "$ac_t""yes" 1>&4 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1532 | LIBS="-lsocket $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1533 | else |
| 1534 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1535 | fi |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 1536 | # SVR4 sockets |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1537 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1538 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1539 | echo $ac_n "checking for --with-readline""... $ac_c" 1>&4 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1540 | # Check whether --with-readline or --without-readline was given. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1541 | withval="$with_readline" |
| 1542 | if test -n "$withval"; then |
| 1543 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1544 | echo "$ac_t""$withval" 1>&4 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1545 | cat >> confdefs.h <<\EOF |
| 1546 | #define WITH_READLINE 1 |
| 1547 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1548 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1549 | if test ! -d "$withval" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1550 | 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] | 1551 | fi |
| 1552 | termcap= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1553 | echo $ac_n "checking for -ltermcap""... $ac_c" 1>&4 |
| 1554 | if eval "test \"`echo '${'ac_cv_lib_termcap'+set}'`\" = set"; then |
| 1555 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1556 | else |
| 1557 | ac_save_LIBS="$LIBS" |
| 1558 | LIBS="$LIBS -ltermcap " |
| 1559 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1560 | #line 1561 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1561 | #include "confdefs.h" |
| 1562 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1563 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1564 | int t() { |
| 1565 | tgetent() |
| 1566 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1567 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1568 | if eval $ac_link; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1569 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1570 | eval "ac_cv_lib_termcap=yes" |
| 1571 | else |
| 1572 | rm -rf conftest* |
| 1573 | eval "ac_cv_lib_termcap=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1574 | fi |
| 1575 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1576 | LIBS="$ac_save_LIBS" |
| 1577 | |
| 1578 | fi |
| 1579 | if eval "test \"`echo '$ac_cv_lib_'termcap`\" = yes"; then |
| 1580 | echo "$ac_t""yes" 1>&4 |
| 1581 | termcap=termcap |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1582 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1583 | echo "$ac_t""no" 1>&4 |
| 1584 | |
| 1585 | echo $ac_n "checking for -ltermlib""... $ac_c" 1>&4 |
| 1586 | if eval "test \"`echo '${'ac_cv_lib_termlib'+set}'`\" = set"; then |
| 1587 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1588 | else |
| 1589 | ac_save_LIBS="$LIBS" |
| 1590 | LIBS="$LIBS -ltermlib " |
| 1591 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1592 | #line 1593 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1593 | #include "confdefs.h" |
| 1594 | |
| 1595 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1596 | int t() { |
| 1597 | tgetent() |
| 1598 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1599 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1600 | if eval $ac_link; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1601 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1602 | eval "ac_cv_lib_termlib=yes" |
| 1603 | else |
| 1604 | rm -rf conftest* |
| 1605 | eval "ac_cv_lib_termlib=no" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1606 | fi |
| 1607 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1608 | LIBS="$ac_save_LIBS" |
| 1609 | |
| 1610 | fi |
| 1611 | if eval "test \"`echo '$ac_cv_lib_'termlib`\" = yes"; then |
| 1612 | echo "$ac_t""yes" 1>&4 |
| 1613 | termcap=termlib |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1614 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1615 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1616 | fi |
| 1617 | |
| 1618 | fi |
| 1619 | |
| 1620 | if test ! -z "$termcap" |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1621 | then LIBS="$LIBS $withval/libreadline.a" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1622 | # Avoid possible conflict between shared libraries termcap and gl |
| 1623 | # on IRIX 5: both contain a routine called clear. |
| 1624 | if test -f /usr/lib/lib$termcap.a |
| 1625 | then LIBS="$LIBS /usr/lib/lib$termcap.a" |
| 1626 | else LIBS="$LIBS -l$termcap" |
| 1627 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1628 | 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] | 1629 | fi |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1630 | else |
| 1631 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1632 | fi |
| 1633 | |
| 1634 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1635 | echo $ac_n "checking for --with-thread""... $ac_c" 1>&4 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1636 | # Check whether --with-thread or --without-thread was given. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1637 | withval="$with_thread" |
| 1638 | if test -n "$withval"; then |
| 1639 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1640 | echo "$ac_t""$withval" 1>&4 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1641 | if test -d "$withval" |
| 1642 | then LIBS="$LIBS -L$withval" |
| 1643 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1644 | echo $ac_n "checking for -lpthreads""... $ac_c" 1>&4 |
| 1645 | if eval "test \"`echo '${'ac_cv_lib_pthreads'+set}'`\" = set"; then |
| 1646 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1647 | else |
| 1648 | ac_save_LIBS="$LIBS" |
| 1649 | LIBS="$LIBS -lpthreads " |
| 1650 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1651 | #line 1652 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1652 | #include "confdefs.h" |
| 1653 | |
| 1654 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1655 | int t() { |
| 1656 | pthread_create() |
| 1657 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1658 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1659 | if eval $ac_link; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1660 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1661 | eval "ac_cv_lib_pthreads=yes" |
| 1662 | else |
| 1663 | rm -rf conftest* |
| 1664 | eval "ac_cv_lib_pthreads=no" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1665 | fi |
| 1666 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1667 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1668 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1669 | fi |
| 1670 | if eval "test \"`echo '$ac_cv_lib_'pthreads`\" = yes"; then |
| 1671 | echo "$ac_t""yes" 1>&4 |
| 1672 | cat >> confdefs.h <<\EOF |
| 1673 | #define WITH_THREAD 1 |
| 1674 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1675 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1676 | cat >> confdefs.h <<\EOF |
| 1677 | #define _POSIX_THREADS 1 |
| 1678 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1679 | |
| 1680 | LIBS="$LIBS -lpthreads" |
| 1681 | LIBOBJS="$LIBOBJS thread.o" |
| 1682 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1683 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1684 | fi |
| 1685 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1686 | echo $ac_n "checking for -lmpc""... $ac_c" 1>&4 |
| 1687 | if eval "test \"`echo '${'ac_cv_lib_mpc'+set}'`\" = set"; then |
| 1688 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1689 | else |
| 1690 | ac_save_LIBS="$LIBS" |
| 1691 | LIBS="$LIBS -lmpc " |
| 1692 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1693 | #line 1694 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1694 | #include "confdefs.h" |
| 1695 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1696 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1697 | int t() { |
| 1698 | usconfig() |
| 1699 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1700 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1701 | if eval $ac_link; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1702 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1703 | eval "ac_cv_lib_mpc=yes" |
| 1704 | else |
| 1705 | rm -rf conftest* |
| 1706 | eval "ac_cv_lib_mpc=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1707 | fi |
| 1708 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1709 | LIBS="$ac_save_LIBS" |
| 1710 | |
| 1711 | fi |
| 1712 | if eval "test \"`echo '$ac_cv_lib_'mpc`\" = yes"; then |
| 1713 | echo "$ac_t""yes" 1>&4 |
| 1714 | cat >> confdefs.h <<\EOF |
| 1715 | #define WITH_THREAD 1 |
| 1716 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1717 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1718 | LIBS="$LIBS -lmpc" |
| 1719 | LIBOBJS="$LIBOBJS thread.o" |
| 1720 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1721 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1722 | fi |
| 1723 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1724 | echo $ac_n "checking for -lthread""... $ac_c" 1>&4 |
| 1725 | if eval "test \"`echo '${'ac_cv_lib_thread'+set}'`\" = set"; then |
| 1726 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1727 | else |
| 1728 | ac_save_LIBS="$LIBS" |
| 1729 | LIBS="$LIBS -lthread " |
| 1730 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1731 | #line 1732 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1732 | #include "confdefs.h" |
| 1733 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1734 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1735 | int t() { |
| 1736 | thr_create() |
| 1737 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1738 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1739 | if eval $ac_link; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1740 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1741 | eval "ac_cv_lib_thread=yes" |
| 1742 | else |
| 1743 | rm -rf conftest* |
| 1744 | eval "ac_cv_lib_thread=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1745 | fi |
| 1746 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1747 | LIBS="$ac_save_LIBS" |
| 1748 | |
| 1749 | fi |
| 1750 | if eval "test \"`echo '$ac_cv_lib_'thread`\" = yes"; then |
| 1751 | echo "$ac_t""yes" 1>&4 |
| 1752 | cat >> confdefs.h <<\EOF |
| 1753 | #define WITH_THREAD 1 |
| 1754 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1755 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1756 | LIBS="$LIBS -lthread" |
| 1757 | LIBOBJS="$LIBOBJS thread.o" |
| 1758 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1759 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1760 | fi |
| 1761 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1762 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1763 | else |
| 1764 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1765 | fi |
| 1766 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1767 | |
| 1768 | # -I${DLINCLDIR} is added to the compile rule for import.o |
| 1769 | |
| 1770 | DLINCLDIR=/ |
| 1771 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1772 | 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] | 1773 | # Check whether --with-sgi-dl or --without-sgi-dl was given. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1774 | withval="$with_sgi_dl" |
| 1775 | if test -n "$withval"; then |
| 1776 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1777 | echo "$ac_t""$withval" 1>&4 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1778 | cat >> confdefs.h <<\EOF |
| 1779 | #define WITH_SGI_DL 1 |
| 1780 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1781 | |
| 1782 | dldir=$withval |
| 1783 | if test -d "$dldir" |
| 1784 | then LIBS="$LIBS -L$dldir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1785 | 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] | 1786 | fi |
| 1787 | DLINCLDIR=${dldir} |
| 1788 | LIBS="$LIBS -ldl -lmld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1789 | else |
| 1790 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1791 | fi |
| 1792 | |
| 1793 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1794 | 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] | 1795 | # Check whether --with-dl-dld or --without-dl-dld was given. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1796 | withval="$with_dl_dld" |
| 1797 | if test -n "$withval"; then |
| 1798 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1799 | echo "$ac_t""$withval" 1>&4 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1800 | cat >> confdefs.h <<\EOF |
| 1801 | #define WITH_DL_DLD 1 |
| 1802 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1803 | |
| 1804 | dldir=`echo "$withval" | sed 's/,.*//'` |
| 1805 | dlddir=`echo "$withval" | sed 's/.*,//'` |
| 1806 | if test -d "$dldir" -a -d "$dlddir" |
| 1807 | then LIBS="$LIBS -L$dldir -L$dlddir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1808 | 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] | 1809 | fi |
| 1810 | DLINCLDIR=${dldir} |
| 1811 | LIBS="$LIBS -ldl -ldld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1812 | else |
| 1813 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1814 | fi |
| 1815 | |
| 1816 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1817 | # checks for library functions |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1818 | 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] | 1819 | do |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1820 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&4 |
| 1821 | if eval "test \"`echo '${'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 1822 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1823 | else |
| 1824 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1825 | #line 1826 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1826 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1827 | #include <ctype.h> /* Arbitrary system header to define __stub macros. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1828 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1829 | int t() { |
| 1830 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1831 | /* The GNU C library defines this for functions which it implements |
| 1832 | to always fail with ENOSYS. Some functions are actually named |
| 1833 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1834 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1835 | choke me |
| 1836 | #else |
| 1837 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1838 | char $ac_func(); $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1839 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1840 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1841 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1842 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1843 | if eval $ac_link; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1844 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1845 | eval "ac_cv_func_$ac_func=yes" |
| 1846 | else |
| 1847 | rm -rf conftest* |
| 1848 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1849 | fi |
| 1850 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1851 | |
| 1852 | fi |
| 1853 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 1854 | echo "$ac_t""yes" 1>&4 |
| 1855 | ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'` |
| 1856 | cat >> confdefs.h <<EOF |
| 1857 | #define $ac_tr_func 1 |
| 1858 | EOF |
| 1859 | |
| 1860 | else |
| 1861 | echo "$ac_t""no" 1>&4 |
| 1862 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1863 | done |
| 1864 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1865 | for ac_func in dup2 getcwd strerror memmove |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1866 | do |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1867 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&4 |
| 1868 | if eval "test \"`echo '${'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 1869 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1870 | else |
| 1871 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1872 | #line 1873 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1873 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1874 | #include <ctype.h> /* Arbitrary system header to define __stub macros. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1875 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1876 | int t() { |
| 1877 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1878 | /* The GNU C library defines this for functions which it implements |
| 1879 | to always fail with ENOSYS. Some functions are actually named |
| 1880 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1881 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1882 | choke me |
| 1883 | #else |
| 1884 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1885 | char $ac_func(); $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1886 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1887 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1888 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1889 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1890 | if eval $ac_link; then |
| 1891 | rm -rf conftest* |
| 1892 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1893 | else |
| 1894 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1895 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1896 | fi |
| 1897 | rm -f conftest* |
| 1898 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1899 | fi |
| 1900 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 1901 | echo "$ac_t""yes" 1>&4 |
| 1902 | : |
| 1903 | else |
| 1904 | echo "$ac_t""no" 1>&4 |
| 1905 | LIBOBJS="$LIBOBJS ${ac_func}.o" |
| 1906 | fi |
| 1907 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1908 | done |
| 1909 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1910 | echo $ac_n "checking for getpgrp""... $ac_c" 1>&4 |
| 1911 | if eval "test \"`echo '${'ac_cv_func_getpgrp'+set}'`\" = set"; then |
| 1912 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1913 | else |
| 1914 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1915 | #line 1916 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1916 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1917 | #include <ctype.h> /* Arbitrary system header to define __stub macros. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1918 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1919 | int t() { |
| 1920 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1921 | /* The GNU C library defines this for functions which it implements |
| 1922 | to always fail with ENOSYS. Some functions are actually named |
| 1923 | something starting with __ and the normal name is an alias. */ |
| 1924 | #if defined (__stub_getpgrp) || defined (__stub___getpgrp) |
| 1925 | choke me |
| 1926 | #else |
| 1927 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1928 | char getpgrp(); getpgrp(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1929 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1930 | |
| 1931 | ; return 0; } |
| 1932 | EOF |
| 1933 | if eval $ac_link; then |
| 1934 | rm -rf conftest* |
| 1935 | eval "ac_cv_func_getpgrp=yes" |
| 1936 | else |
| 1937 | rm -rf conftest* |
| 1938 | eval "ac_cv_func_getpgrp=no" |
| 1939 | fi |
| 1940 | rm -f conftest* |
| 1941 | |
| 1942 | fi |
| 1943 | if eval "test \"`echo '$ac_cv_func_'getpgrp`\" = yes"; then |
| 1944 | echo "$ac_t""yes" 1>&4 |
| 1945 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1946 | #line 1947 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1947 | #include "confdefs.h" |
| 1948 | #include <unistd.h> |
| 1949 | int main() { return 0; } |
| 1950 | int t() { |
| 1951 | getpgrp(0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1952 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1953 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1954 | if eval $ac_compile; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1955 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1956 | cat >> confdefs.h <<\EOF |
| 1957 | #define GETPGRP_HAVE_ARG 1 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1958 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1959 | |
| 1960 | fi |
| 1961 | rm -f conftest* |
| 1962 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1963 | else |
| 1964 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1965 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1966 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1967 | echo $ac_n "checking for setpgrp""... $ac_c" 1>&4 |
| 1968 | if eval "test \"`echo '${'ac_cv_func_setpgrp'+set}'`\" = set"; then |
| 1969 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 1970 | else |
| 1971 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 1972 | #line 1973 "configure" |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 1973 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1974 | #include <ctype.h> /* Arbitrary system header to define __stub macros. */ |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 1975 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1976 | int t() { |
| 1977 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 1978 | /* The GNU C library defines this for functions which it implements |
| 1979 | to always fail with ENOSYS. Some functions are actually named |
| 1980 | something starting with __ and the normal name is an alias. */ |
| 1981 | #if defined (__stub_setpgrp) || defined (__stub___setpgrp) |
| 1982 | choke me |
| 1983 | #else |
| 1984 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1985 | char setpgrp(); setpgrp(); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 1986 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1987 | |
| 1988 | ; return 0; } |
| 1989 | EOF |
| 1990 | if eval $ac_link; then |
| 1991 | rm -rf conftest* |
| 1992 | eval "ac_cv_func_setpgrp=yes" |
| 1993 | else |
| 1994 | rm -rf conftest* |
| 1995 | eval "ac_cv_func_setpgrp=no" |
| 1996 | fi |
| 1997 | rm -f conftest* |
| 1998 | |
| 1999 | fi |
| 2000 | if eval "test \"`echo '$ac_cv_func_'setpgrp`\" = yes"; then |
| 2001 | echo "$ac_t""yes" 1>&4 |
| 2002 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2003 | #line 2004 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2004 | #include "confdefs.h" |
| 2005 | #include <unistd.h> |
| 2006 | int main() { return 0; } |
| 2007 | int t() { |
| 2008 | setpgrp(0,0); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2009 | ; return 0; } |
| 2010 | EOF |
| 2011 | if eval $ac_compile; then |
| 2012 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2013 | cat >> confdefs.h <<\EOF |
| 2014 | #define SETPGRP_HAVE_ARG 1 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2015 | EOF |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2016 | |
| 2017 | fi |
| 2018 | rm -f conftest* |
| 2019 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2020 | else |
| 2021 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2022 | fi |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 2023 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2024 | echo $ac_n "checking for gettimeofday""... $ac_c" 1>&4 |
| 2025 | if eval "test \"`echo '${'ac_cv_func_gettimeofday'+set}'`\" = set"; then |
| 2026 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 2027 | else |
| 2028 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2029 | #line 2030 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2030 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2031 | #include <ctype.h> /* Arbitrary system header to define __stub macros. */ |
| 2032 | int main() { return 0; } |
| 2033 | int t() { |
| 2034 | |
| 2035 | /* The GNU C library defines this for functions which it implements |
| 2036 | to always fail with ENOSYS. Some functions are actually named |
| 2037 | something starting with __ and the normal name is an alias. */ |
| 2038 | #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday) |
| 2039 | choke me |
| 2040 | #else |
| 2041 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2042 | char gettimeofday(); gettimeofday(); |
| 2043 | #endif |
| 2044 | |
| 2045 | ; return 0; } |
| 2046 | EOF |
| 2047 | if eval $ac_link; then |
| 2048 | rm -rf conftest* |
| 2049 | eval "ac_cv_func_gettimeofday=yes" |
| 2050 | else |
| 2051 | rm -rf conftest* |
| 2052 | eval "ac_cv_func_gettimeofday=no" |
| 2053 | fi |
| 2054 | rm -f conftest* |
| 2055 | |
| 2056 | fi |
| 2057 | if eval "test \"`echo '$ac_cv_func_'gettimeofday`\" = yes"; then |
| 2058 | echo "$ac_t""yes" 1>&4 |
| 2059 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2060 | #line 2061 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2061 | #include "confdefs.h" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2062 | #include <sys/time.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2063 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2064 | int t() { |
| 2065 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
| 2066 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2067 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2068 | if eval $ac_compile; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2069 | : |
| 2070 | else |
| 2071 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2072 | cat >> confdefs.h <<\EOF |
| 2073 | #define GETTIMEOFDAY_NO_TZ 1 |
| 2074 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2075 | |
| 2076 | fi |
| 2077 | rm -f conftest* |
| 2078 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2079 | else |
| 2080 | echo "$ac_t""no" 1>&4 |
| 2081 | fi |
| 2082 | |
| 2083 | |
| 2084 | # checks for structures |
| 2085 | echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&4 |
| 2086 | if eval "test \"`echo '${'ac_cv_header_time'+set}'`\" = set"; then |
| 2087 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 2088 | else |
| 2089 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2090 | #line 2091 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2091 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2092 | #include <sys/types.h> |
| 2093 | #include <sys/time.h> |
| 2094 | #include <time.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2095 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2096 | int t() { |
| 2097 | struct tm *tp; |
| 2098 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2099 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2100 | if eval $ac_compile; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2101 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2102 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2103 | else |
| 2104 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2105 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2106 | fi |
| 2107 | rm -f conftest* |
| 2108 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2109 | fi |
| 2110 | echo "$ac_t""$ac_cv_header_time" 1>&4 |
| 2111 | if test $ac_cv_header_time = yes; then |
| 2112 | cat >> confdefs.h <<\EOF |
| 2113 | #define TIME_WITH_SYS_TIME 1 |
| 2114 | EOF |
| 2115 | |
| 2116 | fi |
| 2117 | |
| 2118 | echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&4 |
| 2119 | if eval "test \"`echo '${'ac_cv_struct_tm'+set}'`\" = set"; then |
| 2120 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 2121 | else |
| 2122 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2123 | #line 2124 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2124 | #include "confdefs.h" |
| 2125 | #include <sys/types.h> |
| 2126 | #include <time.h> |
| 2127 | int main() { return 0; } |
| 2128 | int t() { |
| 2129 | struct tm *tp; tp->tm_sec; |
| 2130 | ; return 0; } |
| 2131 | EOF |
| 2132 | if eval $ac_compile; then |
| 2133 | rm -rf conftest* |
| 2134 | ac_cv_struct_tm=time.h |
| 2135 | else |
| 2136 | rm -rf conftest* |
| 2137 | ac_cv_struct_tm=sys/time.h |
| 2138 | fi |
| 2139 | rm -f conftest* |
| 2140 | |
| 2141 | fi |
| 2142 | echo "$ac_t""$ac_cv_struct_tm" 1>&4 |
| 2143 | if test $ac_cv_struct_tm = sys/time.h; then |
| 2144 | cat >> confdefs.h <<\EOF |
| 2145 | #define TM_IN_SYS_TIME 1 |
| 2146 | EOF |
| 2147 | |
| 2148 | fi |
| 2149 | |
| 2150 | echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&4 |
| 2151 | if eval "test \"`echo '${'ac_cv_struct_tm_zone'+set}'`\" = set"; then |
| 2152 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 2153 | else |
| 2154 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2155 | #line 2156 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2156 | #include "confdefs.h" |
| 2157 | #include <sys/types.h> |
| 2158 | #include <$ac_cv_struct_tm> |
| 2159 | int main() { return 0; } |
| 2160 | int t() { |
| 2161 | struct tm tm; tm.tm_zone; |
| 2162 | ; return 0; } |
| 2163 | EOF |
| 2164 | if eval $ac_compile; then |
| 2165 | rm -rf conftest* |
| 2166 | ac_cv_struct_tm_zone=yes |
| 2167 | else |
| 2168 | rm -rf conftest* |
| 2169 | ac_cv_struct_tm_zone=no |
| 2170 | fi |
| 2171 | rm -f conftest* |
| 2172 | |
| 2173 | fi |
| 2174 | echo "$ac_t""$ac_cv_struct_tm_zone" 1>&4 |
| 2175 | if test "$ac_cv_struct_tm_zone" = yes; then |
| 2176 | cat >> confdefs.h <<\EOF |
| 2177 | #define HAVE_TM_ZONE 1 |
| 2178 | EOF |
| 2179 | |
| 2180 | else |
| 2181 | echo $ac_n "checking for tzname""... $ac_c" 1>&4 |
| 2182 | if eval "test \"`echo '${'ac_cv_var_tzname'+set}'`\" = set"; then |
| 2183 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 2184 | else |
| 2185 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2186 | #line 2187 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2187 | #include "confdefs.h" |
| 2188 | #include <time.h> |
| 2189 | #ifndef tzname /* For SGI. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2190 | extern char *tzname[]; /* RS6000 and others reject char **tzname. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2191 | #endif |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2192 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2193 | int t() { |
| 2194 | atoi(*tzname); |
| 2195 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2196 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2197 | if eval $ac_link; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2198 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2199 | ac_cv_var_tzname=yes |
| 2200 | else |
| 2201 | rm -rf conftest* |
| 2202 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2203 | fi |
| 2204 | rm -f conftest* |
| 2205 | |
| 2206 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2207 | echo "$ac_t""$ac_cv_var_tzname" 1>&4 |
| 2208 | if test $ac_cv_var_tzname = yes; then |
| 2209 | cat >> confdefs.h <<\EOF |
| 2210 | #define HAVE_TZNAME 1 |
| 2211 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2212 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2213 | fi |
| 2214 | fi |
| 2215 | |
| 2216 | |
| 2217 | echo $ac_n "checking for time.h that defines altzone""... $ac_c" 1>&4 |
| 2218 | if eval "test \"`echo '${'ac_cv_header_time_altzone'+set}'`\" = set"; then |
| 2219 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 2220 | else |
| 2221 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2222 | #line 2223 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2223 | #include "confdefs.h" |
| 2224 | #include <time.h> |
| 2225 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2226 | int t() { |
| 2227 | return altzone; |
| 2228 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2229 | EOF |
| 2230 | if eval $ac_compile; then |
| 2231 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2232 | ac_cv_header_time_altzone=yes |
| 2233 | else |
| 2234 | rm -rf conftest* |
| 2235 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2236 | fi |
| 2237 | rm -f conftest* |
| 2238 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2239 | fi |
| 2240 | |
| 2241 | echo "$ac_t""$ac_cv_header_time_altzone" 1>&4 |
| 2242 | if test $ac_cv_header_time_altzone = yes; then |
| 2243 | cat >> confdefs.h <<\EOF |
| 2244 | #define HAVE_ALTZONE 1 |
| 2245 | EOF |
| 2246 | |
| 2247 | fi |
| 2248 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2249 | was_it_defined=no |
| 2250 | 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] | 2251 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2252 | #line 2253 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2253 | #include "confdefs.h" |
| 2254 | |
| 2255 | #include <sys/types.h> |
| 2256 | #include <sys/select.h> |
| 2257 | #include <sys/time.h> |
| 2258 | |
| 2259 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2260 | int t() { |
| 2261 | ; |
| 2262 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2263 | EOF |
| 2264 | if eval $ac_compile; then |
| 2265 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2266 | cat >> confdefs.h <<\EOF |
| 2267 | #define SYS_SELECT_WITH_SYS_TIME 1 |
| 2268 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2269 | was_it_defined=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2270 | fi |
| 2271 | rm -f conftest* |
| 2272 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2273 | echo "$ac_t""$was_it_defined" 1>&4 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2274 | |
| 2275 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2276 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2277 | echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&4 |
| 2278 | if eval "test \"`echo '${'ac_cv_c_char_unsigned'+set}'`\" = set"; then |
| 2279 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 2280 | else |
| 2281 | if test "$GCC" = yes; then |
| 2282 | # GCC predefines this symbol on systems where it applies. |
| 2283 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2284 | #line 2285 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2285 | #include "confdefs.h" |
| 2286 | #ifdef __CHAR_UNSIGNED__ |
| 2287 | yes |
| 2288 | #endif |
| 2289 | |
| 2290 | EOF |
| 2291 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 2292 | egrep "yes" >/dev/null 2>&1; then |
| 2293 | rm -rf conftest* |
| 2294 | ac_cv_c_char_unsigned=yes |
| 2295 | else |
| 2296 | rm -rf conftest* |
| 2297 | ac_cv_c_char_unsigned=no |
| 2298 | fi |
| 2299 | rm -f conftest* |
| 2300 | |
| 2301 | else |
| 2302 | if test "$cross_compiling" = yes; then |
| 2303 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2304 | else |
| 2305 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2306 | #line 2307 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2307 | #include "confdefs.h" |
| 2308 | /* volatile prevents gcc2 from optimizing the test away on sparcs. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2309 | #if !defined(__STDC__) || __STDC__ != 1 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2310 | #define volatile |
| 2311 | #endif |
| 2312 | main() { |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2313 | volatile char c = 255; exit(c < 0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2314 | } |
| 2315 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2316 | eval $ac_link |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2317 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2318 | ac_cv_c_char_unsigned=yes |
| 2319 | else |
| 2320 | ac_cv_c_char_unsigned=no |
| 2321 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2322 | fi |
| 2323 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2324 | fi |
| 2325 | fi |
| 2326 | echo "$ac_t""$ac_cv_c_char_unsigned" 1>&4 |
| 2327 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
| 2328 | cat >> confdefs.h <<\EOF |
| 2329 | #define __CHAR_UNSIGNED__ 1 |
| 2330 | EOF |
| 2331 | |
| 2332 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2333 | |
| 2334 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2335 | echo $ac_n "checking for working const""... $ac_c" 1>&4 |
| 2336 | if eval "test \"`echo '${'ac_cv_c_const'+set}'`\" = set"; then |
| 2337 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 2338 | else |
| 2339 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2340 | #line 2341 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2341 | #include "confdefs.h" |
| 2342 | |
| 2343 | int main() { return 0; } |
| 2344 | int t() { |
| 2345 | |
| 2346 | /* Ultrix mips cc rejects this. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2347 | typedef int charset[2]; const charset x; |
| 2348 | /* SunOS 4.1.1 cc rejects this. */ |
| 2349 | char const *const *ccp; |
| 2350 | char **p; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2351 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 2352 | struct point {int x, y;}; |
| 2353 | static struct point const zero; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2354 | /* AIX XL C 1.02.0.0 rejects this. |
| 2355 | It does not let you subtract one const X* pointer from another in an arm |
| 2356 | of an if-expression whose if-part is not a constant expression */ |
| 2357 | const char *g = "string"; |
| 2358 | ccp = &g + (g ? g-g : 0); |
| 2359 | /* HPUX 7.0 cc rejects these. */ |
| 2360 | ++ccp; |
| 2361 | p = (char**) ccp; |
| 2362 | ccp = (char const *const *) p; |
| 2363 | { /* SCO 3.2v4 cc rejects this. */ |
| 2364 | char *t; |
| 2365 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
| 2366 | |
| 2367 | *t++ = 0; |
| 2368 | } |
| 2369 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2370 | int x[] = {25, 17}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2371 | const int *foo = &x[0]; |
| 2372 | ++foo; |
| 2373 | } |
| 2374 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 2375 | typedef const int *iptr; |
| 2376 | iptr p = 0; |
| 2377 | ++p; |
| 2378 | } |
| 2379 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 2380 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 2381 | struct s { int j; const int *ap[3]; }; |
| 2382 | struct s *b; b->j = 5; |
| 2383 | } |
| 2384 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 2385 | const int foo = 10; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2386 | } |
| 2387 | |
| 2388 | ; return 0; } |
| 2389 | EOF |
| 2390 | if eval $ac_compile; then |
| 2391 | rm -rf conftest* |
| 2392 | ac_cv_c_const=yes |
| 2393 | else |
| 2394 | rm -rf conftest* |
| 2395 | ac_cv_c_const=no |
| 2396 | fi |
| 2397 | rm -f conftest* |
| 2398 | |
| 2399 | fi |
| 2400 | echo "$ac_t""$ac_cv_c_const" 1>&4 |
| 2401 | if test $ac_cv_c_const = no; then |
| 2402 | cat >> confdefs.h <<\EOF |
| 2403 | #define const |
| 2404 | EOF |
| 2405 | |
| 2406 | fi |
| 2407 | |
| 2408 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2409 | works=no |
| 2410 | echo $ac_n "checking for working volatile""... $ac_c" 1>&4 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2411 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2412 | #line 2413 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2413 | #include "confdefs.h" |
| 2414 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2415 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2416 | int t() { |
| 2417 | volatile int x; x = 0; |
| 2418 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2419 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2420 | if eval $ac_compile; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2421 | rm -rf conftest* |
| 2422 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2423 | else |
| 2424 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2425 | cat >> confdefs.h <<\EOF |
| 2426 | #define volatile |
| 2427 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2428 | |
| 2429 | fi |
| 2430 | rm -f conftest* |
| 2431 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2432 | echo "$ac_t""$works" 1>&4 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2433 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2434 | works=no |
| 2435 | 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] | 2436 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2437 | #line 2438 "configure" |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 2438 | #include "confdefs.h" |
| 2439 | |
| 2440 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2441 | int t() { |
| 2442 | signed char c; |
| 2443 | ; return 0; } |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 2444 | EOF |
| 2445 | if eval $ac_compile; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2446 | rm -rf conftest* |
| 2447 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 2448 | else |
| 2449 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2450 | cat >> confdefs.h <<\EOF |
| 2451 | #define signed |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2452 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2453 | |
| 2454 | fi |
| 2455 | rm -f conftest* |
| 2456 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2457 | echo "$ac_t""$works" 1>&4 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2458 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2459 | have_prototypes=no |
| 2460 | echo $ac_n "checking for prototypes""... $ac_c" 1>&4 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2461 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2462 | #line 2463 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2463 | #include "confdefs.h" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2464 | int foo(int x) { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2465 | int main() { return 0; } |
| 2466 | int t() { |
| 2467 | return foo(10); |
| 2468 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2469 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2470 | if eval $ac_compile; then |
| 2471 | rm -rf conftest* |
| 2472 | cat >> confdefs.h <<\EOF |
| 2473 | #define HAVE_PROTOTYPES 1 |
| 2474 | EOF |
| 2475 | have_prototypes=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2476 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2477 | rm -f conftest* |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2478 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2479 | echo "$ac_t""$have_prototypes" 1>&4 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2480 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2481 | works=no |
| 2482 | 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] | 2483 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2484 | #line 2485 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2485 | #include "confdefs.h" |
| 2486 | |
| 2487 | #include <stdarg.h> |
| 2488 | int foo(int x, ...) { return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2489 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2490 | int main() { return 0; } |
| 2491 | int t() { |
| 2492 | return foo(10, 11, 12); |
| 2493 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2494 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2495 | if eval $ac_compile; then |
| 2496 | rm -rf conftest* |
| 2497 | cat >> confdefs.h <<\EOF |
| 2498 | #define HAVE_STDARG_PROTOTYPES 1 |
| 2499 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2500 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2501 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2502 | rm -f conftest* |
| 2503 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2504 | echo "$ac_t""$works" 1>&4 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2505 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2506 | if test "$have_prototypes" = yes; then |
| 2507 | bad_prototypes=no |
| 2508 | 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] | 2509 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2510 | #line 2511 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2511 | #include "confdefs.h" |
| 2512 | #include <unistd.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2513 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2514 | int t() { |
| 2515 | char **t;execve("@",t,t); |
| 2516 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2517 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2518 | if eval $ac_compile; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2519 | : |
| 2520 | else |
| 2521 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2522 | cat >> confdefs.h <<\EOF |
| 2523 | #define BAD_EXEC_PROTOTYPES 1 |
| 2524 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2525 | bad_prototypes=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2526 | fi |
| 2527 | rm -f conftest* |
| 2528 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2529 | echo "$ac_t""$bad_prototypes" 1>&4 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2530 | fi |
| 2531 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2532 | bad_forward=no |
| 2533 | 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] | 2534 | if test "$cross_compiling" = yes; then |
| 2535 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2536 | else |
| 2537 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2538 | #line 2539 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2539 | #include "confdefs.h" |
| 2540 | |
| 2541 | struct s { int a; int b; }; |
| 2542 | static struct s foo; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2543 | int foobar() { |
| 2544 | static int random; |
| 2545 | random = (int) &foo; |
| 2546 | return random; |
| 2547 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2548 | static struct s foo = { 1, 2 }; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2549 | main() { |
| 2550 | exit(!((int)&foo == foobar())); |
| 2551 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2552 | |
| 2553 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2554 | eval $ac_link |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2555 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
| 2556 | : |
| 2557 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2558 | cat >> confdefs.h <<\EOF |
| 2559 | #define BAD_STATIC_FORWARD 1 |
| 2560 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2561 | bad_forward=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2562 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2563 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2564 | rm -fr conftest* |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2565 | echo "$ac_t""$bad_forward" 1>&4 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2566 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2567 | va_list_is_array=no |
| 2568 | 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] | 2569 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2570 | #line 2571 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2571 | #include "confdefs.h" |
| 2572 | |
| 2573 | #ifdef HAVE_STDARG_PROTOTYPES |
| 2574 | #include <stdarg.h> |
| 2575 | #else |
| 2576 | #include <varargs.h> |
| 2577 | #endif |
| 2578 | |
| 2579 | int main() { return 0; } |
| 2580 | int t() { |
| 2581 | va_list list1, list2; list1 = list2; |
| 2582 | ; return 0; } |
| 2583 | EOF |
| 2584 | if eval $ac_compile; then |
| 2585 | : |
| 2586 | else |
| 2587 | rm -rf conftest* |
| 2588 | cat >> confdefs.h <<\EOF |
| 2589 | #define VA_LIST_IS_ARRAY 1 |
| 2590 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2591 | va_list_is_array=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2592 | fi |
| 2593 | rm -f conftest* |
| 2594 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2595 | echo "$ac_t""$va_list_is_array" 1>&4 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2596 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2597 | # checks for system services |
| 2598 | # (none yet) |
| 2599 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2600 | # Linux requires this for correct f.p. operations |
| 2601 | echo $ac_n "checking for -lieee""... $ac_c" 1>&4 |
| 2602 | if eval "test \"`echo '${'ac_cv_lib_ieee'+set}'`\" = set"; then |
| 2603 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 2604 | else |
| 2605 | ac_save_LIBS="$LIBS" |
| 2606 | LIBS="$LIBS -lieee " |
| 2607 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2608 | #line 2609 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2609 | #include "confdefs.h" |
| 2610 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2611 | int main() { return 0; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2612 | int t() { |
| 2613 | __fpu_control() |
| 2614 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2615 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2616 | if eval $ac_link; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2617 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2618 | eval "ac_cv_lib_ieee=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2619 | else |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2620 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2621 | eval "ac_cv_lib_ieee=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2622 | fi |
| 2623 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2624 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2625 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2626 | fi |
| 2627 | if eval "test \"`echo '$ac_cv_lib_'ieee`\" = yes"; then |
| 2628 | echo "$ac_t""yes" 1>&4 |
| 2629 | ac_tr_lib=HAVE_LIB`echo ieee | tr '[a-z]' '[A-Z]'` |
| 2630 | cat >> confdefs.h <<EOF |
| 2631 | #define $ac_tr_lib 1 |
| 2632 | EOF |
| 2633 | |
| 2634 | LIBS="$LIBS -lieee" |
| 2635 | |
| 2636 | else |
| 2637 | echo "$ac_t""no" 1>&4 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2638 | fi |
| 2639 | |
| 2640 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2641 | # check for --with-libm=... |
| 2642 | |
| 2643 | LIBM=-lm |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2644 | # Check whether --with-libm or --without-libm was given. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2645 | withval="$with_libm" |
| 2646 | if test -n "$withval"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2647 | |
| 2648 | if test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2649 | then LIBM=$withval |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2650 | 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] | 2651 | fi |
| 2652 | fi |
| 2653 | |
| 2654 | |
| 2655 | # check for --with-libc=... |
| 2656 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2657 | # Check whether --with-libc or --without-libc was given. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2658 | withval="$with_libc" |
| 2659 | if test -n "$withval"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2660 | |
| 2661 | if test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2662 | then LIBC=$withval |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2663 | 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] | 2664 | fi |
| 2665 | fi |
| 2666 | |
| 2667 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 2668 | # check for hypot() in math library |
| 2669 | LIBS_SAVE=$LIBS |
| 2670 | LIBS="$LIBS $LIBM" |
| 2671 | for ac_func in hypot |
| 2672 | do |
| 2673 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&4 |
| 2674 | if eval "test \"`echo '${'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 2675 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 2676 | else |
| 2677 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2678 | #line 2679 "configure" |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 2679 | #include "confdefs.h" |
| 2680 | #include <ctype.h> /* Arbitrary system header to define __stub macros. */ |
| 2681 | int main() { return 0; } |
| 2682 | int t() { |
| 2683 | |
| 2684 | /* The GNU C library defines this for functions which it implements |
| 2685 | to always fail with ENOSYS. Some functions are actually named |
| 2686 | something starting with __ and the normal name is an alias. */ |
| 2687 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 2688 | choke me |
| 2689 | #else |
| 2690 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2691 | char $ac_func(); $ac_func(); |
| 2692 | #endif |
| 2693 | |
| 2694 | ; return 0; } |
| 2695 | EOF |
| 2696 | if eval $ac_link; then |
| 2697 | rm -rf conftest* |
| 2698 | eval "ac_cv_func_$ac_func=yes" |
| 2699 | else |
| 2700 | rm -rf conftest* |
| 2701 | eval "ac_cv_func_$ac_func=no" |
| 2702 | fi |
| 2703 | rm -f conftest* |
| 2704 | |
| 2705 | fi |
| 2706 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 2707 | echo "$ac_t""yes" 1>&4 |
| 2708 | ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'` |
| 2709 | cat >> confdefs.h <<EOF |
| 2710 | #define $ac_tr_func 1 |
| 2711 | EOF |
| 2712 | |
| 2713 | else |
| 2714 | echo "$ac_t""no" 1>&4 |
| 2715 | fi |
| 2716 | done |
| 2717 | |
| 2718 | LIBS=$LIBS_SAVE |
| 2719 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2720 | # check for getopt |
| 2721 | echo $ac_n "checking for genuine getopt""... $ac_c" 1>&4 |
| 2722 | if eval "test \"`echo '${'ac_cv_func_getopt'+set}'`\" = set"; then |
| 2723 | echo $ac_n "(cached) $ac_c" 1>&4 |
| 2724 | else |
| 2725 | if test "$cross_compiling" = yes; then |
| 2726 | ac_cv_func_getopt=no |
| 2727 | else |
| 2728 | cat > conftest.$ac_ext <<EOF |
| 2729 | #line 2730 "configure" |
| 2730 | #include "confdefs.h" |
| 2731 | #include <stdio.h> |
| 2732 | extern int optind, opterr, getopt(); |
| 2733 | extern char* optarg; |
| 2734 | int main() { |
| 2735 | char* av[] = { "testprog", "parameter", "-fFlag", NULL }; |
| 2736 | opterr = 0; |
| 2737 | if (getopt(3, av, "f:") == 'f') { exit(1); } |
| 2738 | exit(0); |
| 2739 | } |
| 2740 | EOF |
| 2741 | eval $ac_link |
| 2742 | if test -s conftest && (./conftest; exit) 2>/dev/null; then |
| 2743 | ac_cv_func_getopt=yes |
| 2744 | else |
| 2745 | ac_cv_func_getopt=no |
| 2746 | fi |
| 2747 | fi |
| 2748 | rm -fr conftest* |
| 2749 | fi |
| 2750 | echo "$ac_t""$ac_cv_func_getopt" 1>&4 |
| 2751 | test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o" |
| 2752 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2753 | # generate output files |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2754 | trap '' 1 2 15 |
| 2755 | if test -w $cache_file; then |
| 2756 | echo "updating cache $cache_file" |
| 2757 | cat > $cache_file <<\EOF |
| 2758 | # This file is a shell script that caches the results of configure |
| 2759 | # tests run on this system so they can be shared between configure |
| 2760 | # scripts and configure runs. It is not useful on other systems. |
| 2761 | # If it contains results you don't want to keep, you may remove or edit it. |
| 2762 | # |
| 2763 | # By default, configure uses ./config.cache as the cache file, |
| 2764 | # creating it if it does not exist already. You can give configure |
| 2765 | # the --cache-file=FILE option to use a different cache file; that is |
| 2766 | # what configure does when it calls configure scripts in |
| 2767 | # subdirectories, so they share the cache. |
| 2768 | # Giving --cache-file=/dev/null disables caching, for debugging configure. |
| 2769 | # config.status only pays attention to the cache file if you give it the |
| 2770 | # --recheck option to rerun configure. |
| 2771 | # |
| 2772 | EOF |
| 2773 | # Ultrix sh set writes to stderr and can't be redirected directly. |
| 2774 | (set) 2>&1 | |
| 2775 | sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/: \${\1='\2'}/p" \ |
| 2776 | >> $cache_file |
| 2777 | else |
| 2778 | echo "not updating unwritable cache $cache_file" |
| 2779 | fi |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2780 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2781 | trap 'rm -fr conftest* confdefs* core $ac_clean_files; exit 1' 1 2 15 |
| 2782 | |
| 2783 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 2784 | # Let make expand exec_prefix. |
| 2785 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2786 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2787 | # Any assignment to VPATH causes Sun make to only execute |
| 2788 | # the first set of double-colon rules, so remove it if not needed. |
| 2789 | # If there is a colon in the path, we need to keep it. |
| 2790 | if test "x$srcdir" = x.; then |
| 2791 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
| 2792 | fi |
| 2793 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2794 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2795 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2796 | DEFS=-DHAVE_CONFIG_H |
| 2797 | |
| 2798 | # Without the "./", some shells look in PATH for config.status. |
| 2799 | : ${CONFIG_STATUS=./config.status} |
| 2800 | |
| 2801 | echo creating $CONFIG_STATUS |
| 2802 | rm -f $CONFIG_STATUS |
| 2803 | cat > $CONFIG_STATUS <<EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2804 | #!/bin/sh |
| 2805 | # Generated automatically by configure. |
| 2806 | # Run this file to recreate the current configuration. |
| 2807 | # This directory was configured as follows, |
| 2808 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
| 2809 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2810 | # $0 $ac_configure_args |
| 2811 | # |
| 2812 | # Compiler output produced by configure, useful for debugging |
| 2813 | # configure, is in ./config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2814 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2815 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2816 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2817 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2818 | case "\$ac_option" in |
| 2819 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2820 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
| 2821 | 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] | 2822 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2823 | echo "$CONFIG_STATUS generated by autoconf version 2.0" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2824 | exit 0 ;; |
| 2825 | -help | --help | --hel | --he | --h) |
| 2826 | echo "\$ac_cs_usage"; exit 0 ;; |
| 2827 | *) echo "\$ac_cs_usage"; exit 1 ;; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2828 | esac |
| 2829 | done |
| 2830 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2831 | ac_given_srcdir=$srcdir |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2832 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2833 | 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] | 2834 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2835 | # Protect against being on the right side of a sed subst in config.status. |
| 2836 | sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g; |
| 2837 | s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2838 | $ac_vpsub |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2839 | $extrasub |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2840 | s%@CFLAGS@%$CFLAGS%g |
| 2841 | s%@CPPFLAGS@%$CPPFLAGS%g |
| 2842 | s%@CXXFLAGS@%$CXXFLAGS%g |
| 2843 | s%@DEFS@%$DEFS%g |
| 2844 | s%@LDFLAGS@%$LDFLAGS%g |
| 2845 | s%@LIBS@%$LIBS%g |
| 2846 | s%@exec_prefix@%$exec_prefix%g |
| 2847 | s%@prefix@%$prefix%g |
| 2848 | s%@program_transform_name@%$program_transform_name%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2849 | s%@CC@%$CC%g |
| 2850 | s%@RANLIB@%$RANLIB%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2851 | s%@AR@%$AR%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 2852 | s%@INSTALL@%$INSTALL%g |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame^] | 2853 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
| 2854 | s%@INSTALL_DATA@%$INSTALL_DATA%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 2855 | s%@OPT@%$OPT%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2856 | s%@CPP@%$CPP%g |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2857 | s%@MACHDEP@%$MACHDEP%g |
| 2858 | s%@SO@%$SO%g |
| 2859 | s%@LDSHARED@%$LDSHARED%g |
| 2860 | s%@CCSHARED@%$CCSHARED%g |
| 2861 | s%@LINKFORSHARED@%$LINKFORSHARED%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2862 | s%@DLINCLDIR@%$DLINCLDIR%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2863 | s%@LIBOBJS@%$LIBOBJS%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2864 | s%@LIBM@%$LIBM%g |
| 2865 | s%@LIBC@%$LIBC%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2866 | |
| 2867 | CEOF |
| 2868 | EOF |
| 2869 | cat >> $CONFIG_STATUS <<EOF |
| 2870 | |
| 2871 | CONFIG_FILES=\${CONFIG_FILES-"Makefile Objects/Makefile Parser/Makefile Python/Makefile Modules/Makefile.pre"} |
| 2872 | EOF |
| 2873 | cat >> $CONFIG_STATUS <<\EOF |
| 2874 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then |
| 2875 | # Support "outfile[:infile]", defaulting infile="outfile.in". |
| 2876 | case "$ac_file" in |
| 2877 | *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'` |
| 2878 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 2879 | *) ac_file_in="${ac_file}.in" ;; |
| 2880 | esac |
| 2881 | |
| 2882 | # Adjust relative srcdir, etc. for subdirectories. |
| 2883 | |
| 2884 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 2885 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 2886 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 2887 | # The file is in a subdirectory. |
| 2888 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
| 2889 | ac_dir_suffix="/$ac_dir" |
| 2890 | # A "../" for each directory in $ac_dir_suffix. |
| 2891 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
| 2892 | else |
| 2893 | ac_dir_suffix= ac_dots= |
| 2894 | fi |
| 2895 | |
| 2896 | case "$ac_given_srcdir" in |
| 2897 | .) srcdir=. |
| 2898 | if test -z "$ac_dots"; then top_srcdir=. |
| 2899 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; |
| 2900 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; |
| 2901 | *) # Relative path. |
| 2902 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
| 2903 | top_srcdir="$ac_dots$ac_given_srcdir" ;; |
| 2904 | esac |
| 2905 | |
| 2906 | echo creating "$ac_file" |
| 2907 | rm -f "$ac_file" |
| 2908 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." |
| 2909 | case "$ac_file" in |
| 2910 | *Makefile*) ac_comsub="1i\\ |
| 2911 | # $configure_input" ;; |
| 2912 | *) ac_comsub= ;; |
| 2913 | esac |
| 2914 | sed -e "$ac_comsub |
| 2915 | s%@configure_input@%$configure_input%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2916 | s%@srcdir@%$srcdir%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2917 | s%@top_srcdir@%$top_srcdir%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2918 | " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2919 | fi; done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2920 | rm -f conftest.subs |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2921 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2922 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
| 2923 | # 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] | 2924 | # |
| 2925 | # ac_d sets the value in "#define NAME VALUE" lines. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2926 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
| 2927 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2928 | ac_dC='\3' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2929 | ac_dD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2930 | # 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] | 2931 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 2932 | ac_uB='\([ ]\)%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2933 | ac_uC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2934 | ac_uD='\4%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2935 | # 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] | 2936 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 2937 | ac_eB='$%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2938 | ac_eC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2939 | ac_eD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2940 | |
| 2941 | CONFIG_HEADERS=${CONFIG_HEADERS-"config.h"} |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2942 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then |
| 2943 | # Support "outfile[:infile]", defaulting infile="outfile.in". |
| 2944 | case "$ac_file" in |
| 2945 | *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'` |
| 2946 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 2947 | *) ac_file_in="${ac_file}.in" ;; |
| 2948 | esac |
| 2949 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2950 | echo creating $ac_file |
| 2951 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2952 | rm -f conftest.frag conftest.in conftest.out |
| 2953 | cp $ac_given_srcdir/$ac_file_in conftest.in |
| 2954 | |
| 2955 | EOF |
| 2956 | |
| 2957 | # Transform confdefs.h into a sed script conftest.vals that substitutes |
| 2958 | # the proper values into config.h.in to produce config.h. And first: |
| 2959 | # Protect against being on the right side of a sed subst in config.status. |
| 2960 | # Protect against being in an unquoted here document in config.status. |
| 2961 | rm -f conftest.vals |
| 2962 | cat > conftest.hdr <<\EOF |
| 2963 | s/[\\&%]/\\&/g |
| 2964 | s%[\\$`]%\\&%g |
| 2965 | s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp |
| 2966 | s%ac_d%ac_u%gp |
| 2967 | s%ac_u%ac_e%gp |
| 2968 | EOF |
| 2969 | sed -n -f conftest.hdr confdefs.h > conftest.vals |
| 2970 | rm -f conftest.hdr |
| 2971 | |
| 2972 | # This sed command replaces #undef with comments. This is necessary, for |
| 2973 | # example, in the case of _POSIX_SOURCE, which is predefined and required |
| 2974 | # on some systems where configure will not decide to define it. |
| 2975 | cat >> conftest.vals <<\EOF |
| 2976 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% |
| 2977 | EOF |
| 2978 | |
| 2979 | # Break up conftest.vals because some shells have a limit on |
| 2980 | # the size of here documents, and old seds have small limits too. |
| 2981 | # Maximum number of lines to put in a single here document. |
| 2982 | ac_max_here_lines=12 |
| 2983 | |
| 2984 | rm -f conftest.tail |
| 2985 | while : |
| 2986 | do |
| 2987 | ac_lines=`grep -c . conftest.vals` |
| 2988 | # grep -c gives empty output for an empty file on some AIX systems. |
| 2989 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi |
| 2990 | # Write a limited-size here document to conftest.frag. |
| 2991 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS |
| 2992 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS |
| 2993 | echo 'CEOF |
| 2994 | sed -f conftest.frag conftest.in > conftest.out |
| 2995 | rm -f conftest.in |
| 2996 | mv conftest.out conftest.in |
| 2997 | ' >> $CONFIG_STATUS |
| 2998 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
| 2999 | rm -f conftest.vals |
| 3000 | mv conftest.tail conftest.vals |
| 3001 | done |
| 3002 | rm -f conftest.vals |
| 3003 | |
| 3004 | cat >> $CONFIG_STATUS <<\EOF |
| 3005 | rm -f conftest.frag conftest.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3006 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3007 | cat conftest.in >> conftest.h |
| 3008 | rm -f conftest.in |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3009 | if cmp -s $ac_file conftest.h 2>/dev/null; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3010 | echo "$ac_file is unchanged" |
| 3011 | rm -f conftest.h |
| 3012 | else |
| 3013 | rm -f $ac_file |
| 3014 | mv conftest.h $ac_file |
| 3015 | fi |
| 3016 | fi; done |
| 3017 | |
| 3018 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3019 | |
| 3020 | exit 0 |
| 3021 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3022 | chmod +x $CONFIG_STATUS |
| 3023 | rm -fr confdefs* $ac_clean_files |
| 3024 | test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3025 | |