Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1 | #! /bin/sh |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2 | |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3 | # From configure.in Revision: 1.200 |
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 | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6 | # Generated automatically using autoconf version 2.13 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 7 | # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8 | # |
| 9 | # This configure script is free software; the Free Software Foundation |
| 10 | # gives unlimited permission to copy, distribute and modify it. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12 | # Defaults: |
| 13 | ac_help= |
| 14 | ac_default_prefix=/usr/local |
| 15 | # Any additions from configure.in: |
| 16 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 17 | --with-next-archs='arch1 arch2 ..' build MAB binary" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 18 | ac_help="$ac_help |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 19 | --with-next-framework Build (OpenStep|Rhapsody|MacOSX|Darwin) framework" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 20 | ac_help="$ac_help |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 21 | --with-dyld Use (OpenStep|Rhapsody|MacOSX|Darwin) dynamic linker" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 22 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 23 | --without-gcc never use gcc" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 24 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 25 | --with-cxx=<compiler> enable C++ support" |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 26 | ac_help="$ac_help |
Neil Schemenauer | dfb38e4 | 2001-01-27 06:57:08 +0000 | [diff] [blame] | 27 | --with-suffix=.exe set executable suffix" |
| 28 | ac_help="$ac_help |
Skip Montanaro | cb85326 | 2000-08-30 22:29:48 +0000 | [diff] [blame] | 29 | --with-pydebug build with Py_DEBUG defined" |
| 30 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 31 | --with-libs='lib1 ...' link against additional libs" |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 32 | ac_help="$ac_help |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 33 | --with-signal-module disable/enable signal module" |
| 34 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 35 | --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries" |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 36 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 37 | --with(out)-threads[=DIRECTORY] disable/enable thread support" |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 38 | ac_help="$ac_help |
Barry Warsaw | a0f3c5c | 2000-06-30 16:39:35 +0000 | [diff] [blame] | 39 | --with(out)-thread[=DIRECTORY] deprecated; use --with(out)-threads" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 40 | ac_help="$ac_help |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 41 | --with-pth use GNU pth threading libraries" |
| 42 | ac_help="$ac_help |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 43 | --with(out)-cycle-gc disable/enable garbage collection" |
| 44 | ac_help="$ac_help |
Barry Warsaw | a57b89b | 2001-01-15 17:07:21 +0000 | [diff] [blame] | 45 | --with(out)-dbm disable/enable dbm module" |
| 46 | ac_help="$ac_help |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 47 | --with(out)-libdb disable/enable bsddb module" |
| 48 | ac_help="$ac_help |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 49 | --with-wctype-functions use wctype.h functions" |
| 50 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 51 | --with-sgi-dl=DIRECTORY IRIX 4 dynamic linking" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 52 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 53 | --with-dl-dld=DL_DIR,DLD_DIR GNU dynamic linking" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 54 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 55 | --with-fpectl enable SIGFPE catching" |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 56 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 57 | --with-libm=STRING math library" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 58 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 59 | --with-libc=STRING C library" |
Guido van Rossum | 4c3f57c | 2001-01-10 20:40:46 +0000 | [diff] [blame] | 60 | ac_help="$ac_help |
| 61 | --with-check-import-case enable imported module name case checking" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 62 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 63 | # Initialize some variables set by options. |
| 64 | # The variables have the same names as the options, with |
| 65 | # dashes changed to underlines. |
| 66 | build=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 67 | cache_file=./config.cache |
| 68 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 69 | host=NONE |
| 70 | no_create= |
| 71 | nonopt=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 72 | no_recursion= |
| 73 | prefix=NONE |
| 74 | program_prefix=NONE |
| 75 | program_suffix=NONE |
| 76 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 77 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 78 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 79 | srcdir= |
| 80 | target=NONE |
| 81 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 82 | x_includes=NONE |
| 83 | x_libraries=NONE |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 84 | bindir='${exec_prefix}/bin' |
| 85 | sbindir='${exec_prefix}/sbin' |
| 86 | libexecdir='${exec_prefix}/libexec' |
| 87 | datadir='${prefix}/share' |
| 88 | sysconfdir='${prefix}/etc' |
| 89 | sharedstatedir='${prefix}/com' |
| 90 | localstatedir='${prefix}/var' |
| 91 | libdir='${exec_prefix}/lib' |
| 92 | includedir='${prefix}/include' |
| 93 | oldincludedir='/usr/include' |
| 94 | infodir='${prefix}/info' |
| 95 | mandir='${prefix}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 96 | |
| 97 | # Initialize some other variables. |
| 98 | subdirs= |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 99 | MFLAGS= MAKEFLAGS= |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 100 | SHELL=${CONFIG_SHELL-/bin/sh} |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 101 | # Maximum number of lines to put in a shell here document. |
| 102 | ac_max_here_lines=12 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 103 | |
| 104 | ac_prev= |
| 105 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 106 | do |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 107 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 108 | # If the previous option needs an argument, assign it. |
| 109 | if test -n "$ac_prev"; then |
| 110 | eval "$ac_prev=\$ac_option" |
| 111 | ac_prev= |
| 112 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 113 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 114 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 115 | case "$ac_option" in |
| 116 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; |
| 117 | *) ac_optarg= ;; |
| 118 | esac |
| 119 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 120 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 121 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 122 | case "$ac_option" in |
| 123 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 124 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 125 | ac_prev=bindir ;; |
| 126 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
| 127 | bindir="$ac_optarg" ;; |
| 128 | |
| 129 | -build | --build | --buil | --bui | --bu) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 130 | ac_prev=build ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 131 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 132 | build="$ac_optarg" ;; |
| 133 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 134 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 135 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 136 | ac_prev=cache_file ;; |
| 137 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 138 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
| 139 | cache_file="$ac_optarg" ;; |
| 140 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 141 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
| 142 | ac_prev=datadir ;; |
| 143 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ |
| 144 | | --da=*) |
| 145 | datadir="$ac_optarg" ;; |
| 146 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 147 | -disable-* | --disable-*) |
| 148 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 149 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 150 | 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] | 151 | { 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] | 152 | fi |
| 153 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 154 | eval "enable_${ac_feature}=no" ;; |
| 155 | |
| 156 | -enable-* | --enable-*) |
| 157 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 158 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 159 | 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] | 160 | { 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] | 161 | fi |
| 162 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 163 | case "$ac_option" in |
| 164 | *=*) ;; |
| 165 | *) ac_optarg=yes ;; |
| 166 | esac |
| 167 | eval "enable_${ac_feature}='$ac_optarg'" ;; |
| 168 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 169 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 170 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 171 | | --exec | --exe | --ex) |
| 172 | ac_prev=exec_prefix ;; |
| 173 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 174 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 175 | | --exec=* | --exe=* | --ex=*) |
| 176 | exec_prefix="$ac_optarg" ;; |
| 177 | |
| 178 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 179 | # Obsolete; use --with-gas. |
| 180 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 181 | |
| 182 | -help | --help | --hel | --he) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 183 | # Omit some internal or obsolete options to make the list less imposing. |
| 184 | # This message is too long to be a string in the A/UX 3.1 sh. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 185 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 186 | Usage: configure [options] [host] |
| 187 | Options: [defaults in brackets after descriptions] |
| 188 | Configuration: |
| 189 | --cache-file=FILE cache test results in FILE |
| 190 | --help print this message |
| 191 | --no-create do not create output files |
| 192 | --quiet, --silent do not print \`checking...' messages |
| 193 | --version print the version of autoconf that created configure |
| 194 | Directory and file names: |
| 195 | --prefix=PREFIX install architecture-independent files in PREFIX |
| 196 | [$ac_default_prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 197 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 198 | [same as prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 199 | --bindir=DIR user executables in DIR [EPREFIX/bin] |
| 200 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] |
| 201 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] |
| 202 | --datadir=DIR read-only architecture-independent data in DIR |
| 203 | [PREFIX/share] |
| 204 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] |
| 205 | --sharedstatedir=DIR modifiable architecture-independent data in DIR |
| 206 | [PREFIX/com] |
| 207 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] |
| 208 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] |
| 209 | --includedir=DIR C header files in DIR [PREFIX/include] |
| 210 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] |
| 211 | --infodir=DIR info documentation in DIR [PREFIX/info] |
| 212 | --mandir=DIR man documentation in DIR [PREFIX/man] |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 213 | --srcdir=DIR find the sources in DIR [configure dir or ..] |
| 214 | --program-prefix=PREFIX prepend PREFIX to installed program names |
| 215 | --program-suffix=SUFFIX append SUFFIX to installed program names |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 216 | --program-transform-name=PROGRAM |
| 217 | run sed PROGRAM on installed program names |
| 218 | EOF |
| 219 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 220 | Host type: |
| 221 | --build=BUILD configure for building on BUILD [BUILD=HOST] |
| 222 | --host=HOST configure for HOST [guessed] |
| 223 | --target=TARGET configure for TARGET [TARGET=HOST] |
| 224 | Features and packages: |
| 225 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 226 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
| 227 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 228 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
| 229 | --x-includes=DIR X include files are in DIR |
| 230 | --x-libraries=DIR X library files are in DIR |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 231 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 232 | if test -n "$ac_help"; then |
| 233 | echo "--enable and --with options recognized:$ac_help" |
| 234 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 235 | exit 0 ;; |
| 236 | |
| 237 | -host | --host | --hos | --ho) |
| 238 | ac_prev=host ;; |
| 239 | -host=* | --host=* | --hos=* | --ho=*) |
| 240 | host="$ac_optarg" ;; |
| 241 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 242 | -includedir | --includedir | --includedi | --included | --include \ |
| 243 | | --includ | --inclu | --incl | --inc) |
| 244 | ac_prev=includedir ;; |
| 245 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 246 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
| 247 | includedir="$ac_optarg" ;; |
| 248 | |
| 249 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 250 | ac_prev=infodir ;; |
| 251 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
| 252 | infodir="$ac_optarg" ;; |
| 253 | |
| 254 | -libdir | --libdir | --libdi | --libd) |
| 255 | ac_prev=libdir ;; |
| 256 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
| 257 | libdir="$ac_optarg" ;; |
| 258 | |
| 259 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 260 | | --libexe | --libex | --libe) |
| 261 | ac_prev=libexecdir ;; |
| 262 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 263 | | --libexe=* | --libex=* | --libe=*) |
| 264 | libexecdir="$ac_optarg" ;; |
| 265 | |
| 266 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
| 267 | | --localstate | --localstat | --localsta | --localst \ |
| 268 | | --locals | --local | --loca | --loc | --lo) |
| 269 | ac_prev=localstatedir ;; |
| 270 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
| 271 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ |
| 272 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) |
| 273 | localstatedir="$ac_optarg" ;; |
| 274 | |
| 275 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 276 | ac_prev=mandir ;; |
| 277 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
| 278 | mandir="$ac_optarg" ;; |
| 279 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 280 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 281 | # Obsolete; use --without-fp. |
| 282 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 283 | |
| 284 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 285 | | --no-cr | --no-c) |
| 286 | no_create=yes ;; |
| 287 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 288 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 289 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 290 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 291 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 292 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 293 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 294 | | --oldin | --oldi | --old | --ol | --o) |
| 295 | ac_prev=oldincludedir ;; |
| 296 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 297 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 298 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
| 299 | oldincludedir="$ac_optarg" ;; |
| 300 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 301 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 302 | ac_prev=prefix ;; |
| 303 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
| 304 | prefix="$ac_optarg" ;; |
| 305 | |
| 306 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 307 | | --program-pre | --program-pr | --program-p) |
| 308 | ac_prev=program_prefix ;; |
| 309 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 310 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
| 311 | program_prefix="$ac_optarg" ;; |
| 312 | |
| 313 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 314 | | --program-suf | --program-su | --program-s) |
| 315 | ac_prev=program_suffix ;; |
| 316 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 317 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
| 318 | program_suffix="$ac_optarg" ;; |
| 319 | |
| 320 | -program-transform-name | --program-transform-name \ |
| 321 | | --program-transform-nam | --program-transform-na \ |
| 322 | | --program-transform-n | --program-transform- \ |
| 323 | | --program-transform | --program-transfor \ |
| 324 | | --program-transfo | --program-transf \ |
| 325 | | --program-trans | --program-tran \ |
| 326 | | --progr-tra | --program-tr | --program-t) |
| 327 | ac_prev=program_transform_name ;; |
| 328 | -program-transform-name=* | --program-transform-name=* \ |
| 329 | | --program-transform-nam=* | --program-transform-na=* \ |
| 330 | | --program-transform-n=* | --program-transform-=* \ |
| 331 | | --program-transform=* | --program-transfor=* \ |
| 332 | | --program-transfo=* | --program-transf=* \ |
| 333 | | --program-trans=* | --program-tran=* \ |
| 334 | | --progr-tra=* | --program-tr=* | --program-t=*) |
| 335 | program_transform_name="$ac_optarg" ;; |
| 336 | |
| 337 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 338 | | -silent | --silent | --silen | --sile | --sil) |
| 339 | silent=yes ;; |
| 340 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 341 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 342 | ac_prev=sbindir ;; |
| 343 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 344 | | --sbi=* | --sb=*) |
| 345 | sbindir="$ac_optarg" ;; |
| 346 | |
| 347 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 348 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 349 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 350 | | --sha | --sh) |
| 351 | ac_prev=sharedstatedir ;; |
| 352 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 353 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 354 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 355 | | --sha=* | --sh=*) |
| 356 | sharedstatedir="$ac_optarg" ;; |
| 357 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 358 | -site | --site | --sit) |
| 359 | ac_prev=site ;; |
| 360 | -site=* | --site=* | --sit=*) |
| 361 | site="$ac_optarg" ;; |
| 362 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 363 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 364 | ac_prev=srcdir ;; |
| 365 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
| 366 | srcdir="$ac_optarg" ;; |
| 367 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 368 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 369 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 370 | ac_prev=sysconfdir ;; |
| 371 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 372 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
| 373 | sysconfdir="$ac_optarg" ;; |
| 374 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 375 | -target | --target | --targe | --targ | --tar | --ta | --t) |
| 376 | ac_prev=target ;; |
| 377 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
| 378 | target="$ac_optarg" ;; |
| 379 | |
| 380 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 381 | verbose=yes ;; |
| 382 | |
| 383 | -version | --version | --versio | --versi | --vers) |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 384 | echo "configure generated by autoconf version 2.13" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 385 | exit 0 ;; |
| 386 | |
| 387 | -with-* | --with-*) |
| 388 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 389 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 390 | 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] | 391 | { 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] | 392 | fi |
| 393 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 394 | case "$ac_option" in |
| 395 | *=*) ;; |
| 396 | *) ac_optarg=yes ;; |
| 397 | esac |
| 398 | eval "with_${ac_package}='$ac_optarg'" ;; |
| 399 | |
| 400 | -without-* | --without-*) |
| 401 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 402 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 403 | 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] | 404 | { 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] | 405 | fi |
| 406 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 407 | eval "with_${ac_package}=no" ;; |
| 408 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 409 | --x) |
| 410 | # Obsolete; use --with-x. |
| 411 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 412 | |
| 413 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 414 | | --x-incl | --x-inc | --x-in | --x-i) |
| 415 | ac_prev=x_includes ;; |
| 416 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 417 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
| 418 | x_includes="$ac_optarg" ;; |
| 419 | |
| 420 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 421 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 422 | ac_prev=x_libraries ;; |
| 423 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 424 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
| 425 | x_libraries="$ac_optarg" ;; |
| 426 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 427 | -*) { 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] | 428 | ;; |
| 429 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 430 | *) |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 431 | 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] | 432 | echo "configure: warning: $ac_option: invalid host type" 1>&2 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 433 | fi |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 434 | if test "x$nonopt" != xNONE; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 435 | { 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] | 436 | fi |
| 437 | nonopt="$ac_option" |
| 438 | ;; |
| 439 | |
| 440 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 441 | done |
| 442 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 443 | if test -n "$ac_prev"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 444 | { 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] | 445 | fi |
| 446 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 447 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 448 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 449 | # File descriptor usage: |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 450 | # 0 standard input |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 451 | # 1 file creation |
| 452 | # 2 errors and warnings |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 453 | # 3 some systems may open it to /dev/tty |
| 454 | # 4 used on the Kubota Titan |
| 455 | # 6 checking for... messages and results |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 456 | # 5 compiler messages saved in config.log |
| 457 | if test "$silent" = yes; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 458 | exec 6>/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 459 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 460 | exec 6>&1 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 461 | fi |
| 462 | exec 5>./config.log |
| 463 | |
| 464 | echo "\ |
| 465 | This file contains any messages produced by compilers while |
| 466 | running configure, to aid debugging if configure makes a mistake. |
| 467 | " 1>&5 |
| 468 | |
| 469 | # Strip out --no-create and --no-recursion so they do not pile up. |
| 470 | # Also quote any args containing shell metacharacters. |
| 471 | ac_configure_args= |
| 472 | for ac_arg |
| 473 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 474 | case "$ac_arg" in |
| 475 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 476 | | --no-cr | --no-c) ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 477 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 478 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; |
| 479 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) |
| 480 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; |
| 481 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 482 | esac |
| 483 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 484 | |
| 485 | # NLS nuisances. |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 486 | # Only set these to C if already set. These must not be set unconditionally |
| 487 | # because not all systems understand e.g. LANG=C (notably SCO). |
| 488 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! |
| 489 | # Non-C LC_CTYPE values break the ctype check. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 490 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 491 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi |
| 492 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi |
| 493 | if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 494 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 495 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
| 496 | rm -rf conftest* confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 497 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. |
| 498 | echo > confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 499 | |
| 500 | # A filename unique to this package, relative to the directory that |
| 501 | # 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] | 502 | ac_unique_file=Include/object.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 503 | |
| 504 | # Find the source files, if location was not specified. |
| 505 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 506 | ac_srcdir_defaulted=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 507 | # Try the directory containing this script, then its parent. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 508 | ac_prog=$0 |
| 509 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` |
| 510 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
| 511 | srcdir=$ac_confdir |
| 512 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 513 | srcdir=.. |
| 514 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 515 | else |
| 516 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 517 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 518 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 519 | if test "$ac_srcdir_defaulted" = yes; then |
| 520 | { 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] | 521 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 522 | { 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] | 523 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 524 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 525 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` |
| 526 | |
| 527 | # Prefer explicitly selected file to automatically selected ones. |
| 528 | if test -z "$CONFIG_SITE"; then |
| 529 | if test "x$prefix" != xNONE; then |
| 530 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" |
| 531 | else |
| 532 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" |
| 533 | fi |
| 534 | fi |
| 535 | for ac_site_file in $CONFIG_SITE; do |
| 536 | if test -r "$ac_site_file"; then |
| 537 | echo "loading site script $ac_site_file" |
| 538 | . "$ac_site_file" |
| 539 | fi |
| 540 | done |
| 541 | |
| 542 | if test -r "$cache_file"; then |
| 543 | echo "loading cache $cache_file" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 544 | . $cache_file |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 545 | else |
| 546 | echo "creating cache $cache_file" |
| 547 | > $cache_file |
| 548 | fi |
| 549 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 550 | ac_ext=c |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 551 | # 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] | 552 | ac_cpp='$CPP $CPPFLAGS' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 553 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 554 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 555 | cross_compiling=$ac_cv_prog_cc_cross |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 556 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 557 | ac_exeext= |
| 558 | ac_objext=o |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 559 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then |
| 560 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. |
| 561 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then |
| 562 | ac_n= ac_c=' |
| 563 | ' ac_t=' ' |
| 564 | else |
| 565 | ac_n=-n ac_c= ac_t= |
| 566 | fi |
| 567 | else |
| 568 | ac_n= ac_c='\c' ac_t= |
| 569 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 570 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 571 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 572 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 573 | |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 574 | # Set VERSION so we only need to edit in one place (i.e., here) |
| 575 | |
Neil Schemenauer | 7d64577 | 2001-01-17 21:59:33 +0000 | [diff] [blame] | 576 | VERSION=2.1 |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 577 | |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 578 | # NEXTSTEP|MacOSX|Darwin stuff |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 579 | if test -f /usr/lib/NextStep/software_version -o -f /System/Library/CoreServices/software_version ; then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 580 | |
| 581 | echo $ac_n "checking for --with-next-archs""... $ac_c" 1>&6 |
Neil Schemenauer | dfb38e4 | 2001-01-27 06:57:08 +0000 | [diff] [blame] | 582 | echo "configure:583: checking for --with-next-archs" >&5 |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 583 | # Check whether --with-next-archs or --without-next-archs was given. |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 584 | if test "${with_next_archs+set}" = set; then |
| 585 | withval="$with_next_archs" |
| 586 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 587 | if test -n "$withval"; then |
| 588 | ac_arch_flags=`/usr/lib/arch_tool -archify_list $withval` |
| 589 | # GCC does not currently support multi archs on the NeXT |
| 590 | with_gcc=no |
| 591 | fi |
| 592 | echo "$ac_t""$with_next_archs" 1>&6 |
| 593 | |
| 594 | else |
| 595 | echo "$ac_t""none: using `arch`" 1>&6 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 596 | fi |
| 597 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 598 | |
| 599 | if test -z "$MACHDEP" |
| 600 | then |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 601 | ac_sys_system=`uname -s` |
| 602 | if test "$ac_sys_system" = "Darwin" ; then |
| 603 | ac_sys_release=`uname -r` |
| 604 | else |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 605 | set X `hostinfo | egrep '(NeXT Mach|Kernel Release).*:' | \ |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 606 | sed -e 's/://' -e 's/\./_/'` && \ |
| 607 | ac_sys_system=next && ac_sys_release=$4 |
| 608 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 609 | |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 610 | MACHDEP="$ac_sys_system$ac_sys_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 611 | fi |
| 612 | fi |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 613 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 614 | # Check whether --with-next-framework or --without-next-framework was given. |
| 615 | if test "${with_next_framework+set}" = set; then |
| 616 | withval="$with_next_framework" |
| 617 | : |
| 618 | fi |
| 619 | |
| 620 | # Check whether --with-dyld or --without-dyld was given. |
| 621 | if test "${with_dyld+set}" = set; then |
| 622 | withval="$with_dyld" |
| 623 | : |
| 624 | fi |
| 625 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 626 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 627 | # Set name for machine-dependent library files |
| 628 | |
| 629 | echo $ac_n "checking MACHDEP""... $ac_c" 1>&6 |
Neil Schemenauer | dfb38e4 | 2001-01-27 06:57:08 +0000 | [diff] [blame] | 630 | echo "configure:631: checking MACHDEP" >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 631 | if test -z "$MACHDEP" |
| 632 | then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 633 | ac_sys_system=`uname -s` |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 634 | if test "$ac_sys_system" = "AIX" -o "$ac_sys_system" = "Monterey64"; then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 635 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 636 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 637 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 638 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 639 | ac_md_system=`echo $ac_sys_system | |
| 640 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 641 | ac_md_release=`echo $ac_sys_release | |
| 642 | tr -d '/ ' | sed 's/\..*//'` |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 643 | MACHDEP="$ac_md_system$ac_md_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 644 | |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 645 | case $MACHDEP in |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 646 | '') MACHDEP="unknown";; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 647 | esac |
| 648 | fi |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 649 | |
| 650 | # |
| 651 | # SGI compilers allow the specification of the both the ABI and the |
| 652 | # ISA on the command line. Depending on the values of these switches, |
| 653 | # different and often incompatable code will be generated. |
| 654 | # |
| 655 | # The SGI_ABI variable can be used to modify the CC and LDFLAGS and |
| 656 | # thus supply support for various ABI/ISA combinations. The MACHDEP |
| 657 | # variable is also adjusted. |
| 658 | # |
| 659 | |
| 660 | if test ! -z "$SGI_ABI" |
| 661 | then |
| 662 | CC="cc $SGI_ABI" |
| 663 | LDFLAGS="$SGI_ABI $LDFLAGS" |
| 664 | MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'` |
| 665 | fi |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 666 | echo "$ac_t""$MACHDEP" 1>&6 |
| 667 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 668 | # checks for alternative programs |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 669 | echo $ac_n "checking for --without-gcc""... $ac_c" 1>&6 |
Neil Schemenauer | dfb38e4 | 2001-01-27 06:57:08 +0000 | [diff] [blame] | 670 | echo "configure:671: checking for --without-gcc" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 671 | # Check whether --with-gcc or --without-gcc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 672 | if test "${with_gcc+set}" = set; then |
| 673 | withval="$with_gcc" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 674 | |
| 675 | case $withval in |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 676 | no) CC=cc |
| 677 | without_gcc=yes;; |
| 678 | yes) CC=gcc |
| 679 | without_gcc=no;; |
| 680 | *) CC=$withval |
| 681 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 682 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 683 | else |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 684 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 685 | case $ac_sys_system in |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 686 | OSF1) CC=cc |
| 687 | without_gcc=;; |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 688 | AIX*) CC=cc_r |
| 689 | without_gcc=;; |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 690 | BeOS*) |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 691 | case $BE_HOST_CPU in |
| 692 | ppc) |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 693 | CC=mwcc |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 694 | without_gcc=yes |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 695 | OPT="-O -D'DL_EXPORT(RTYPE)=__declspec(dllexport) RTYPE' -D'DL_IMPORT(RTYPE)=__declspec(dllexport) RTYPE' -export pragma" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 696 | CCSHARED="-UDL_IMPORT -D'DL_IMPORT(RTYPE)=__declspec(dllimport) RTYPE'" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 697 | LDFLAGS="$LDFLAGS -nodup" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 698 | ;; |
| 699 | x86) |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 700 | CC=gcc |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 701 | without_gcc=no |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 702 | OPT=-O |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 703 | ;; |
| 704 | *) |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 705 | { echo "configure: error: Unknown BeOS platform \"$BE_HOST_CPU\"" 1>&2; exit 1; } |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 706 | ;; |
| 707 | esac |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 708 | AR="\$(srcdir)/Modules/ar_beos" |
| 709 | RANLIB=: |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 710 | ;; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 711 | Monterey*) |
| 712 | RANLIB=: |
| 713 | without_gcc=;; |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 714 | *) without_gcc=no;; |
| 715 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 716 | fi |
| 717 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 718 | echo "$ac_t""$without_gcc" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 719 | |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 720 | |
| 721 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 722 | MAINOBJ=Modules/python.o |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 723 | echo $ac_n "checking for --with-cxx=<compiler>""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 724 | echo "configure:725: checking for --with-cxx=<compiler>" >&5 |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 725 | # Check whether --with-cxx or --without-cxx was given. |
| 726 | if test "${with_cxx+set}" = set; then |
| 727 | withval="$with_cxx" |
| 728 | |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 729 | check_cxx=no |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 730 | case $withval in |
| 731 | no) CXX= |
| 732 | with_cxx=no;; |
| 733 | *) CXX=$withval |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 734 | MAINOBJ=Modules/ccpython.o |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 735 | with_cxx=$withval;; |
| 736 | esac |
| 737 | else |
| 738 | |
| 739 | with_cxx=no |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 740 | check_cxx=yes |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 741 | |
| 742 | fi |
| 743 | |
| 744 | echo "$ac_t""$with_cxx" 1>&6 |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 745 | |
| 746 | |
| 747 | if test "$check_cxx" = "yes" |
| 748 | then |
| 749 | for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl |
| 750 | do |
| 751 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 752 | set dummy $ac_prog; ac_word=$2 |
| 753 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 754 | echo "configure:755: checking for $ac_word" >&5 |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 755 | if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then |
| 756 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 757 | else |
| 758 | if test -n "$CXX"; then |
| 759 | ac_cv_prog_CXX="$CXX" # Let the user override the test. |
| 760 | else |
| 761 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 762 | ac_dummy="$PATH" |
| 763 | for ac_dir in $ac_dummy; do |
| 764 | test -z "$ac_dir" && ac_dir=. |
| 765 | if test -f $ac_dir/$ac_word; then |
| 766 | ac_cv_prog_CXX="$ac_prog" |
| 767 | break |
| 768 | fi |
| 769 | done |
| 770 | IFS="$ac_save_ifs" |
| 771 | fi |
| 772 | fi |
| 773 | CXX="$ac_cv_prog_CXX" |
| 774 | if test -n "$CXX"; then |
| 775 | echo "$ac_t""$CXX" 1>&6 |
| 776 | else |
| 777 | echo "$ac_t""no" 1>&6 |
| 778 | fi |
| 779 | |
| 780 | test -n "$CXX" && break |
| 781 | done |
| 782 | test -n "$CXX" || CXX="notfound" |
| 783 | |
| 784 | if test "$CXX" = "notfound" |
| 785 | then |
| 786 | CXX= |
| 787 | else |
| 788 | echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 789 | echo "configure:790: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5 |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 790 | |
| 791 | ac_ext=C |
| 792 | # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 793 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 794 | ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 795 | ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 796 | cross_compiling=$ac_cv_prog_cxx_cross |
| 797 | |
| 798 | cat > conftest.$ac_ext << EOF |
| 799 | |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 800 | #line 801 "configure" |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 801 | #include "confdefs.h" |
| 802 | |
| 803 | int main(){return(0);} |
| 804 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 805 | if { (eval echo configure:806: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 806 | ac_cv_prog_cxx_works=yes |
| 807 | # If we can't run a trivial program, we are probably using a cross compiler. |
| 808 | if (./conftest; exit) 2>/dev/null; then |
| 809 | ac_cv_prog_cxx_cross=no |
| 810 | else |
| 811 | ac_cv_prog_cxx_cross=yes |
| 812 | fi |
| 813 | else |
| 814 | echo "configure: failed program was:" >&5 |
| 815 | cat conftest.$ac_ext >&5 |
| 816 | ac_cv_prog_cxx_works=no |
| 817 | fi |
| 818 | rm -fr conftest* |
| 819 | ac_ext=c |
| 820 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 821 | ac_cpp='$CPP $CPPFLAGS' |
| 822 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 823 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 824 | cross_compiling=$ac_cv_prog_cc_cross |
| 825 | |
| 826 | echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6 |
| 827 | if test $ac_cv_prog_cxx_works = no; then |
| 828 | { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; } |
| 829 | fi |
| 830 | echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 831 | echo "configure:832: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5 |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 832 | echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6 |
| 833 | cross_compiling=$ac_cv_prog_cxx_cross |
| 834 | |
| 835 | fi |
| 836 | fi |
| 837 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 838 | # If the user switches compilers, we can't believe the cache |
| 839 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 840 | then |
| 841 | { echo "configure: error: cached CC is different -- throw away $cache_file |
| 842 | (it is also a good idea to do 'make clean' before compiling)" 1>&2; exit 1; } |
| 843 | fi |
| 844 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 845 | # Extract the first word of "gcc", so it can be a program name with args. |
| 846 | set dummy gcc; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 847 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 848 | echo "configure:849: checking for $ac_word" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 849 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 850 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 851 | else |
| 852 | if test -n "$CC"; then |
| 853 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 854 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 855 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 856 | ac_dummy="$PATH" |
| 857 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 858 | test -z "$ac_dir" && ac_dir=. |
| 859 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 860 | ac_cv_prog_CC="gcc" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 861 | break |
| 862 | fi |
| 863 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 864 | IFS="$ac_save_ifs" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 865 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 866 | fi |
| 867 | CC="$ac_cv_prog_CC" |
| 868 | if test -n "$CC"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 869 | echo "$ac_t""$CC" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 870 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 871 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 872 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 873 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 874 | if test -z "$CC"; then |
| 875 | # Extract the first word of "cc", so it can be a program name with args. |
| 876 | set dummy cc; ac_word=$2 |
| 877 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 878 | echo "configure:879: checking for $ac_word" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 879 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 880 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 881 | else |
| 882 | if test -n "$CC"; then |
| 883 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 884 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 885 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 886 | ac_prog_rejected=no |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 887 | ac_dummy="$PATH" |
| 888 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 889 | test -z "$ac_dir" && ac_dir=. |
| 890 | if test -f $ac_dir/$ac_word; then |
| 891 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then |
| 892 | ac_prog_rejected=yes |
| 893 | continue |
| 894 | fi |
| 895 | ac_cv_prog_CC="cc" |
| 896 | break |
| 897 | fi |
| 898 | done |
| 899 | IFS="$ac_save_ifs" |
| 900 | if test $ac_prog_rejected = yes; then |
| 901 | # We found a bogon in the path, so make sure we never use it. |
| 902 | set dummy $ac_cv_prog_CC |
| 903 | shift |
| 904 | if test $# -gt 0; then |
| 905 | # We chose a different compiler from the bogus one. |
| 906 | # However, it has the same basename, so the bogon will be chosen |
| 907 | # first if we set CC to just the basename; use the full file name. |
| 908 | shift |
| 909 | set dummy "$ac_dir/$ac_word" "$@" |
| 910 | shift |
| 911 | ac_cv_prog_CC="$@" |
| 912 | fi |
| 913 | fi |
| 914 | fi |
| 915 | fi |
| 916 | CC="$ac_cv_prog_CC" |
| 917 | if test -n "$CC"; then |
| 918 | echo "$ac_t""$CC" 1>&6 |
| 919 | else |
| 920 | echo "$ac_t""no" 1>&6 |
| 921 | fi |
| 922 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 923 | if test -z "$CC"; then |
| 924 | case "`uname -s`" in |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 925 | *win32* | *WIN32*) |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 926 | # Extract the first word of "cl", so it can be a program name with args. |
| 927 | set dummy cl; ac_word=$2 |
| 928 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 929 | echo "configure:930: checking for $ac_word" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 930 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 931 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 932 | else |
| 933 | if test -n "$CC"; then |
| 934 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 935 | else |
| 936 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 937 | ac_dummy="$PATH" |
| 938 | for ac_dir in $ac_dummy; do |
| 939 | test -z "$ac_dir" && ac_dir=. |
| 940 | if test -f $ac_dir/$ac_word; then |
| 941 | ac_cv_prog_CC="cl" |
| 942 | break |
| 943 | fi |
| 944 | done |
| 945 | IFS="$ac_save_ifs" |
| 946 | fi |
| 947 | fi |
| 948 | CC="$ac_cv_prog_CC" |
| 949 | if test -n "$CC"; then |
| 950 | echo "$ac_t""$CC" 1>&6 |
| 951 | else |
| 952 | echo "$ac_t""no" 1>&6 |
| 953 | fi |
| 954 | ;; |
| 955 | esac |
| 956 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 957 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } |
| 958 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 959 | |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 960 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 961 | echo "configure:962: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 962 | |
| 963 | ac_ext=c |
| 964 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 965 | ac_cpp='$CPP $CPPFLAGS' |
| 966 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 967 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 968 | cross_compiling=$ac_cv_prog_cc_cross |
| 969 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 970 | cat > conftest.$ac_ext << EOF |
| 971 | |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 972 | #line 973 "configure" |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 973 | #include "confdefs.h" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 974 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 975 | main(){return(0);} |
| 976 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 977 | if { (eval echo configure:978: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 978 | ac_cv_prog_cc_works=yes |
| 979 | # If we can't run a trivial program, we are probably using a cross compiler. |
| 980 | if (./conftest; exit) 2>/dev/null; then |
| 981 | ac_cv_prog_cc_cross=no |
| 982 | else |
| 983 | ac_cv_prog_cc_cross=yes |
| 984 | fi |
| 985 | else |
| 986 | echo "configure: failed program was:" >&5 |
| 987 | cat conftest.$ac_ext >&5 |
| 988 | ac_cv_prog_cc_works=no |
| 989 | fi |
| 990 | rm -fr conftest* |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 991 | ac_ext=c |
| 992 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 993 | ac_cpp='$CPP $CPPFLAGS' |
| 994 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 995 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 996 | cross_compiling=$ac_cv_prog_cc_cross |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 997 | |
| 998 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 |
| 999 | if test $ac_cv_prog_cc_works = no; then |
| 1000 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } |
| 1001 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1002 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1003 | echo "configure:1004: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1004 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
| 1005 | cross_compiling=$ac_cv_prog_cc_cross |
| 1006 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1007 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1008 | echo "configure:1009: checking whether we are using GNU C" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1009 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1010 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1011 | else |
| 1012 | cat > conftest.c <<EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1013 | #ifdef __GNUC__ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1014 | yes; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1015 | #endif |
| 1016 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1017 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1018: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1018 | ac_cv_prog_gcc=yes |
| 1019 | else |
| 1020 | ac_cv_prog_gcc=no |
| 1021 | fi |
| 1022 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1023 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1024 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1025 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1026 | if test $ac_cv_prog_gcc = yes; then |
| 1027 | GCC=yes |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1028 | else |
| 1029 | GCC= |
| 1030 | fi |
| 1031 | |
| 1032 | ac_test_CFLAGS="${CFLAGS+set}" |
| 1033 | ac_save_CFLAGS="$CFLAGS" |
| 1034 | CFLAGS= |
| 1035 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1036 | echo "configure:1037: checking whether ${CC-cc} accepts -g" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1037 | if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1038 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1039 | else |
| 1040 | echo 'void f(){}' > conftest.c |
| 1041 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1042 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1043 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1044 | ac_cv_prog_cc_g=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1045 | fi |
| 1046 | rm -f conftest* |
| 1047 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1048 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1049 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1050 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1051 | if test "$ac_test_CFLAGS" = set; then |
| 1052 | CFLAGS="$ac_save_CFLAGS" |
| 1053 | elif test $ac_cv_prog_cc_g = yes; then |
| 1054 | if test "$GCC" = yes; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1055 | CFLAGS="-g -O2" |
| 1056 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1057 | CFLAGS="-g" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1058 | fi |
| 1059 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1060 | if test "$GCC" = yes; then |
| 1061 | CFLAGS="-O2" |
| 1062 | else |
| 1063 | CFLAGS= |
| 1064 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1065 | fi |
| 1066 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1067 | echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1068 | echo "configure:1069: checking for Cygwin environment" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1069 | if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then |
| 1070 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1071 | else |
| 1072 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1073 | #line 1074 "configure" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1074 | #include "confdefs.h" |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1075 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1076 | int main() { |
| 1077 | |
| 1078 | #ifndef __CYGWIN__ |
| 1079 | #define __CYGWIN__ __CYGWIN32__ |
| 1080 | #endif |
| 1081 | return __CYGWIN__; |
| 1082 | ; return 0; } |
| 1083 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1084 | if { (eval echo configure:1085: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1085 | rm -rf conftest* |
| 1086 | ac_cv_cygwin=yes |
| 1087 | else |
| 1088 | echo "configure: failed program was:" >&5 |
| 1089 | cat conftest.$ac_ext >&5 |
| 1090 | rm -rf conftest* |
| 1091 | ac_cv_cygwin=no |
| 1092 | fi |
| 1093 | rm -f conftest* |
| 1094 | rm -f conftest* |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1095 | fi |
| 1096 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1097 | echo "$ac_t""$ac_cv_cygwin" 1>&6 |
| 1098 | CYGWIN= |
| 1099 | test "$ac_cv_cygwin" = yes && CYGWIN=yes |
| 1100 | echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1101 | echo "configure:1102: checking for mingw32 environment" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1102 | if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then |
| 1103 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1104 | else |
| 1105 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1106 | #line 1107 "configure" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1107 | #include "confdefs.h" |
| 1108 | |
| 1109 | int main() { |
| 1110 | return __MINGW32__; |
| 1111 | ; return 0; } |
| 1112 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1113 | if { (eval echo configure:1114: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1114 | rm -rf conftest* |
| 1115 | ac_cv_mingw32=yes |
| 1116 | else |
| 1117 | echo "configure: failed program was:" >&5 |
| 1118 | cat conftest.$ac_ext >&5 |
| 1119 | rm -rf conftest* |
| 1120 | ac_cv_mingw32=no |
| 1121 | fi |
| 1122 | rm -f conftest* |
| 1123 | rm -f conftest* |
| 1124 | fi |
| 1125 | |
| 1126 | echo "$ac_t""$ac_cv_mingw32" 1>&6 |
| 1127 | MINGW32= |
| 1128 | test "$ac_cv_mingw32" = yes && MINGW32=yes |
| 1129 | |
| 1130 | |
| 1131 | echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1132 | echo "configure:1133: checking for executable suffix" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1133 | if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then |
| 1134 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1135 | else |
| 1136 | if test "$CYGWIN" = yes || test "$MINGW32" = yes; then |
| 1137 | ac_cv_exeext=.exe |
| 1138 | else |
| 1139 | rm -f conftest* |
| 1140 | echo 'int main () { return 0; }' > conftest.$ac_ext |
| 1141 | ac_cv_exeext= |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1142 | if { (eval echo configure:1143: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1143 | for file in conftest.*; do |
| 1144 | case $file in |
| 1145 | *.c | *.o | *.obj) ;; |
| 1146 | *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;; |
| 1147 | esac |
| 1148 | done |
| 1149 | else |
| 1150 | { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; } |
| 1151 | fi |
| 1152 | rm -f conftest* |
| 1153 | test x"${ac_cv_exeext}" = x && ac_cv_exeext=no |
| 1154 | fi |
| 1155 | fi |
| 1156 | |
| 1157 | EXEEXT="" |
| 1158 | test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext} |
| 1159 | echo "$ac_t""${ac_cv_exeext}" 1>&6 |
| 1160 | ac_exeext=$EXEEXT |
| 1161 | |
Neil Schemenauer | dfb38e4 | 2001-01-27 06:57:08 +0000 | [diff] [blame] | 1162 | echo $ac_n "checking for --with-suffix""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1163 | echo "configure:1164: checking for --with-suffix" >&5 |
Neil Schemenauer | dfb38e4 | 2001-01-27 06:57:08 +0000 | [diff] [blame] | 1164 | # Check whether --with-suffix or --without-suffix was given. |
| 1165 | if test "${with_suffix+set}" = set; then |
| 1166 | withval="$with_suffix" |
| 1167 | |
| 1168 | case $withval in |
| 1169 | no) EXEEXT=;; |
| 1170 | yes) EXEEXT=.exe;; |
| 1171 | *) EXEEXT=$withval;; |
| 1172 | esac |
| 1173 | fi |
| 1174 | |
| 1175 | echo "$ac_t""$EXEEXT" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1176 | |
Guido van Rossum | dd997f7 | 1998-10-07 19:58:26 +0000 | [diff] [blame] | 1177 | case $MACHDEP in |
| 1178 | bsdos*) |
| 1179 | case $CC in |
| 1180 | gcc) CC="$CC -D_HAVE_BSDI";; |
| 1181 | esac;; |
| 1182 | esac |
| 1183 | |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 1184 | case $ac_sys_system in |
| 1185 | hp*|HP*) |
| 1186 | case $CC in |
Guido van Rossum | cd5ff9f | 2000-09-22 16:15:54 +0000 | [diff] [blame] | 1187 | cc|*/cc) CC="$CC -Ae";; |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 1188 | esac;; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 1189 | Monterey*) |
| 1190 | case $CC in |
| 1191 | cc) CC="$CC -Wl,-Bexport";; |
| 1192 | esac;; |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 1193 | esac |
| 1194 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 1195 | |
| 1196 | echo $ac_n "checking LIBRARY""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1197 | echo "configure:1198: checking LIBRARY" >&5 |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 1198 | if test -z "$LIBRARY" |
| 1199 | then |
| 1200 | LIBRARY='libpython$(VERSION).a' |
| 1201 | fi |
| 1202 | echo "$ac_t""$LIBRARY" 1>&6 |
| 1203 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1204 | # LDLIBRARY is the name of the library to link against (as opposed to the |
| 1205 | # name of the library into which to insert object files). On systems |
| 1206 | # without shared libraries, LDLIBRARY is the same as LIBRARY (defined in |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 1207 | # the Makefiles). On Cygwin LDLIBRARY is the import library, DLLLIBRARY is the |
| 1208 | # shared (i.e., DLL) library. |
| 1209 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1210 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 1211 | LDLIBRARY="$LIBRARY" |
Guido van Rossum | ca563f2 | 2001-01-23 01:52:44 +0000 | [diff] [blame] | 1212 | DLLLIBRARY='' |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1213 | |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1214 | # LINKCC is the command that links the python executable -- default is $(CC). |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 1215 | # This is altered for AIX in order to build the export list before |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1216 | # linking. |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1217 | |
| 1218 | echo $ac_n "checking LINKCC""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1219 | echo "configure:1220: checking LINKCC" >&5 |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1220 | if test -z "$LINKCC" |
| 1221 | then |
| 1222 | case $ac_sys_system in |
| 1223 | AIX*) |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1224 | LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp \"\" \$(LIBRARY); \$(PURIFY) \$(CC)";; |
Guido van Rossum | 3c4bb80 | 1997-12-18 23:55:32 +0000 | [diff] [blame] | 1225 | dgux*) |
| 1226 | LINKCC="LD_RUN_PATH=$libdir \$(PURIFY) \$(CC)";; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 1227 | Monterey64*) |
| 1228 | LINKCC="\$(PURIFY) \$(CC) -L/usr/lib/ia64l64";; |
Guido van Rossum | 25f9303 | 1997-08-18 16:00:04 +0000 | [diff] [blame] | 1229 | *) LINKCC="\$(PURIFY) \$(CC)";; |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1230 | esac |
| 1231 | fi |
| 1232 | echo "$ac_t""$LINKCC" 1>&6 |
| 1233 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1234 | echo $ac_n "checking LDLIBRARY""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1235 | echo "configure:1236: checking LDLIBRARY" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1236 | |
| 1237 | # NeXT framework builds require that the 'ar' library be converted into |
| 1238 | # a bundle using libtool. |
| 1239 | if test "$with_next_framework" |
| 1240 | then |
| 1241 | LDLIBRARY='libpython$(VERSION).dylib' |
| 1242 | fi |
| 1243 | |
| 1244 | # DG/UX requires some fancy ld contortions to produce a .so from an .a |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 1245 | case $MACHDEP in |
| 1246 | dguxR4) |
| 1247 | LDLIBRARY='libpython$(VERSION).so' |
| 1248 | OPT="$OPT -pic" |
| 1249 | ;; |
| 1250 | beos*) |
| 1251 | LDLIBRARY='libpython$(VERSION).so' |
| 1252 | ;; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 1253 | cygwin*) |
| 1254 | LDLIBRARY='libpython$(VERSION).dll.a' |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1255 | DLLLIBRARY='libpython$(VERSION).dll' |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 1256 | ;; |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 1257 | esac |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1258 | echo "$ac_t""$LDLIBRARY" 1>&6 |
| 1259 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1260 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 1261 | set dummy ranlib; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1262 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1263 | echo "configure:1264: checking for $ac_word" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1264 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1265 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1266 | else |
| 1267 | if test -n "$RANLIB"; then |
| 1268 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 1269 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1270 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 1271 | ac_dummy="$PATH" |
| 1272 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1273 | test -z "$ac_dir" && ac_dir=. |
| 1274 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1275 | ac_cv_prog_RANLIB="ranlib" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1276 | break |
| 1277 | fi |
| 1278 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1279 | IFS="$ac_save_ifs" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1280 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1281 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1282 | fi |
| 1283 | RANLIB="$ac_cv_prog_RANLIB" |
| 1284 | if test -n "$RANLIB"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1285 | echo "$ac_t""$RANLIB" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1286 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1287 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1288 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1289 | |
| 1290 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1291 | for ac_prog in ar aal |
| 1292 | do |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1293 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 1294 | set dummy $ac_prog; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1295 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1296 | echo "configure:1297: checking for $ac_word" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1297 | if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1298 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1299 | else |
| 1300 | if test -n "$AR"; then |
| 1301 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 1302 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1303 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 1304 | ac_dummy="$PATH" |
| 1305 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1306 | test -z "$ac_dir" && ac_dir=. |
| 1307 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1308 | ac_cv_prog_AR="$ac_prog" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1309 | break |
| 1310 | fi |
| 1311 | done |
| 1312 | IFS="$ac_save_ifs" |
| 1313 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1314 | fi |
| 1315 | AR="$ac_cv_prog_AR" |
| 1316 | if test -n "$AR"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1317 | echo "$ac_t""$AR" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1318 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1319 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1320 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1321 | |
| 1322 | test -n "$AR" && break |
| 1323 | done |
| 1324 | test -n "$AR" || AR="ar" |
| 1325 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1326 | ac_aux_dir= |
| 1327 | for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do |
| 1328 | if test -f $ac_dir/install-sh; then |
| 1329 | ac_aux_dir=$ac_dir |
| 1330 | ac_install_sh="$ac_aux_dir/install-sh -c" |
| 1331 | break |
| 1332 | elif test -f $ac_dir/install.sh; then |
| 1333 | ac_aux_dir=$ac_dir |
| 1334 | ac_install_sh="$ac_aux_dir/install.sh -c" |
| 1335 | break |
| 1336 | fi |
| 1337 | done |
| 1338 | if test -z "$ac_aux_dir"; then |
| 1339 | { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; } |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1340 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1341 | ac_config_guess=$ac_aux_dir/config.guess |
| 1342 | ac_config_sub=$ac_aux_dir/config.sub |
| 1343 | ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. |
| 1344 | |
| 1345 | # Find a good install program. We prefer a C program (faster), |
| 1346 | # so one script is as good as another. But avoid the broken or |
| 1347 | # incompatible versions: |
| 1348 | # SysV /etc/install, /usr/sbin/install |
| 1349 | # SunOS /usr/etc/install |
| 1350 | # IRIX /sbin/install |
| 1351 | # AIX /bin/install |
| 1352 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 1353 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 1354 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 1355 | # ./install, which can be erroneously created by make from ./install.sh. |
| 1356 | echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1357 | echo "configure:1358: checking for a BSD compatible install" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1358 | if test -z "$INSTALL"; then |
| 1359 | if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then |
| 1360 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1361 | else |
| 1362 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" |
| 1363 | for ac_dir in $PATH; do |
| 1364 | # Account for people who put trailing slashes in PATH elements. |
| 1365 | case "$ac_dir/" in |
| 1366 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; |
| 1367 | *) |
| 1368 | # OSF1 and SCO ODT 3.0 have their own names for install. |
| 1369 | # Don't use installbsd from OSF since it installs stuff as root |
| 1370 | # by default. |
| 1371 | for ac_prog in ginstall scoinst install; do |
| 1372 | if test -f $ac_dir/$ac_prog; then |
| 1373 | if test $ac_prog = install && |
| 1374 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then |
| 1375 | # AIX install. It has an incompatible calling convention. |
| 1376 | : |
| 1377 | else |
| 1378 | ac_cv_path_install="$ac_dir/$ac_prog -c" |
| 1379 | break 2 |
| 1380 | fi |
| 1381 | fi |
| 1382 | done |
| 1383 | ;; |
| 1384 | esac |
| 1385 | done |
| 1386 | IFS="$ac_save_IFS" |
| 1387 | |
| 1388 | fi |
| 1389 | if test "${ac_cv_path_install+set}" = set; then |
| 1390 | INSTALL="$ac_cv_path_install" |
| 1391 | else |
| 1392 | # As a last resort, use the slow shell script. We don't cache a |
| 1393 | # path for INSTALL within a source directory, because that will |
| 1394 | # break other packages using the cache if that directory is |
| 1395 | # removed, or if the path is relative. |
| 1396 | INSTALL="$ac_install_sh" |
| 1397 | fi |
| 1398 | fi |
| 1399 | echo "$ac_t""$INSTALL" 1>&6 |
| 1400 | |
| 1401 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 1402 | # It thinks the first close brace ends the variable substitution. |
| 1403 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 1404 | |
| 1405 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' |
| 1406 | |
| 1407 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 1408 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1409 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1410 | # Not every filesystem supports hard links |
| 1411 | |
| 1412 | if test -z "$LN" ; then |
| 1413 | case $ac_sys_system in |
| 1414 | BeOS*) LN="ln -s";; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 1415 | CYGWIN*) LN="ln -s";; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1416 | *) LN=ln;; |
| 1417 | esac |
| 1418 | fi |
| 1419 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1420 | # Optimizer/debugger flags |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1421 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1422 | if test -z "$OPT" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1423 | then |
Guido van Rossum | edca74a | 1997-07-18 23:29:40 +0000 | [diff] [blame] | 1424 | case $GCC in |
| 1425 | yes) |
| 1426 | case $ac_cv_prog_cc_g in |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 1427 | yes) OPT="-g -O2 -Wall -Wstrict-prototypes";; |
| 1428 | *) OPT="-O2 -Wall -Wstrict-prototypes";; |
Guido van Rossum | edca74a | 1997-07-18 23:29:40 +0000 | [diff] [blame] | 1429 | esac |
| 1430 | ;; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1431 | *) OPT="-O";; |
| 1432 | esac |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1433 | fi |
| 1434 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 1435 | # The current (beta) Monterey compiler dies with optimizations |
| 1436 | case $ac_sys_system in |
| 1437 | Monterey*) OPT="";; |
| 1438 | esac |
| 1439 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1440 | if test "$ac_arch_flags" |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 1441 | then |
| 1442 | OPT="$OPT $ac_arch_flags" |
| 1443 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1444 | # checks for UNIX variants that set C preprocessor variables |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1445 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1446 | echo "configure:1447: checking how to run the C preprocessor" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1447 | # On Suns, sometimes $CPP names a directory. |
| 1448 | if test -n "$CPP" && test -d "$CPP"; then |
| 1449 | CPP= |
| 1450 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1451 | if test -z "$CPP"; then |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1452 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1453 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1454 | else |
| 1455 | # This must be in double quotes, not single quotes, because CPP may get |
| 1456 | # substituted into the Makefile and "${CC-cc}" will confuse make. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1457 | CPP="${CC-cc} -E" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1458 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 1459 | # not just through cpp. |
| 1460 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1461 | #line 1462 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1462 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1463 | #include <assert.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1464 | Syntax Error |
| 1465 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1466 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1467 | { (eval echo configure:1468: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1468 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 1469 | if test -z "$ac_err"; then |
| 1470 | : |
| 1471 | else |
| 1472 | echo "$ac_err" >&5 |
| 1473 | echo "configure: failed program was:" >&5 |
| 1474 | cat conftest.$ac_ext >&5 |
| 1475 | rm -rf conftest* |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1476 | CPP="${CC-cc} -E -traditional-cpp" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1477 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1478 | #line 1479 "configure" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1479 | #include "confdefs.h" |
| 1480 | #include <assert.h> |
| 1481 | Syntax Error |
| 1482 | EOF |
| 1483 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1484 | { (eval echo configure:1485: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1485 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1486 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1487 | : |
| 1488 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1489 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1490 | echo "configure: failed program was:" >&5 |
| 1491 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1492 | rm -rf conftest* |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1493 | CPP="${CC-cc} -nologo -E" |
| 1494 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1495 | #line 1496 "configure" |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1496 | #include "confdefs.h" |
| 1497 | #include <assert.h> |
| 1498 | Syntax Error |
| 1499 | EOF |
| 1500 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1501 | { (eval echo configure:1502: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1502 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 1503 | if test -z "$ac_err"; then |
| 1504 | : |
| 1505 | else |
| 1506 | echo "$ac_err" >&5 |
| 1507 | echo "configure: failed program was:" >&5 |
| 1508 | cat conftest.$ac_ext >&5 |
| 1509 | rm -rf conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1510 | CPP=/lib/cpp |
| 1511 | fi |
| 1512 | rm -f conftest* |
| 1513 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1514 | rm -f conftest* |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1515 | fi |
| 1516 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1517 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1518 | fi |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 1519 | CPP="$ac_cv_prog_CPP" |
| 1520 | else |
| 1521 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1522 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1523 | echo "$ac_t""$CPP" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1524 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1525 | echo $ac_n "checking for AIX""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1526 | echo "configure:1527: checking for AIX" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1527 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1528 | #line 1529 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1529 | #include "confdefs.h" |
| 1530 | #ifdef _AIX |
| 1531 | yes |
| 1532 | #endif |
| 1533 | |
| 1534 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1535 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1536 | egrep "yes" >/dev/null 2>&1; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1537 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1538 | echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1539 | #define _ALL_SOURCE 1 |
| 1540 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1541 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1542 | else |
| 1543 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1544 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1545 | fi |
| 1546 | rm -f conftest* |
| 1547 | |
| 1548 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1549 | ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1550 | echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1551 | echo "configure:1552: checking for minix/config.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1552 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1553 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1554 | else |
| 1555 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1556 | #line 1557 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1557 | #include "confdefs.h" |
| 1558 | #include <minix/config.h> |
| 1559 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1560 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1561 | { (eval echo configure:1562: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1562 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1563 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1564 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1565 | eval "ac_cv_header_$ac_safe=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1566 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1567 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1568 | echo "configure: failed program was:" >&5 |
| 1569 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1570 | rm -rf conftest* |
| 1571 | eval "ac_cv_header_$ac_safe=no" |
| 1572 | fi |
| 1573 | rm -f conftest* |
| 1574 | fi |
| 1575 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1576 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1577 | MINIX=yes |
| 1578 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1579 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1580 | MINIX= |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1581 | fi |
| 1582 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1583 | if test "$MINIX" = yes; then |
| 1584 | cat >> confdefs.h <<\EOF |
| 1585 | #define _POSIX_SOURCE 1 |
| 1586 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1587 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1588 | cat >> confdefs.h <<\EOF |
| 1589 | #define _POSIX_1_SOURCE 2 |
| 1590 | EOF |
| 1591 | |
| 1592 | cat >> confdefs.h <<\EOF |
| 1593 | #define _MINIX 1 |
| 1594 | EOF |
| 1595 | |
| 1596 | fi |
| 1597 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1598 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1599 | echo $ac_n "checking whether $CC accepts -OPT:Olimit=0""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1600 | echo "configure:1601: checking whether $CC accepts -OPT:Olimit=0" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1601 | if eval "test \"`echo '$''{'ac_cv_opt_olimit_ok'+set}'`\" = set"; then |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1602 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1603 | else |
| 1604 | ac_save_cc="$CC" |
| 1605 | CC="$CC -OPT:Olimit=0" |
| 1606 | if test "$cross_compiling" = yes; then |
| 1607 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1608 | else |
| 1609 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1610 | #line 1611 "configure" |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1611 | #include "confdefs.h" |
| 1612 | int main() { return 0; } |
| 1613 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1614 | if { (eval echo configure:1615: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1615 | then |
| 1616 | ac_cv_opt_olimit_ok=yes |
| 1617 | else |
| 1618 | echo "configure: failed program was:" >&5 |
| 1619 | cat conftest.$ac_ext >&5 |
| 1620 | rm -fr conftest* |
| 1621 | ac_cv_opt_olimit_ok=no |
| 1622 | fi |
| 1623 | rm -fr conftest* |
| 1624 | fi |
| 1625 | |
| 1626 | CC="$ac_save_cc" |
| 1627 | fi |
| 1628 | |
| 1629 | echo "$ac_t""$ac_cv_opt_olimit_ok" 1>&6 |
Guido van Rossum | 2efa34b | 1997-10-23 17:43:11 +0000 | [diff] [blame] | 1630 | if test $ac_cv_opt_olimit_ok = yes; then |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 1631 | case $ac_sys_system in |
| 1632 | Darwin*) OPT="$OPT" ;; |
| 1633 | *) OPT="$OPT -OPT:Olimit=0";; |
| 1634 | esac |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1635 | else |
| 1636 | echo $ac_n "checking whether $CC accepts -Olimit 1500""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1637 | echo "configure:1638: checking whether $CC accepts -Olimit 1500" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1638 | if eval "test \"`echo '$''{'ac_cv_olimit_ok'+set}'`\" = set"; then |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1639 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1640 | else |
| 1641 | ac_save_cc="$CC" |
| 1642 | CC="$CC -Olimit 1500" |
| 1643 | if test "$cross_compiling" = yes; then |
| 1644 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1645 | else |
| 1646 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1647 | #line 1648 "configure" |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1648 | #include "confdefs.h" |
| 1649 | int main() { return 0; } |
| 1650 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1651 | if { (eval echo configure:1652: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1652 | then |
| 1653 | ac_cv_olimit_ok=yes |
| 1654 | else |
| 1655 | echo "configure: failed program was:" >&5 |
| 1656 | cat conftest.$ac_ext >&5 |
| 1657 | rm -fr conftest* |
| 1658 | ac_cv_olimit_ok=no |
Guido van Rossum | 201afe5 | 1997-05-14 21:14:44 +0000 | [diff] [blame] | 1659 | fi |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1660 | rm -fr conftest* |
| 1661 | fi |
| 1662 | |
| 1663 | CC="$ac_save_cc" |
| 1664 | fi |
| 1665 | |
| 1666 | echo "$ac_t""$ac_cv_olimit_ok" 1>&6 |
| 1667 | if test $ac_cv_olimit_ok = yes; then |
| 1668 | OPT="$OPT -Olimit 1500" |
| 1669 | fi |
| 1670 | fi |
| 1671 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1672 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1673 | # checks for header files |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1674 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1675 | echo "configure:1676: checking for ANSI C header files" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1676 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1677 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1678 | else |
| 1679 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1680 | #line 1681 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1681 | #include "confdefs.h" |
| 1682 | #include <stdlib.h> |
| 1683 | #include <stdarg.h> |
| 1684 | #include <string.h> |
| 1685 | #include <float.h> |
| 1686 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1687 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1688 | { (eval echo configure:1689: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1689 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1690 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1691 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1692 | ac_cv_header_stdc=yes |
| 1693 | else |
| 1694 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1695 | echo "configure: failed program was:" >&5 |
| 1696 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1697 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1698 | ac_cv_header_stdc=no |
| 1699 | fi |
| 1700 | rm -f conftest* |
| 1701 | |
| 1702 | if test $ac_cv_header_stdc = yes; then |
| 1703 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 1704 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1705 | #line 1706 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1706 | #include "confdefs.h" |
| 1707 | #include <string.h> |
| 1708 | EOF |
| 1709 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1710 | egrep "memchr" >/dev/null 2>&1; then |
| 1711 | : |
| 1712 | else |
| 1713 | rm -rf conftest* |
| 1714 | ac_cv_header_stdc=no |
| 1715 | fi |
| 1716 | rm -f conftest* |
| 1717 | |
| 1718 | fi |
| 1719 | |
| 1720 | if test $ac_cv_header_stdc = yes; then |
| 1721 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 1722 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1723 | #line 1724 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1724 | #include "confdefs.h" |
| 1725 | #include <stdlib.h> |
| 1726 | EOF |
| 1727 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1728 | egrep "free" >/dev/null 2>&1; then |
| 1729 | : |
| 1730 | else |
| 1731 | rm -rf conftest* |
| 1732 | ac_cv_header_stdc=no |
| 1733 | fi |
| 1734 | rm -f conftest* |
| 1735 | |
| 1736 | fi |
| 1737 | |
| 1738 | if test $ac_cv_header_stdc = yes; then |
| 1739 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 1740 | if test "$cross_compiling" = yes; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1741 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1742 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1743 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1744 | #line 1745 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1745 | #include "confdefs.h" |
| 1746 | #include <ctype.h> |
| 1747 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 1748 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1749 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1750 | int main () { int i; for (i = 0; i < 256; i++) |
| 1751 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); |
| 1752 | exit (0); } |
| 1753 | |
| 1754 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1755 | if { (eval echo configure:1756: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1756 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1757 | : |
| 1758 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1759 | echo "configure: failed program was:" >&5 |
| 1760 | cat conftest.$ac_ext >&5 |
| 1761 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1762 | ac_cv_header_stdc=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1763 | fi |
| 1764 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1765 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1766 | |
| 1767 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1768 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1769 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1770 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1771 | if test $ac_cv_header_stdc = yes; then |
| 1772 | cat >> confdefs.h <<\EOF |
| 1773 | #define STDC_HEADERS 1 |
| 1774 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1775 | |
| 1776 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1777 | |
Andrew M. Kuchling | 5821b77 | 2000-08-25 01:14:08 +0000 | [diff] [blame] | 1778 | for ac_hdr in dlfcn.h fcntl.h limits.h locale.h ncurses.h poll.h pthread.h \ |
Eric S. Raymond | d2d75d3 | 2001-01-16 15:26:34 +0000 | [diff] [blame] | 1779 | signal.h stdarg.h stddef.h stdlib.h thread.h unistd.h utime.h termios.h \ |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 1780 | sys/audioio.h sys/file.h sys/lock.h db_185.h db.h \ |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 1781 | sys/param.h sys/select.h sys/socket.h sys/time.h sys/times.h \ |
Fred Drake | ae90f8d | 2000-09-15 03:38:12 +0000 | [diff] [blame] | 1782 | sys/un.h sys/utsname.h sys/wait.h pty.h libutil.h \ |
| 1783 | ndbm.h db1/ndbm.h gdbm/ndbm.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1784 | do |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1785 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1786 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1787 | echo "configure:1788: checking for $ac_hdr" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1788 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1789 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1790 | else |
| 1791 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1792 | #line 1793 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1793 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1794 | #include <$ac_hdr> |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1795 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1796 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1797 | { (eval echo configure:1798: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1798 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1799 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1800 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1801 | eval "ac_cv_header_$ac_safe=yes" |
| 1802 | else |
| 1803 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1804 | echo "configure: failed program was:" >&5 |
| 1805 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1806 | rm -rf conftest* |
| 1807 | eval "ac_cv_header_$ac_safe=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1808 | fi |
| 1809 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1810 | fi |
| 1811 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1812 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1813 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1814 | cat >> confdefs.h <<EOF |
| 1815 | #define $ac_tr_hdr 1 |
| 1816 | EOF |
| 1817 | |
| 1818 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1819 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1820 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1821 | done |
| 1822 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1823 | ac_header_dirent=no |
| 1824 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h |
| 1825 | do |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1826 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1827 | echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1828 | echo "configure:1829: checking for $ac_hdr that defines DIR" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1829 | if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1830 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1831 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1832 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1833 | #line 1834 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1834 | #include "confdefs.h" |
| 1835 | #include <sys/types.h> |
| 1836 | #include <$ac_hdr> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1837 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1838 | DIR *dirp = 0; |
| 1839 | ; return 0; } |
| 1840 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1841 | if { (eval echo configure:1842: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1842 | rm -rf conftest* |
| 1843 | eval "ac_cv_header_dirent_$ac_safe=yes" |
| 1844 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1845 | echo "configure: failed program was:" >&5 |
| 1846 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1847 | rm -rf conftest* |
| 1848 | eval "ac_cv_header_dirent_$ac_safe=no" |
| 1849 | fi |
| 1850 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1851 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1852 | if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1853 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1854 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1855 | cat >> confdefs.h <<EOF |
| 1856 | #define $ac_tr_hdr 1 |
| 1857 | EOF |
| 1858 | ac_header_dirent=$ac_hdr; break |
| 1859 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1860 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1861 | fi |
| 1862 | done |
| 1863 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 1864 | if test $ac_header_dirent = dirent.h; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1865 | echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1866 | echo "configure:1867: checking for opendir in -ldir" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1867 | ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1868 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1869 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1870 | else |
| 1871 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1872 | LIBS="-ldir $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1873 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1874 | #line 1875 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1875 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1876 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1877 | /* We use char because int might match the return type of a gcc2 |
| 1878 | builtin and then its argument prototype would still apply. */ |
| 1879 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1880 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1881 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1882 | opendir() |
| 1883 | ; return 0; } |
| 1884 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1885 | if { (eval echo configure:1886: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1886 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1887 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1888 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1889 | echo "configure: failed program was:" >&5 |
| 1890 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1891 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1892 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1893 | fi |
| 1894 | rm -f conftest* |
| 1895 | LIBS="$ac_save_LIBS" |
| 1896 | |
| 1897 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1898 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1899 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1900 | LIBS="$LIBS -ldir" |
| 1901 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1902 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1903 | fi |
| 1904 | |
| 1905 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1906 | echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1907 | echo "configure:1908: checking for opendir in -lx" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1908 | ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1909 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1910 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1911 | else |
| 1912 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1913 | LIBS="-lx $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1914 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1915 | #line 1916 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1916 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1917 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1918 | /* We use char because int might match the return type of a gcc2 |
| 1919 | builtin and then its argument prototype would still apply. */ |
| 1920 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1921 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1922 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1923 | opendir() |
| 1924 | ; return 0; } |
| 1925 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1926 | if { (eval echo configure:1927: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1927 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1928 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1929 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1930 | echo "configure: failed program was:" >&5 |
| 1931 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1932 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1933 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1934 | fi |
| 1935 | rm -f conftest* |
| 1936 | LIBS="$ac_save_LIBS" |
| 1937 | |
| 1938 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1939 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1940 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1941 | LIBS="$LIBS -lx" |
| 1942 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1943 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1944 | fi |
| 1945 | |
| 1946 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1947 | |
| 1948 | |
| 1949 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1950 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1951 | echo $ac_n "checking for clock_t in time.h""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1952 | echo "configure:1953: checking for clock_t in time.h" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1953 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1954 | #line 1955 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1955 | #include "confdefs.h" |
| 1956 | #include <time.h> |
| 1957 | EOF |
| 1958 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1959 | egrep "clock_t" >/dev/null 2>&1; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1960 | rm -rf conftest* |
| 1961 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1962 | else |
| 1963 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1964 | cat >> confdefs.h <<\EOF |
| 1965 | #define clock_t long |
| 1966 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1967 | |
| 1968 | fi |
| 1969 | rm -f conftest* |
| 1970 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1971 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1972 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1973 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 1974 | cat >> confdefs.h <<\EOF |
| 1975 | #if defined(SCO_DS) |
| 1976 | #undef _OFF_T |
| 1977 | #endif |
| 1978 | EOF |
| 1979 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1980 | # Type availability checks |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1981 | echo $ac_n "checking for mode_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1982 | echo "configure:1983: checking for mode_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1983 | if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1984 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1985 | else |
| 1986 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 1987 | #line 1988 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1988 | #include "confdefs.h" |
| 1989 | #include <sys/types.h> |
| 1990 | #if STDC_HEADERS |
| 1991 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1992 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1993 | #endif |
| 1994 | EOF |
| 1995 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1996 | egrep "(^|[^a-zA-Z_0-9])mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1997 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1998 | ac_cv_type_mode_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1999 | else |
| 2000 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2001 | ac_cv_type_mode_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2002 | fi |
| 2003 | rm -f conftest* |
| 2004 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2005 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2006 | echo "$ac_t""$ac_cv_type_mode_t" 1>&6 |
| 2007 | if test $ac_cv_type_mode_t = no; then |
| 2008 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2009 | #define mode_t int |
| 2010 | EOF |
| 2011 | |
| 2012 | fi |
| 2013 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2014 | echo $ac_n "checking for off_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2015 | echo "configure:2016: checking for off_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2016 | if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2017 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2018 | else |
| 2019 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2020 | #line 2021 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2021 | #include "confdefs.h" |
| 2022 | #include <sys/types.h> |
| 2023 | #if STDC_HEADERS |
| 2024 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2025 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2026 | #endif |
| 2027 | EOF |
| 2028 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2029 | egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2030 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2031 | ac_cv_type_off_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2032 | else |
| 2033 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2034 | ac_cv_type_off_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2035 | fi |
| 2036 | rm -f conftest* |
| 2037 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2038 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2039 | echo "$ac_t""$ac_cv_type_off_t" 1>&6 |
| 2040 | if test $ac_cv_type_off_t = no; then |
| 2041 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2042 | #define off_t long |
| 2043 | EOF |
| 2044 | |
| 2045 | fi |
| 2046 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2047 | echo $ac_n "checking for pid_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2048 | echo "configure:2049: checking for pid_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2049 | if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2050 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2051 | else |
| 2052 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2053 | #line 2054 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2054 | #include "confdefs.h" |
| 2055 | #include <sys/types.h> |
| 2056 | #if STDC_HEADERS |
| 2057 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2058 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2059 | #endif |
| 2060 | EOF |
| 2061 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2062 | egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2063 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2064 | ac_cv_type_pid_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2065 | else |
| 2066 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2067 | ac_cv_type_pid_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2068 | fi |
| 2069 | rm -f conftest* |
| 2070 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2071 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2072 | echo "$ac_t""$ac_cv_type_pid_t" 1>&6 |
| 2073 | if test $ac_cv_type_pid_t = no; then |
| 2074 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2075 | #define pid_t int |
| 2076 | EOF |
| 2077 | |
| 2078 | fi |
| 2079 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2080 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2081 | echo "configure:2082: checking return type of signal handlers" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2082 | if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2083 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2084 | else |
| 2085 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2086 | #line 2087 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2087 | #include "confdefs.h" |
| 2088 | #include <sys/types.h> |
| 2089 | #include <signal.h> |
| 2090 | #ifdef signal |
| 2091 | #undef signal |
| 2092 | #endif |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2093 | #ifdef __cplusplus |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2094 | extern "C" void (*signal (int, void (*)(int)))(int); |
| 2095 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2096 | void (*signal ()) (); |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2097 | #endif |
| 2098 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2099 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2100 | int i; |
| 2101 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2102 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2103 | if { (eval echo configure:2104: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2104 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2105 | ac_cv_type_signal=void |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2106 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2107 | echo "configure: failed program was:" >&5 |
| 2108 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2109 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2110 | ac_cv_type_signal=int |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2111 | fi |
| 2112 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2113 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2114 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2115 | echo "$ac_t""$ac_cv_type_signal" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2116 | cat >> confdefs.h <<EOF |
| 2117 | #define RETSIGTYPE $ac_cv_type_signal |
| 2118 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2119 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2120 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2121 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2122 | echo "configure:2123: checking for size_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2123 | if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2124 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2125 | else |
| 2126 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2127 | #line 2128 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2128 | #include "confdefs.h" |
| 2129 | #include <sys/types.h> |
| 2130 | #if STDC_HEADERS |
| 2131 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2132 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2133 | #endif |
| 2134 | EOF |
| 2135 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2136 | egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2137 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2138 | ac_cv_type_size_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2139 | else |
| 2140 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2141 | ac_cv_type_size_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2142 | fi |
| 2143 | rm -f conftest* |
| 2144 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2145 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2146 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 |
| 2147 | if test $ac_cv_type_size_t = no; then |
| 2148 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2149 | #define size_t unsigned |
| 2150 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2151 | |
| 2152 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2153 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2154 | echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2155 | echo "configure:2156: checking for uid_t in sys/types.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2156 | if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2157 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2158 | else |
| 2159 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2160 | #line 2161 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2161 | #include "confdefs.h" |
| 2162 | #include <sys/types.h> |
| 2163 | EOF |
| 2164 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 2165 | egrep "uid_t" >/dev/null 2>&1; then |
| 2166 | rm -rf conftest* |
| 2167 | ac_cv_type_uid_t=yes |
| 2168 | else |
| 2169 | rm -rf conftest* |
| 2170 | ac_cv_type_uid_t=no |
| 2171 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2172 | rm -f conftest* |
| 2173 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2174 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2175 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2176 | echo "$ac_t""$ac_cv_type_uid_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2177 | if test $ac_cv_type_uid_t = no; then |
| 2178 | cat >> confdefs.h <<\EOF |
| 2179 | #define uid_t int |
| 2180 | EOF |
| 2181 | |
| 2182 | cat >> confdefs.h <<\EOF |
| 2183 | #define gid_t int |
| 2184 | EOF |
| 2185 | |
| 2186 | fi |
| 2187 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2188 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2189 | # Sizes of various common basic types |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2190 | echo $ac_n "checking size of int""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2191 | echo "configure:2192: checking size of int" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2192 | if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2193 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2194 | else |
| 2195 | if test "$cross_compiling" = yes; then |
| 2196 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2197 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2198 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2199 | #line 2200 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2200 | #include "confdefs.h" |
| 2201 | #include <stdio.h> |
| 2202 | main() |
| 2203 | { |
| 2204 | FILE *f=fopen("conftestval", "w"); |
| 2205 | if (!f) exit(1); |
| 2206 | fprintf(f, "%d\n", sizeof(int)); |
| 2207 | exit(0); |
| 2208 | } |
| 2209 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2210 | if { (eval echo configure:2211: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2211 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2212 | ac_cv_sizeof_int=`cat conftestval` |
| 2213 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2214 | echo "configure: failed program was:" >&5 |
| 2215 | cat conftest.$ac_ext >&5 |
| 2216 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2217 | ac_cv_sizeof_int=0 |
| 2218 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2219 | rm -fr conftest* |
| 2220 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2221 | |
| 2222 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2223 | echo "$ac_t""$ac_cv_sizeof_int" 1>&6 |
| 2224 | cat >> confdefs.h <<EOF |
| 2225 | #define SIZEOF_INT $ac_cv_sizeof_int |
| 2226 | EOF |
| 2227 | |
| 2228 | |
| 2229 | echo $ac_n "checking size of long""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2230 | echo "configure:2231: checking size of long" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2231 | if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2232 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2233 | else |
| 2234 | if test "$cross_compiling" = yes; then |
| 2235 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2236 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2237 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2238 | #line 2239 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2239 | #include "confdefs.h" |
| 2240 | #include <stdio.h> |
| 2241 | main() |
| 2242 | { |
| 2243 | FILE *f=fopen("conftestval", "w"); |
| 2244 | if (!f) exit(1); |
| 2245 | fprintf(f, "%d\n", sizeof(long)); |
| 2246 | exit(0); |
| 2247 | } |
| 2248 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2249 | if { (eval echo configure:2250: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2250 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2251 | ac_cv_sizeof_long=`cat conftestval` |
| 2252 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2253 | echo "configure: failed program was:" >&5 |
| 2254 | cat conftest.$ac_ext >&5 |
| 2255 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2256 | ac_cv_sizeof_long=0 |
| 2257 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2258 | rm -fr conftest* |
| 2259 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2260 | |
| 2261 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2262 | echo "$ac_t""$ac_cv_sizeof_long" 1>&6 |
| 2263 | cat >> confdefs.h <<EOF |
| 2264 | #define SIZEOF_LONG $ac_cv_sizeof_long |
| 2265 | EOF |
| 2266 | |
| 2267 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2268 | echo $ac_n "checking size of void *""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2269 | echo "configure:2270: checking size of void *" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2270 | if eval "test \"`echo '$''{'ac_cv_sizeof_void_p'+set}'`\" = set"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2271 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2272 | else |
| 2273 | if test "$cross_compiling" = yes; then |
| 2274 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2275 | else |
| 2276 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2277 | #line 2278 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2278 | #include "confdefs.h" |
| 2279 | #include <stdio.h> |
| 2280 | main() |
| 2281 | { |
| 2282 | FILE *f=fopen("conftestval", "w"); |
| 2283 | if (!f) exit(1); |
| 2284 | fprintf(f, "%d\n", sizeof(void *)); |
| 2285 | exit(0); |
| 2286 | } |
| 2287 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2288 | if { (eval echo configure:2289: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2289 | then |
| 2290 | ac_cv_sizeof_void_p=`cat conftestval` |
| 2291 | else |
| 2292 | echo "configure: failed program was:" >&5 |
| 2293 | cat conftest.$ac_ext >&5 |
| 2294 | rm -fr conftest* |
| 2295 | ac_cv_sizeof_void_p=0 |
| 2296 | fi |
| 2297 | rm -fr conftest* |
| 2298 | fi |
| 2299 | |
| 2300 | fi |
| 2301 | echo "$ac_t""$ac_cv_sizeof_void_p" 1>&6 |
| 2302 | cat >> confdefs.h <<EOF |
| 2303 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
| 2304 | EOF |
| 2305 | |
| 2306 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2307 | echo $ac_n "checking size of char""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2308 | echo "configure:2309: checking size of char" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2309 | if eval "test \"`echo '$''{'ac_cv_sizeof_char'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2310 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2311 | else |
| 2312 | if test "$cross_compiling" = yes; then |
| 2313 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2314 | else |
| 2315 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2316 | #line 2317 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2317 | #include "confdefs.h" |
| 2318 | #include <stdio.h> |
| 2319 | main() |
| 2320 | { |
| 2321 | FILE *f=fopen("conftestval", "w"); |
| 2322 | if (!f) exit(1); |
| 2323 | fprintf(f, "%d\n", sizeof(char)); |
| 2324 | exit(0); |
| 2325 | } |
| 2326 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2327 | if { (eval echo configure:2328: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2328 | then |
| 2329 | ac_cv_sizeof_char=`cat conftestval` |
| 2330 | else |
| 2331 | echo "configure: failed program was:" >&5 |
| 2332 | cat conftest.$ac_ext >&5 |
| 2333 | rm -fr conftest* |
| 2334 | ac_cv_sizeof_char=0 |
| 2335 | fi |
| 2336 | rm -fr conftest* |
| 2337 | fi |
| 2338 | |
| 2339 | fi |
| 2340 | echo "$ac_t""$ac_cv_sizeof_char" 1>&6 |
| 2341 | cat >> confdefs.h <<EOF |
| 2342 | #define SIZEOF_CHAR $ac_cv_sizeof_char |
| 2343 | EOF |
| 2344 | |
| 2345 | |
| 2346 | echo $ac_n "checking size of short""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2347 | echo "configure:2348: checking size of short" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2348 | if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2349 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2350 | else |
| 2351 | if test "$cross_compiling" = yes; then |
| 2352 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2353 | else |
| 2354 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2355 | #line 2356 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2356 | #include "confdefs.h" |
| 2357 | #include <stdio.h> |
| 2358 | main() |
| 2359 | { |
| 2360 | FILE *f=fopen("conftestval", "w"); |
| 2361 | if (!f) exit(1); |
| 2362 | fprintf(f, "%d\n", sizeof(short)); |
| 2363 | exit(0); |
| 2364 | } |
| 2365 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2366 | if { (eval echo configure:2367: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2367 | then |
| 2368 | ac_cv_sizeof_short=`cat conftestval` |
| 2369 | else |
| 2370 | echo "configure: failed program was:" >&5 |
| 2371 | cat conftest.$ac_ext >&5 |
| 2372 | rm -fr conftest* |
| 2373 | ac_cv_sizeof_short=0 |
| 2374 | fi |
| 2375 | rm -fr conftest* |
| 2376 | fi |
| 2377 | |
| 2378 | fi |
| 2379 | echo "$ac_t""$ac_cv_sizeof_short" 1>&6 |
| 2380 | cat >> confdefs.h <<EOF |
| 2381 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
| 2382 | EOF |
| 2383 | |
| 2384 | |
| 2385 | echo $ac_n "checking size of float""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2386 | echo "configure:2387: checking size of float" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2387 | if eval "test \"`echo '$''{'ac_cv_sizeof_float'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2388 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2389 | else |
| 2390 | if test "$cross_compiling" = yes; then |
| 2391 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2392 | else |
| 2393 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2394 | #line 2395 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2395 | #include "confdefs.h" |
| 2396 | #include <stdio.h> |
| 2397 | main() |
| 2398 | { |
| 2399 | FILE *f=fopen("conftestval", "w"); |
| 2400 | if (!f) exit(1); |
| 2401 | fprintf(f, "%d\n", sizeof(float)); |
| 2402 | exit(0); |
| 2403 | } |
| 2404 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2405 | if { (eval echo configure:2406: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2406 | then |
| 2407 | ac_cv_sizeof_float=`cat conftestval` |
| 2408 | else |
| 2409 | echo "configure: failed program was:" >&5 |
| 2410 | cat conftest.$ac_ext >&5 |
| 2411 | rm -fr conftest* |
| 2412 | ac_cv_sizeof_float=0 |
| 2413 | fi |
| 2414 | rm -fr conftest* |
| 2415 | fi |
| 2416 | |
| 2417 | fi |
| 2418 | echo "$ac_t""$ac_cv_sizeof_float" 1>&6 |
| 2419 | cat >> confdefs.h <<EOF |
| 2420 | #define SIZEOF_FLOAT $ac_cv_sizeof_float |
| 2421 | EOF |
| 2422 | |
| 2423 | |
| 2424 | echo $ac_n "checking size of double""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2425 | echo "configure:2426: checking size of double" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2426 | if eval "test \"`echo '$''{'ac_cv_sizeof_double'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2427 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2428 | else |
| 2429 | if test "$cross_compiling" = yes; then |
| 2430 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2431 | else |
| 2432 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2433 | #line 2434 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2434 | #include "confdefs.h" |
| 2435 | #include <stdio.h> |
| 2436 | main() |
| 2437 | { |
| 2438 | FILE *f=fopen("conftestval", "w"); |
| 2439 | if (!f) exit(1); |
| 2440 | fprintf(f, "%d\n", sizeof(double)); |
| 2441 | exit(0); |
| 2442 | } |
| 2443 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2444 | if { (eval echo configure:2445: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2445 | then |
| 2446 | ac_cv_sizeof_double=`cat conftestval` |
| 2447 | else |
| 2448 | echo "configure: failed program was:" >&5 |
| 2449 | cat conftest.$ac_ext >&5 |
| 2450 | rm -fr conftest* |
| 2451 | ac_cv_sizeof_double=0 |
| 2452 | fi |
| 2453 | rm -fr conftest* |
| 2454 | fi |
| 2455 | |
| 2456 | fi |
| 2457 | echo "$ac_t""$ac_cv_sizeof_double" 1>&6 |
| 2458 | cat >> confdefs.h <<EOF |
| 2459 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
| 2460 | EOF |
| 2461 | |
| 2462 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2463 | echo $ac_n "checking size of fpos_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2464 | echo "configure:2465: checking size of fpos_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2465 | if eval "test \"`echo '$''{'ac_cv_sizeof_fpos_t'+set}'`\" = set"; then |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2466 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2467 | else |
| 2468 | if test "$cross_compiling" = yes; then |
| 2469 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2470 | else |
| 2471 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2472 | #line 2473 "configure" |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2473 | #include "confdefs.h" |
| 2474 | #include <stdio.h> |
| 2475 | main() |
| 2476 | { |
| 2477 | FILE *f=fopen("conftestval", "w"); |
| 2478 | if (!f) exit(1); |
| 2479 | fprintf(f, "%d\n", sizeof(fpos_t)); |
| 2480 | exit(0); |
| 2481 | } |
| 2482 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2483 | if { (eval echo configure:2484: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2484 | then |
| 2485 | ac_cv_sizeof_fpos_t=`cat conftestval` |
| 2486 | else |
| 2487 | echo "configure: failed program was:" >&5 |
| 2488 | cat conftest.$ac_ext >&5 |
| 2489 | rm -fr conftest* |
| 2490 | ac_cv_sizeof_fpos_t=0 |
| 2491 | fi |
| 2492 | rm -fr conftest* |
| 2493 | fi |
| 2494 | |
| 2495 | fi |
| 2496 | echo "$ac_t""$ac_cv_sizeof_fpos_t" 1>&6 |
| 2497 | cat >> confdefs.h <<EOF |
| 2498 | #define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t |
| 2499 | EOF |
| 2500 | |
| 2501 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2502 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2503 | echo $ac_n "checking for long long support""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2504 | echo "configure:2505: checking for long long support" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2505 | have_long_long=no |
| 2506 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2507 | #line 2508 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2508 | #include "confdefs.h" |
| 2509 | |
| 2510 | int main() { |
| 2511 | long long x; x = (long long)0; |
| 2512 | ; return 0; } |
| 2513 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2514 | if { (eval echo configure:2515: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2515 | rm -rf conftest* |
| 2516 | cat >> confdefs.h <<\EOF |
| 2517 | #define HAVE_LONG_LONG 1 |
| 2518 | EOF |
| 2519 | have_long_long=yes |
| 2520 | else |
| 2521 | echo "configure: failed program was:" >&5 |
| 2522 | cat conftest.$ac_ext >&5 |
| 2523 | fi |
| 2524 | rm -f conftest* |
| 2525 | echo "$ac_t""$have_long_long" 1>&6 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2526 | if test "$have_long_long" = yes ; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2527 | echo $ac_n "checking size of long long""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2528 | echo "configure:2529: checking size of long long" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2529 | if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2530 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2531 | else |
| 2532 | if test "$cross_compiling" = yes; then |
| 2533 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2534 | else |
| 2535 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2536 | #line 2537 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2537 | #include "confdefs.h" |
| 2538 | #include <stdio.h> |
| 2539 | main() |
| 2540 | { |
| 2541 | FILE *f=fopen("conftestval", "w"); |
| 2542 | if (!f) exit(1); |
| 2543 | fprintf(f, "%d\n", sizeof(long long)); |
| 2544 | exit(0); |
| 2545 | } |
| 2546 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2547 | if { (eval echo configure:2548: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2548 | then |
| 2549 | ac_cv_sizeof_long_long=`cat conftestval` |
| 2550 | else |
| 2551 | echo "configure: failed program was:" >&5 |
| 2552 | cat conftest.$ac_ext >&5 |
| 2553 | rm -fr conftest* |
| 2554 | ac_cv_sizeof_long_long=0 |
| 2555 | fi |
| 2556 | rm -fr conftest* |
| 2557 | fi |
| 2558 | |
| 2559 | fi |
| 2560 | echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6 |
| 2561 | cat >> confdefs.h <<EOF |
| 2562 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
| 2563 | EOF |
| 2564 | |
| 2565 | |
| 2566 | fi |
| 2567 | |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2568 | echo $ac_n "checking for uintptr_t support""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2569 | echo "configure:2570: checking for uintptr_t support" >&5 |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2570 | have_uintptr_t=no |
| 2571 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2572 | #line 2573 "configure" |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2573 | #include "confdefs.h" |
| 2574 | |
| 2575 | int main() { |
| 2576 | uintptr_t x; x = (uintptr_t)0; |
| 2577 | ; return 0; } |
| 2578 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2579 | if { (eval echo configure:2580: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2580 | rm -rf conftest* |
| 2581 | cat >> confdefs.h <<\EOF |
| 2582 | #define HAVE_UINTPTR_T 1 |
| 2583 | EOF |
| 2584 | have_uintptr_t=yes |
| 2585 | else |
| 2586 | echo "configure: failed program was:" >&5 |
| 2587 | cat conftest.$ac_ext >&5 |
| 2588 | fi |
| 2589 | rm -f conftest* |
| 2590 | echo "$ac_t""$have_uintptr_t" 1>&6 |
| 2591 | if test "$have_uintptr_t" = yes ; then |
| 2592 | echo $ac_n "checking size of uintptr_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2593 | echo "configure:2594: checking size of uintptr_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2594 | if eval "test \"`echo '$''{'ac_cv_sizeof_uintptr_t'+set}'`\" = set"; then |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2595 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2596 | else |
| 2597 | if test "$cross_compiling" = yes; then |
| 2598 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2599 | else |
| 2600 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2601 | #line 2602 "configure" |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2602 | #include "confdefs.h" |
| 2603 | #include <stdio.h> |
| 2604 | main() |
| 2605 | { |
| 2606 | FILE *f=fopen("conftestval", "w"); |
| 2607 | if (!f) exit(1); |
| 2608 | fprintf(f, "%d\n", sizeof(uintptr_t)); |
| 2609 | exit(0); |
| 2610 | } |
| 2611 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2612 | if { (eval echo configure:2613: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2613 | then |
| 2614 | ac_cv_sizeof_uintptr_t=`cat conftestval` |
| 2615 | else |
| 2616 | echo "configure: failed program was:" >&5 |
| 2617 | cat conftest.$ac_ext >&5 |
| 2618 | rm -fr conftest* |
| 2619 | ac_cv_sizeof_uintptr_t=0 |
| 2620 | fi |
| 2621 | rm -fr conftest* |
| 2622 | fi |
| 2623 | |
| 2624 | fi |
| 2625 | echo "$ac_t""$ac_cv_sizeof_uintptr_t" 1>&6 |
| 2626 | cat >> confdefs.h <<EOF |
| 2627 | #define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t |
| 2628 | EOF |
| 2629 | |
| 2630 | |
| 2631 | fi |
| 2632 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2633 | # Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>. |
| 2634 | echo $ac_n "checking size of off_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2635 | echo "configure:2636: checking size of off_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2636 | if eval "test \"`echo '$''{'ac_cv_sizeof_off_t'+set}'`\" = set"; then |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2637 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2638 | else |
| 2639 | if test "$cross_compiling" = yes; then |
| 2640 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2641 | else |
| 2642 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2643 | #line 2644 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2644 | #include "confdefs.h" |
| 2645 | #include <stdio.h> |
| 2646 | #include <sys/types.h> |
| 2647 | main() |
| 2648 | { |
| 2649 | FILE *f=fopen("conftestval", "w"); |
| 2650 | if (!f) exit(1); |
| 2651 | fprintf(f, "%d\n", sizeof(off_t)); |
| 2652 | exit(0); |
| 2653 | } |
| 2654 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2655 | if { (eval echo configure:2656: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2656 | then |
| 2657 | ac_cv_sizeof_off_t=`cat conftestval` |
| 2658 | else |
| 2659 | echo "configure: failed program was:" >&5 |
| 2660 | cat conftest.$ac_ext >&5 |
| 2661 | rm -fr conftest* |
| 2662 | ac_cv_sizeof_off_t=0 |
| 2663 | fi |
| 2664 | rm -fr conftest* |
| 2665 | fi |
| 2666 | |
| 2667 | |
| 2668 | fi |
| 2669 | |
| 2670 | echo "$ac_t""$ac_cv_sizeof_off_t" 1>&6 |
| 2671 | cat >> confdefs.h <<EOF |
| 2672 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
| 2673 | EOF |
| 2674 | |
| 2675 | |
| 2676 | echo $ac_n "checking whether to enable large file support""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2677 | echo "configure:2678: checking whether to enable large file support" >&5 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2678 | if test "$have_long_long" = yes -a \ |
| 2679 | "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \ |
| 2680 | "$ac_cv_sizeof_long_long" -ge "$ac_cv_sizeof_off_t"; then |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2681 | cat >> confdefs.h <<\EOF |
| 2682 | #define HAVE_LARGEFILE_SUPPORT 1 |
| 2683 | EOF |
| 2684 | |
| 2685 | echo "$ac_t""yes" 1>&6 |
| 2686 | else |
| 2687 | echo "$ac_t""no" 1>&6 |
| 2688 | fi |
| 2689 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2690 | # AC_CHECK_SIZEOF() doesn't include <time.h>. |
| 2691 | echo $ac_n "checking size of time_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2692 | echo "configure:2693: checking size of time_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2693 | if eval "test \"`echo '$''{'ac_cv_sizeof_time_t'+set}'`\" = set"; then |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2694 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2695 | else |
| 2696 | if test "$cross_compiling" = yes; then |
| 2697 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2698 | else |
| 2699 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2700 | #line 2701 "configure" |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2701 | #include "confdefs.h" |
| 2702 | #include <stdio.h> |
| 2703 | #include <time.h> |
| 2704 | main() |
| 2705 | { |
| 2706 | FILE *f=fopen("conftestval", "w"); |
| 2707 | if (!f) exit(1); |
| 2708 | fprintf(f, "%d\n", sizeof(time_t)); |
| 2709 | exit(0); |
| 2710 | } |
| 2711 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2712 | if { (eval echo configure:2713: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2713 | then |
| 2714 | ac_cv_sizeof_time_t=`cat conftestval` |
| 2715 | else |
| 2716 | echo "configure: failed program was:" >&5 |
| 2717 | cat conftest.$ac_ext >&5 |
| 2718 | rm -fr conftest* |
| 2719 | ac_cv_sizeof_time_t=0 |
| 2720 | fi |
| 2721 | rm -fr conftest* |
| 2722 | fi |
| 2723 | |
| 2724 | |
| 2725 | fi |
| 2726 | |
| 2727 | echo "$ac_t""$ac_cv_sizeof_time_t" 1>&6 |
| 2728 | cat >> confdefs.h <<EOF |
| 2729 | #define SIZEOF_TIME_T $ac_cv_sizeof_time_t |
| 2730 | EOF |
| 2731 | |
| 2732 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2733 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2734 | # if have pthread_t then define SIZEOF_PTHREAD_T |
| 2735 | echo $ac_n "checking for pthread_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2736 | echo "configure:2737: checking for pthread_t" >&5 |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2737 | have_pthread_t=no |
| 2738 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2739 | #line 2740 "configure" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2740 | #include "confdefs.h" |
| 2741 | #include <pthread.h> |
| 2742 | int main() { |
Guido van Rossum | 1258049 | 2000-09-24 16:47:19 +0000 | [diff] [blame] | 2743 | pthread_t x; x = *(pthread_t*)0; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2744 | ; return 0; } |
| 2745 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2746 | if { (eval echo configure:2747: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2747 | rm -rf conftest* |
| 2748 | have_pthread_t=yes |
| 2749 | else |
| 2750 | echo "configure: failed program was:" >&5 |
| 2751 | cat conftest.$ac_ext >&5 |
| 2752 | fi |
| 2753 | rm -f conftest* |
| 2754 | echo "$ac_t""$have_pthread_t" 1>&6 |
| 2755 | if test "$have_pthread_t" = yes ; then |
| 2756 | # AC_CHECK_SIZEOF() doesn't include <pthread.h>. |
| 2757 | echo $ac_n "checking size of pthread_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2758 | echo "configure:2759: checking size of pthread_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2759 | if eval "test \"`echo '$''{'ac_cv_sizeof_pthread_t'+set}'`\" = set"; then |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2760 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2761 | else |
| 2762 | if test "$cross_compiling" = yes; then |
| 2763 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2764 | else |
| 2765 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2766 | #line 2767 "configure" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2767 | #include "confdefs.h" |
| 2768 | #include <stdio.h> |
| 2769 | #include <pthread.h> |
| 2770 | main() |
| 2771 | { |
| 2772 | FILE *f=fopen("conftestval", "w"); |
| 2773 | if (!f) exit(1); |
| 2774 | fprintf(f, "%d\n", sizeof(pthread_t)); |
| 2775 | exit(0); |
| 2776 | } |
| 2777 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2778 | if { (eval echo configure:2779: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2779 | then |
| 2780 | ac_cv_sizeof_pthread_t=`cat conftestval` |
| 2781 | else |
| 2782 | echo "configure: failed program was:" >&5 |
| 2783 | cat conftest.$ac_ext >&5 |
| 2784 | rm -fr conftest* |
| 2785 | ac_cv_sizeof_pthread_t=0 |
| 2786 | fi |
| 2787 | rm -fr conftest* |
| 2788 | fi |
| 2789 | |
| 2790 | |
| 2791 | fi |
| 2792 | |
| 2793 | echo "$ac_t""$ac_cv_sizeof_pthread_t" 1>&6 |
| 2794 | cat >> confdefs.h <<EOF |
| 2795 | #define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t |
| 2796 | EOF |
| 2797 | |
| 2798 | fi |
| 2799 | |
| 2800 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2801 | # Minor variations in building a framework between NextStep versions 4 and 5 |
| 2802 | |
| 2803 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 2804 | Darwin/*) |
| 2805 | ns_undef_sym='_environ' |
| 2806 | LIBTOOL_CRUFT="-lcc_dynamic -arch_only ppc -U $ns_undef_sym" ;; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2807 | next/4*) |
| 2808 | ns_undef_sym='__environ' |
| 2809 | LIBTOOL_CRUFT="-U $ns_undef_sym" ;; |
| 2810 | next/5*) |
| 2811 | ns_undef_sym='_environ' |
| 2812 | LIBTOOL_CRUFT="-lcc_dynamic -U $ns_undef_sym" ;; |
| 2813 | esac |
| 2814 | |
| 2815 | echo $ac_n "checking for --with-next-framework""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2816 | echo "configure:2817: checking for --with-next-framework" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2817 | if test "$with_next_framework" |
| 2818 | then |
| 2819 | OPT="$OPT -fno-common" |
| 2820 | # -U __environ is needed since bundles don't have access |
| 2821 | # to crt0 when built but will always be linked against it |
| 2822 | LDFLAGS="$LDFLAGS -Wl,-U,$ns_undef_sym" |
| 2823 | cat >> confdefs.h <<\EOF |
| 2824 | #define WITH_NEXT_FRAMEWORK 1 |
| 2825 | EOF |
| 2826 | |
| 2827 | echo "$ac_t""yes" 1>&6 |
| 2828 | else |
| 2829 | echo "$ac_t""no" 1>&6 |
| 2830 | fi |
| 2831 | |
| 2832 | echo $ac_n "checking for --with-dyld""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2833 | echo "configure:2834: checking for --with-dyld" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2834 | if test "$with_next_framework" -o "$with_dyld" |
| 2835 | then |
| 2836 | if test "$with_dyld" |
| 2837 | then |
| 2838 | echo "$ac_t""yes" 1>&6 |
| 2839 | else |
| 2840 | echo "$ac_t""required for framework build" 1>&6 |
| 2841 | fi |
| 2842 | cat >> confdefs.h <<\EOF |
| 2843 | #define WITH_DYLD 1 |
| 2844 | EOF |
| 2845 | |
| 2846 | ns_dyld='set' |
| 2847 | else |
| 2848 | echo "$ac_t""no" 1>&6 |
| 2849 | fi |
| 2850 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2851 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2852 | |
| 2853 | |
| 2854 | |
| 2855 | |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2856 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2857 | # SO is the extension of shared libraries `(including the dot!) |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 2858 | # -- usually .so, .sl on HP-UX, .dll on Cygwin |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2859 | echo $ac_n "checking SO""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2860 | echo "configure:2861: checking SO" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2861 | if test -z "$SO" |
| 2862 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2863 | case $ac_sys_system in |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2864 | hp*|HP*) SO=.sl;; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 2865 | CYGWIN*) SO=.dll;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2866 | *) SO=.so;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2867 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2868 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2869 | echo "$ac_t""$SO" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2870 | # LDSHARED is the ld *command* used to create shared library |
| 2871 | # -- "ld" on SunOS 4.x.x, "ld -G" on SunOS 5.x, "ld -shared" on IRIX 5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2872 | # (Shared libraries in this instance are shared modules to be loaded into |
| 2873 | # Python, as opposed to building Python itself as a shared library.) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2874 | echo $ac_n "checking LDSHARED""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2875 | echo "configure:2876: checking LDSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2876 | if test -z "$LDSHARED" |
| 2877 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2878 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2879 | AIX*) |
| 2880 | BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp" |
| 2881 | LDSHARED="\$(BINLIBDEST)/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/python.exp" |
| 2882 | ;; |
| 2883 | BeOS*) |
| 2884 | BLDSHARED="\$(srcdir)/Modules/ld_so_beos $LDLIBRARY" |
| 2885 | LDSHARED="\$(BINLIBDEST)/ld_so_beos \$(LIBDIR)/$LDLIBRARY" |
| 2886 | ;; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2887 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 2888 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2889 | SunOS/4*) LDSHARED="ld";; |
Greg Ward | 57c9a663 | 2000-05-26 12:22:54 +0000 | [diff] [blame] | 2890 | SunOS/5*) |
| 2891 | if test "$GCC" = "yes" |
Greg Ward | a1c4da2 | 2000-11-07 15:44:21 +0000 | [diff] [blame] | 2892 | then LDSHARED='$(CC) -shared' |
Greg Ward | 57c9a663 | 2000-05-26 12:22:54 +0000 | [diff] [blame] | 2893 | else LDSHARED="ld -G"; |
| 2894 | fi ;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2895 | hp*|HP*) LDSHARED="ld -b";; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2896 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
| 2897 | DYNIX/ptx*) LDSHARED="ld -G";; |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 2898 | Darwin/*|next/*) |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2899 | if test "$ns_dyld" |
Guido van Rossum | acb14c7 | 2001-01-10 21:41:16 +0000 | [diff] [blame] | 2900 | then LDSHARED='$(CC) $(LDFLAGS) -bundle -undefined suppress' |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2901 | else LDSHARED='$(CC) $(CFLAGS) -nostdlib -r'; |
| 2902 | fi |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 2903 | if test "$with_next_framework" ; then |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2904 | LDSHARED="$LDSHARED \$(LDLIBRARY)" |
| 2905 | fi ;; |
Guido van Rossum | 81652ab | 1996-07-21 02:53:27 +0000 | [diff] [blame] | 2906 | Linux*) LDSHARED="gcc -shared";; |
Guido van Rossum | 3c4bb80 | 1997-12-18 23:55:32 +0000 | [diff] [blame] | 2907 | dgux*) LDSHARED="ld -G";; |
Guido van Rossum | 458e7fa | 1999-09-17 15:40:40 +0000 | [diff] [blame] | 2908 | BSD/OS*/4*) LDSHARED="gcc -shared";; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 2909 | OpenBSD*) LDSHARED="ld -Bshareable";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2910 | NetBSD*) |
| 2911 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 2912 | then |
| 2913 | LDSHARED="cc -shared" |
| 2914 | else |
| 2915 | LDSHARED="ld -Bshareable" |
| 2916 | fi;; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 2917 | FreeBSD*) |
Jeremy Hylton | 4bcc7c5 | 2000-08-31 17:45:35 +0000 | [diff] [blame] | 2918 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 2919 | then |
| 2920 | LDSHARED="cc -shared ${LDFLAGS}" |
| 2921 | else |
| 2922 | LDSHARED="ld -Bshareable ${LDFLAGS}" |
| 2923 | fi;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2924 | SCO_SV*) LDSHARED="cc -G -KPIC -Ki486 -belf -Wl,-Bexport";; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2925 | Monterey*) LDSHARED="cc -G -dy -Bdynamic -Bexport -L/usr/lib/ia64l64";; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 2926 | CYGWIN*) LDSHARED="gcc -shared -Wl,--enable-auto-image-base";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2927 | *) LDSHARED="ld";; |
| 2928 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2929 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2930 | echo "$ac_t""$LDSHARED" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2931 | BLDSHARED=${BLDSHARED-$LDSHARED} |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2932 | # CCSHARED are the C *flags* used to create objects to go into a shared |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2933 | # library (module) -- this is only needed for a few systems |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2934 | echo $ac_n "checking CCSHARED""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2935 | echo "configure:2936: checking CCSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2936 | if test -z "$CCSHARED" |
| 2937 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2938 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 2939 | hp*|HP*) if test "$GCC" = yes; |
| 2940 | then CCSHARED="-fpic"; |
| 2941 | else CCSHARED="+z"; |
| 2942 | fi;; |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 2943 | Linux*) CCSHARED="-fPIC";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2944 | BSD/OS*/4*) CCSHARED="-fpic";; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 2945 | OpenBSD*) CCSHARED="-fpic";; |
| 2946 | FreeBSD*|NetBSD*) CCSHARED="-fPIC";; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2947 | SCO_SV*) CCSHARED="-KPIC -dy -Bdynamic";; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2948 | Monterey*) CCSHARED="-G";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2949 | IRIX*/6*) case $CC in |
| 2950 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 2951 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2952 | esac;; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 2953 | CYGWIN*) CCSHARED="-DUSE_DL_IMPORT";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2954 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2955 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2956 | echo "$ac_t""$CCSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2957 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2958 | # the python executable -- this is only needed for a few systems |
| 2959 | echo $ac_n "checking LINKFORSHARED""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2960 | echo "configure:2961: checking LINKFORSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2961 | if test -z "$LINKFORSHARED" |
| 2962 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2963 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2964 | AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2965 | hp*|HP*) |
Guido van Rossum | 304dd2d | 1997-10-20 23:10:56 +0000 | [diff] [blame] | 2966 | LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2967 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 2d9feed | 1997-11-24 17:36:21 +0000 | [diff] [blame] | 2968 | Linux*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2969 | # -u libsys_s pulls in all symbols in libsys |
| 2970 | next/2*|next/3*) LINKFORSHARED="-u libsys_s";; |
| 2971 | # -u __dummy makes the linker aware of the objc runtime |
| 2972 | # in System.framework; otherwise, __objcInit (referenced in |
| 2973 | # crt1.o) gets erroneously defined as common, which breaks dynamic |
| 2974 | # loading of any modules which reference it in System.framework |
| 2975 | next/4*|next/5*) LINKFORSHARED="-u __dummy -framework System" ;; |
Guido van Rossum | acb14c7 | 2001-01-10 21:41:16 +0000 | [diff] [blame] | 2976 | Darwin/*) LINKFORSHARED="-u __dummy -framework System -framework Foundation" ;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2977 | SCO_SV*) LINKFORSHARED="-Bdynamic -dy -Wl,-Bexport";; |
Fred Drake | 02706f5 | 2000-09-25 15:08:46 +0000 | [diff] [blame] | 2978 | ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 2979 | FreeBSD*|NetBSD*) |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2980 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 2981 | then |
| 2982 | LINKFORSHARED="-Wl,--export-dynamic" |
| 2983 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2984 | SunOS/5*) case $CC in |
| 2985 | *gcc*) |
Guido van Rossum | ff48418 | 2000-02-03 13:50:24 +0000 | [diff] [blame] | 2986 | if $CC -Xlinker -V 2>&1 | grep BFD >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 2987 | then |
| 2988 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2989 | fi;; |
| 2990 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2991 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2992 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2993 | echo "$ac_t""$LINKFORSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2994 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 2995 | |
| 2996 | echo $ac_n "checking CFLAGSFORSHARED""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 2997 | echo "configure:2998: checking CFLAGSFORSHARED" >&5 |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 2998 | if test ! "$LIBRARY" = "$LDLIBRARY" |
| 2999 | then |
Neil Schemenauer | 0c6141f | 2001-01-27 21:40:54 +0000 | [diff] [blame] | 3000 | case $ac_sys_system in |
| 3001 | CYGWIN*) |
| 3002 | # Cygwin needs CCSHARED when building extension DLLs |
| 3003 | # but not when building the interpreter DLL. |
| 3004 | CFLAGSFORSHARED='';; |
| 3005 | *) |
| 3006 | CFLAGSFORSHARED='$(CCSHARED)' |
| 3007 | esac |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 3008 | fi |
| 3009 | echo "$ac_t""$CFLAGSFORSHARED" 1>&6 |
| 3010 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3011 | # checks for libraries |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3012 | echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3013 | echo "configure:3014: checking for dlopen in -ldl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3014 | ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3015 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3016 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3017 | else |
| 3018 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3019 | LIBS="-ldl $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3020 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3021 | #line 3022 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3022 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3023 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3024 | /* We use char because int might match the return type of a gcc2 |
| 3025 | builtin and then its argument prototype would still apply. */ |
| 3026 | char dlopen(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3027 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3028 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3029 | dlopen() |
| 3030 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3031 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3032 | if { (eval echo configure:3033: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3033 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3034 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3035 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3036 | echo "configure: failed program was:" >&5 |
| 3037 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3038 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3039 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3040 | fi |
| 3041 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3042 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3043 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3044 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3045 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3046 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3047 | ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 3048 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3049 | cat >> confdefs.h <<EOF |
| 3050 | #define $ac_tr_lib 1 |
| 3051 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3052 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3053 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3054 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3055 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3056 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3057 | fi |
| 3058 | # Dynamic linking for SunOS/Solaris and SYSV |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3059 | echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3060 | echo "configure:3061: checking for shl_load in -ldld" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3061 | ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3062 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3063 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3064 | else |
| 3065 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3066 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3067 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3068 | #line 3069 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3069 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3070 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3071 | /* We use char because int might match the return type of a gcc2 |
| 3072 | builtin and then its argument prototype would still apply. */ |
| 3073 | char shl_load(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3074 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3075 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3076 | shl_load() |
| 3077 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3078 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3079 | if { (eval echo configure:3080: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3080 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3081 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3082 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3083 | echo "configure: failed program was:" >&5 |
| 3084 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3085 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3086 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3087 | fi |
| 3088 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3089 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3090 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3091 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3092 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3093 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3094 | ac_tr_lib=HAVE_LIB`echo dld | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 3095 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3096 | cat >> confdefs.h <<EOF |
| 3097 | #define $ac_tr_lib 1 |
| 3098 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3099 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3100 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3101 | |
| 3102 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3103 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3104 | fi |
| 3105 | # Dynamic linking for HP-UX |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 3106 | |
Skip Montanaro | cb85326 | 2000-08-30 22:29:48 +0000 | [diff] [blame] | 3107 | # Check for --with-pydebug |
| 3108 | echo $ac_n "checking for --with-pydebug""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3109 | echo "configure:3110: checking for --with-pydebug" >&5 |
Skip Montanaro | cb85326 | 2000-08-30 22:29:48 +0000 | [diff] [blame] | 3110 | # Check whether --with-pydebug or --without-pydebug was given. |
| 3111 | if test "${with_pydebug+set}" = set; then |
| 3112 | withval="$with_pydebug" |
| 3113 | |
| 3114 | if test "$withval" != no |
| 3115 | then cat >> confdefs.h <<\EOF |
| 3116 | #define Py_DEBUG 1 |
| 3117 | EOF |
| 3118 | echo "$ac_t""yes" 1>&6 |
| 3119 | else echo "$ac_t""no" 1>&6 |
| 3120 | fi |
| 3121 | else |
| 3122 | echo "$ac_t""no" 1>&6 |
| 3123 | fi |
| 3124 | |
| 3125 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 3126 | # checks for system dependent C++ extensions support |
| 3127 | case "$ac_sys_system" in |
| 3128 | AIX*) echo $ac_n "checking for genuine AIX C++ extensions support""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3129 | echo "configure:3130: checking for genuine AIX C++ extensions support" >&5 |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 3130 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3131 | #line 3132 "configure" |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 3132 | #include "confdefs.h" |
| 3133 | #include "/usr/lpp/xlC/include/load.h" |
| 3134 | int main() { |
| 3135 | loadAndInit("", 0, "") |
| 3136 | ; return 0; } |
| 3137 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3138 | if { (eval echo configure:3139: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 3139 | rm -rf conftest* |
| 3140 | cat >> confdefs.h <<\EOF |
| 3141 | #define AIX_GENUINE_CPLUSPLUS 1 |
| 3142 | EOF |
| 3143 | |
| 3144 | echo "$ac_t""yes" 1>&6 |
| 3145 | else |
| 3146 | echo "configure: failed program was:" >&5 |
| 3147 | cat conftest.$ac_ext >&5 |
| 3148 | rm -rf conftest* |
| 3149 | echo "$ac_t""no" 1>&6 |
| 3150 | fi |
| 3151 | rm -f conftest*;; |
| 3152 | *) ;; |
| 3153 | esac |
| 3154 | |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 3155 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
| 3156 | # However on SGI IRIX, these exist but are broken. |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3157 | # BeOS' sockets are stashed in libnet. |
| 3158 | case "$ac_sys_system" in |
| 3159 | IRIX*) ;; |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3160 | *) |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3161 | echo $ac_n "checking for t_open in -lnsl""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3162 | echo "configure:3163: checking for t_open in -lnsl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3163 | ac_lib_var=`echo nsl'_'t_open | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3164 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3165 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3166 | else |
| 3167 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3168 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3169 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3170 | #line 3171 "configure" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3171 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3172 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3173 | /* We use char because int might match the return type of a gcc2 |
| 3174 | builtin and then its argument prototype would still apply. */ |
| 3175 | char t_open(); |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3176 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3177 | int main() { |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 3178 | t_open() |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3179 | ; return 0; } |
| 3180 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3181 | if { (eval echo configure:3182: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3182 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3183 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3184 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3185 | echo "configure: failed program was:" >&5 |
| 3186 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3187 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3188 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3189 | fi |
| 3190 | rm -f conftest* |
| 3191 | LIBS="$ac_save_LIBS" |
| 3192 | |
| 3193 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3194 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3195 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3196 | LIBS="-lnsl $LIBS" |
| 3197 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3198 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3199 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 3200 | # SVR4 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3201 | echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3202 | echo "configure:3203: checking for socket in -lsocket" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3203 | ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3204 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3205 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3206 | else |
| 3207 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3208 | LIBS="-lsocket $LIBS $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3209 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3210 | #line 3211 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3211 | #include "confdefs.h" |
| 3212 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3213 | /* We use char because int might match the return type of a gcc2 |
| 3214 | builtin and then its argument prototype would still apply. */ |
| 3215 | char socket(); |
| 3216 | |
| 3217 | int main() { |
| 3218 | socket() |
| 3219 | ; return 0; } |
| 3220 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3221 | if { (eval echo configure:3222: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3222 | rm -rf conftest* |
| 3223 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3224 | else |
| 3225 | echo "configure: failed program was:" >&5 |
| 3226 | cat conftest.$ac_ext >&5 |
| 3227 | rm -rf conftest* |
| 3228 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3229 | fi |
| 3230 | rm -f conftest* |
| 3231 | LIBS="$ac_save_LIBS" |
| 3232 | |
| 3233 | fi |
| 3234 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3235 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3236 | LIBS="-lsocket $LIBS" |
| 3237 | else |
| 3238 | echo "$ac_t""no" 1>&6 |
| 3239 | fi |
| 3240 | # SVR4 sockets |
Jeremy Hylton | cb25d5e | 2000-07-27 21:23:28 +0000 | [diff] [blame] | 3241 | ;; |
| 3242 | esac |
| 3243 | case "$ac_sys_system" in |
| 3244 | BeOS*) |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3245 | echo $ac_n "checking for socket in -lnet""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3246 | echo "configure:3247: checking for socket in -lnet" >&5 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3247 | ac_lib_var=`echo net'_'socket | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3248 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3249 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3250 | else |
| 3251 | ac_save_LIBS="$LIBS" |
| 3252 | LIBS="-lnet $LIBS $LIBS" |
| 3253 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3254 | #line 3255 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3255 | #include "confdefs.h" |
| 3256 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3257 | /* We use char because int might match the return type of a gcc2 |
| 3258 | builtin and then its argument prototype would still apply. */ |
| 3259 | char socket(); |
| 3260 | |
| 3261 | int main() { |
| 3262 | socket() |
| 3263 | ; return 0; } |
| 3264 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3265 | if { (eval echo configure:3266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3266 | rm -rf conftest* |
| 3267 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3268 | else |
| 3269 | echo "configure: failed program was:" >&5 |
| 3270 | cat conftest.$ac_ext >&5 |
| 3271 | rm -rf conftest* |
| 3272 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3273 | fi |
| 3274 | rm -f conftest* |
| 3275 | LIBS="$ac_save_LIBS" |
| 3276 | |
| 3277 | fi |
| 3278 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3279 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3280 | LIBS="-lnet $LIBS" |
| 3281 | else |
| 3282 | echo "$ac_t""no" 1>&6 |
| 3283 | fi |
| 3284 | # BeOS |
| 3285 | ;; |
| 3286 | esac |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 3287 | |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 3288 | echo $ac_n "checking for --with-libs""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3289 | echo "configure:3290: checking for --with-libs" >&5 |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 3290 | # Check whether --with-libs or --without-libs was given. |
| 3291 | if test "${with_libs+set}" = set; then |
| 3292 | withval="$with_libs" |
| 3293 | |
| 3294 | echo "$ac_t""$withval" 1>&6 |
| 3295 | LIBS="$withval $LIBS" |
| 3296 | |
| 3297 | else |
| 3298 | echo "$ac_t""no" 1>&6 |
| 3299 | fi |
| 3300 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3301 | |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3302 | # |
| 3303 | # These are used to generate Setup.config. They autoconfigure several |
| 3304 | # features that are otherwise severe pains in the butt. |
| 3305 | # |
| 3306 | # ncurses |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 3307 | |
| 3308 | echo $ac_n "checking for initscr in -lncurses""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3309 | echo "configure:3310: checking for initscr in -lncurses" >&5 |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 3310 | ac_lib_var=`echo ncurses'_'initscr | sed 'y%./+-%__p_%'` |
| 3311 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3312 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3313 | else |
| 3314 | ac_save_LIBS="$LIBS" |
| 3315 | LIBS="-lncurses -ltermcap $LIBS" |
| 3316 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3317 | #line 3318 "configure" |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 3318 | #include "confdefs.h" |
| 3319 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3320 | /* We use char because int might match the return type of a gcc2 |
| 3321 | builtin and then its argument prototype would still apply. */ |
| 3322 | char initscr(); |
| 3323 | |
| 3324 | int main() { |
| 3325 | initscr() |
| 3326 | ; return 0; } |
| 3327 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3328 | if { (eval echo configure:3329: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 3329 | rm -rf conftest* |
| 3330 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3331 | else |
| 3332 | echo "configure: failed program was:" >&5 |
| 3333 | cat conftest.$ac_ext >&5 |
| 3334 | rm -rf conftest* |
| 3335 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3336 | fi |
| 3337 | rm -f conftest* |
| 3338 | LIBS="$ac_save_LIBS" |
| 3339 | |
| 3340 | fi |
| 3341 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3342 | echo "$ac_t""yes" 1>&6 |
| 3343 | USE_NCURSES_MODULE="" |
| 3344 | else |
| 3345 | echo "$ac_t""no" 1>&6 |
| 3346 | USE_NCURSES_MODULE="#" |
| 3347 | fi |
| 3348 | |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3349 | # GNU readline |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 3350 | |
| 3351 | echo $ac_n "checking for readline in -lreadline""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3352 | echo "configure:3353: checking for readline in -lreadline" >&5 |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 3353 | ac_lib_var=`echo readline'_'readline | sed 'y%./+-%__p_%'` |
| 3354 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3355 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3356 | else |
| 3357 | ac_save_LIBS="$LIBS" |
| 3358 | LIBS="-lreadline -ltermcap $LIBS" |
| 3359 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3360 | #line 3361 "configure" |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 3361 | #include "confdefs.h" |
| 3362 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3363 | /* We use char because int might match the return type of a gcc2 |
| 3364 | builtin and then its argument prototype would still apply. */ |
| 3365 | char readline(); |
| 3366 | |
| 3367 | int main() { |
| 3368 | readline() |
| 3369 | ; return 0; } |
| 3370 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3371 | if { (eval echo configure:3372: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 3372 | rm -rf conftest* |
| 3373 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3374 | else |
| 3375 | echo "configure: failed program was:" >&5 |
| 3376 | cat conftest.$ac_ext >&5 |
| 3377 | rm -rf conftest* |
| 3378 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3379 | fi |
| 3380 | rm -f conftest* |
| 3381 | LIBS="$ac_save_LIBS" |
| 3382 | |
| 3383 | fi |
| 3384 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3385 | echo "$ac_t""yes" 1>&6 |
| 3386 | USE_READLINE_MODULE="" |
| 3387 | else |
| 3388 | echo "$ac_t""no" 1>&6 |
| 3389 | USE_READLINE_MODULE="#" |
| 3390 | fi |
| 3391 | |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3392 | # gdbm(3) |
| 3393 | |
| 3394 | |
| 3395 | echo $ac_n "checking for gdbm_open in -lgdbm""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3396 | echo "configure:3397: checking for gdbm_open in -lgdbm" >&5 |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3397 | ac_lib_var=`echo gdbm'_'gdbm_open | sed 'y%./+-%__p_%'` |
| 3398 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3399 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3400 | else |
| 3401 | ac_save_LIBS="$LIBS" |
| 3402 | LIBS="-lgdbm $LIBS" |
| 3403 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3404 | #line 3405 "configure" |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3405 | #include "confdefs.h" |
| 3406 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3407 | /* We use char because int might match the return type of a gcc2 |
| 3408 | builtin and then its argument prototype would still apply. */ |
| 3409 | char gdbm_open(); |
| 3410 | |
| 3411 | int main() { |
| 3412 | gdbm_open() |
| 3413 | ; return 0; } |
| 3414 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3415 | if { (eval echo configure:3416: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3416 | rm -rf conftest* |
| 3417 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3418 | else |
| 3419 | echo "configure: failed program was:" >&5 |
| 3420 | cat conftest.$ac_ext >&5 |
| 3421 | rm -rf conftest* |
| 3422 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3423 | fi |
| 3424 | rm -f conftest* |
| 3425 | LIBS="$ac_save_LIBS" |
| 3426 | |
| 3427 | fi |
| 3428 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3429 | echo "$ac_t""yes" 1>&6 |
| 3430 | USE_GDBM_MODULE="" |
| 3431 | HAVE_LIBGDBM=-lgdbm |
| 3432 | else |
| 3433 | echo "$ac_t""no" 1>&6 |
| 3434 | USE_GDBM_MODULE="#" |
| 3435 | HAVE_LIBGDBM="" |
| 3436 | fi |
| 3437 | |
| 3438 | # ndbm(3) |
| 3439 | |
| 3440 | |
| 3441 | echo $ac_n "checking for ndbm_open in -lndbm""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3442 | echo "configure:3443: checking for ndbm_open in -lndbm" >&5 |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3443 | ac_lib_var=`echo ndbm'_'ndbm_open | sed 'y%./+-%__p_%'` |
| 3444 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3445 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3446 | else |
| 3447 | ac_save_LIBS="$LIBS" |
| 3448 | LIBS="-lndbm $LIBS" |
| 3449 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3450 | #line 3451 "configure" |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3451 | #include "confdefs.h" |
| 3452 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3453 | /* We use char because int might match the return type of a gcc2 |
| 3454 | builtin and then its argument prototype would still apply. */ |
| 3455 | char ndbm_open(); |
| 3456 | |
| 3457 | int main() { |
| 3458 | ndbm_open() |
| 3459 | ; return 0; } |
| 3460 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3461 | if { (eval echo configure:3462: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3462 | rm -rf conftest* |
| 3463 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3464 | else |
| 3465 | echo "configure: failed program was:" >&5 |
| 3466 | cat conftest.$ac_ext >&5 |
| 3467 | rm -rf conftest* |
| 3468 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3469 | fi |
| 3470 | rm -f conftest* |
| 3471 | LIBS="$ac_save_LIBS" |
| 3472 | |
| 3473 | fi |
| 3474 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3475 | echo "$ac_t""yes" 1>&6 |
| 3476 | USE_NDBM_MODULE="" |
| 3477 | HAVE_LIBNDBM=-lndbm |
| 3478 | else |
| 3479 | echo "$ac_t""no" 1>&6 |
| 3480 | USE_NDBM_MODULE="#" |
| 3481 | HAVE_LIBNDBM="" |
| 3482 | fi |
| 3483 | |
| 3484 | # crypt(3) |
| 3485 | |
| 3486 | |
| 3487 | echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3488 | echo "configure:3489: checking for crypt in -lcrypt" >&5 |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3489 | ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'` |
| 3490 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3491 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3492 | else |
| 3493 | ac_save_LIBS="$LIBS" |
| 3494 | LIBS="-lcrypt $LIBS" |
| 3495 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3496 | #line 3497 "configure" |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3497 | #include "confdefs.h" |
| 3498 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3499 | /* We use char because int might match the return type of a gcc2 |
| 3500 | builtin and then its argument prototype would still apply. */ |
| 3501 | char crypt(); |
| 3502 | |
| 3503 | int main() { |
| 3504 | crypt() |
| 3505 | ; return 0; } |
| 3506 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3507 | if { (eval echo configure:3508: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 3508 | rm -rf conftest* |
| 3509 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3510 | else |
| 3511 | echo "configure: failed program was:" >&5 |
| 3512 | cat conftest.$ac_ext >&5 |
| 3513 | rm -rf conftest* |
| 3514 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3515 | fi |
| 3516 | rm -f conftest* |
| 3517 | LIBS="$ac_save_LIBS" |
| 3518 | |
| 3519 | fi |
| 3520 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3521 | echo "$ac_t""yes" 1>&6 |
| 3522 | USE_CRYPT_MODULE="" |
| 3523 | HAVE_LIBCRYPT=-lcrypt |
| 3524 | else |
| 3525 | echo "$ac_t""no" 1>&6 |
| 3526 | USE_CRYPT_MODULE="#" |
| 3527 | HAVE_LIBCRYPT="" |
| 3528 | fi |
| 3529 | |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 3530 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3531 | |
| 3532 | # Determine if signalmodule should be used. |
| 3533 | |
| 3534 | |
| 3535 | echo $ac_n "checking for --with-signal-module""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3536 | echo "configure:3537: checking for --with-signal-module" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3537 | # Check whether --with-signal-module or --without-signal-module was given. |
| 3538 | if test "${with_signal_module+set}" = set; then |
| 3539 | withval="$with_signal_module" |
| 3540 | : |
| 3541 | fi |
| 3542 | |
| 3543 | |
| 3544 | if test -z "$with_signal_module" |
| 3545 | then with_signal_module="yes" |
| 3546 | fi |
| 3547 | echo "$ac_t""$with_signal_module" 1>&6 |
| 3548 | |
| 3549 | if test "${with_signal_module}" = "yes"; then |
| 3550 | USE_SIGNAL_MODULE="" |
| 3551 | SIGNAL_OBJS="" |
| 3552 | else |
| 3553 | USE_SIGNAL_MODULE="#" |
| 3554 | SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o" |
| 3555 | fi |
| 3556 | |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 3557 | # This is used to generate Setup.config |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 3558 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3559 | USE_THREAD_MODULE="" |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 3560 | |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3561 | echo $ac_n "checking for --with-dec-threads""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3562 | echo "configure:3563: checking for --with-dec-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3563 | |
| 3564 | # Check whether --with-dec-threads or --without-dec-threads was given. |
| 3565 | if test "${with_dec_threads+set}" = set; then |
| 3566 | withval="$with_dec_threads" |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3567 | |
| 3568 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3569 | LDLAST=-threads |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3570 | if test "${with_thread+set}" != set; then |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3571 | with_thread="$withval"; |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3572 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3573 | else |
| 3574 | echo "$ac_t""no" 1>&6 |
| 3575 | fi |
| 3576 | |
| 3577 | |
| 3578 | echo $ac_n "checking for --with-threads""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3579 | echo "configure:3580: checking for --with-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3580 | # Check whether --with-threads or --without-threads was given. |
| 3581 | if test "${with_threads+set}" = set; then |
| 3582 | withval="$with_threads" |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3583 | : |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3584 | fi |
| 3585 | |
| 3586 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3587 | # --with-thread is deprecated, but check for it anyway |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3588 | # Check whether --with-thread or --without-thread was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3589 | if test "${with_thread+set}" = set; then |
| 3590 | withval="$with_thread" |
Barry Warsaw | a0f3c5c | 2000-06-30 16:39:35 +0000 | [diff] [blame] | 3591 | |
| 3592 | with_threads=$with_thread |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3593 | fi |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3594 | |
| 3595 | |
| 3596 | if test -z "$with_threads" |
| 3597 | then with_threads="yes" |
| 3598 | fi |
| 3599 | echo "$ac_t""$with_threads" 1>&6 |
| 3600 | |
| 3601 | if test "$with_threads" = "no" |
| 3602 | then |
| 3603 | USE_THREAD_MODULE="#" |
| 3604 | else |
Guido van Rossum | 4095101 | 2000-10-07 16:21:27 +0000 | [diff] [blame] | 3605 | if test ! -z "$with_threads" -a -d "$with_threads" |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3606 | then LDFLAGS="$LDFLAGS -L$with_threads" |
| 3607 | fi |
Guido van Rossum | 4095101 | 2000-10-07 16:21:27 +0000 | [diff] [blame] | 3608 | if test ! -z "$withval" -a -d "$withval" |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3609 | then LDFLAGS="$LDFLAGS -L$withval" |
| 3610 | fi |
| 3611 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 3612 | #define _REENTRANT 1 |
| 3613 | EOF |
| 3614 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3615 | ac_safe=`echo "mach/cthreads.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3616 | echo $ac_n "checking for mach/cthreads.h""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3617 | echo "configure:3618: checking for mach/cthreads.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3618 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3619 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3620 | else |
| 3621 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3622 | #line 3623 "configure" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3623 | #include "confdefs.h" |
| 3624 | #include <mach/cthreads.h> |
| 3625 | EOF |
| 3626 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3627 | { (eval echo configure:3628: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3628 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3629 | if test -z "$ac_err"; then |
| 3630 | rm -rf conftest* |
| 3631 | eval "ac_cv_header_$ac_safe=yes" |
| 3632 | else |
| 3633 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3634 | echo "configure: failed program was:" >&5 |
| 3635 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3636 | rm -rf conftest* |
| 3637 | eval "ac_cv_header_$ac_safe=no" |
| 3638 | fi |
| 3639 | rm -f conftest* |
| 3640 | fi |
| 3641 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 3642 | echo "$ac_t""yes" 1>&6 |
| 3643 | cat >> confdefs.h <<\EOF |
| 3644 | #define WITH_THREAD 1 |
| 3645 | EOF |
| 3646 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3647 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3648 | #define C_THREADS 1 |
| 3649 | EOF |
| 3650 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3651 | LIBOBJS="$LIBOBJS Python/thread.o" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3652 | else |
| 3653 | echo "$ac_t""no" 1>&6 |
| 3654 | |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 3655 | echo $ac_n "checking for --with-pth""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3656 | echo "configure:3657: checking for --with-pth" >&5 |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 3657 | # Check whether --with-pth or --without-pth was given. |
| 3658 | if test "${with_pth+set}" = set; then |
| 3659 | withval="$with_pth" |
| 3660 | |
| 3661 | echo "$ac_t""$withval" 1>&6 |
| 3662 | cat >> confdefs.h <<\EOF |
| 3663 | #define WITH_THREAD 1 |
| 3664 | EOF |
| 3665 | |
| 3666 | cat >> confdefs.h <<\EOF |
| 3667 | #define HAVE_PTH 1 |
| 3668 | EOF |
| 3669 | |
| 3670 | LIBS="-lpth $LIBS" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3671 | LIBOBJS="$LIBOBJS Python/thread.o" |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 3672 | else |
| 3673 | |
| 3674 | echo "$ac_t""no" 1>&6 |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3675 | echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3676 | echo "configure:3677: checking for pthread_create in -lpthread" >&5 |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3677 | ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3678 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3679 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3680 | else |
| 3681 | ac_save_LIBS="$LIBS" |
| 3682 | LIBS="-lpthread $LIBS" |
| 3683 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3684 | #line 3685 "configure" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3685 | #include "confdefs.h" |
| 3686 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3687 | /* We use char because int might match the return type of a gcc2 |
| 3688 | builtin and then its argument prototype would still apply. */ |
| 3689 | char pthread_create(); |
| 3690 | |
| 3691 | int main() { |
| 3692 | pthread_create() |
| 3693 | ; return 0; } |
| 3694 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3695 | if { (eval echo configure:3696: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3696 | rm -rf conftest* |
| 3697 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3698 | else |
| 3699 | echo "configure: failed program was:" >&5 |
| 3700 | cat conftest.$ac_ext >&5 |
| 3701 | rm -rf conftest* |
| 3702 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3703 | fi |
| 3704 | rm -f conftest* |
| 3705 | LIBS="$ac_save_LIBS" |
| 3706 | |
| 3707 | fi |
| 3708 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3709 | echo "$ac_t""yes" 1>&6 |
| 3710 | cat >> confdefs.h <<\EOF |
| 3711 | #define WITH_THREAD 1 |
| 3712 | EOF |
| 3713 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3714 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3715 | #define _POSIX_THREADS 1 |
| 3716 | EOF |
| 3717 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3718 | LIBS="-lpthread $LIBS" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3719 | LIBOBJS="$LIBOBJS Python/thread.o" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3720 | else |
| 3721 | echo "$ac_t""no" 1>&6 |
| 3722 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3723 | echo $ac_n "checking for pthread_detach""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3724 | echo "configure:3725: checking for pthread_detach" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3725 | if eval "test \"`echo '$''{'ac_cv_func_pthread_detach'+set}'`\" = set"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3726 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3727 | else |
| 3728 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3729 | #line 3730 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3730 | #include "confdefs.h" |
| 3731 | /* System header to define __stub macros and hopefully few prototypes, |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3732 | which can conflict with char pthread_detach(); below. */ |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3733 | #include <assert.h> |
| 3734 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3735 | /* We use char because int might match the return type of a gcc2 |
| 3736 | builtin and then its argument prototype would still apply. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3737 | char pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3738 | |
| 3739 | int main() { |
| 3740 | |
| 3741 | /* The GNU C library defines this for functions which it implements |
| 3742 | to always fail with ENOSYS. Some functions are actually named |
| 3743 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3744 | #if defined (__stub_pthread_detach) || defined (__stub___pthread_detach) |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3745 | choke me |
| 3746 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3747 | pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3748 | #endif |
| 3749 | |
| 3750 | ; return 0; } |
| 3751 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3752 | if { (eval echo configure:3753: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3753 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3754 | eval "ac_cv_func_pthread_detach=yes" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3755 | else |
| 3756 | echo "configure: failed program was:" >&5 |
| 3757 | cat conftest.$ac_ext >&5 |
| 3758 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3759 | eval "ac_cv_func_pthread_detach=no" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3760 | fi |
| 3761 | rm -f conftest* |
| 3762 | fi |
| 3763 | |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3764 | if eval "test \"`echo '$ac_cv_func_'pthread_detach`\" = yes"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3765 | echo "$ac_t""yes" 1>&6 |
| 3766 | cat >> confdefs.h <<\EOF |
| 3767 | #define WITH_THREAD 1 |
| 3768 | EOF |
| 3769 | |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 3770 | case $ac_sys_system in |
| 3771 | Darwin*) ;; |
| 3772 | *) cat >> confdefs.h <<\EOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3773 | #define _POSIX_THREADS 1 |
| 3774 | EOF |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 3775 | ;; |
| 3776 | esac |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3777 | LIBOBJS="$LIBOBJS Python/thread.o" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3778 | else |
| 3779 | echo "$ac_t""no" 1>&6 |
| 3780 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3781 | ac_safe=`echo "kernel/OS.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3782 | echo $ac_n "checking for kernel/OS.h""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3783 | echo "configure:3784: checking for kernel/OS.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3784 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3785 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3786 | else |
| 3787 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3788 | #line 3789 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3789 | #include "confdefs.h" |
| 3790 | #include <kernel/OS.h> |
| 3791 | EOF |
| 3792 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3793 | { (eval echo configure:3794: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3794 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3795 | if test -z "$ac_err"; then |
| 3796 | rm -rf conftest* |
| 3797 | eval "ac_cv_header_$ac_safe=yes" |
| 3798 | else |
| 3799 | echo "$ac_err" >&5 |
| 3800 | echo "configure: failed program was:" >&5 |
| 3801 | cat conftest.$ac_ext >&5 |
| 3802 | rm -rf conftest* |
| 3803 | eval "ac_cv_header_$ac_safe=no" |
| 3804 | fi |
| 3805 | rm -f conftest* |
| 3806 | fi |
| 3807 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 3808 | echo "$ac_t""yes" 1>&6 |
| 3809 | cat >> confdefs.h <<\EOF |
| 3810 | #define WITH_THREAD 1 |
| 3811 | EOF |
| 3812 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3813 | cat >> confdefs.h <<\EOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3814 | #define BEOS_THREADS 1 |
| 3815 | EOF |
| 3816 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3817 | LIBOBJS="$LIBOBJS Python/thread.o" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3818 | else |
| 3819 | echo "$ac_t""no" 1>&6 |
| 3820 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3821 | echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3822 | echo "configure:3823: checking for pthread_create in -lpthreads" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3823 | ac_lib_var=`echo pthreads'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3824 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3825 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3826 | else |
| 3827 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3828 | LIBS="-lpthreads $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3829 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3830 | #line 3831 "configure" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3831 | #include "confdefs.h" |
| 3832 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3833 | /* We use char because int might match the return type of a gcc2 |
| 3834 | builtin and then its argument prototype would still apply. */ |
| 3835 | char pthread_create(); |
| 3836 | |
| 3837 | int main() { |
| 3838 | pthread_create() |
| 3839 | ; return 0; } |
| 3840 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3841 | if { (eval echo configure:3842: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3842 | rm -rf conftest* |
| 3843 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3844 | else |
| 3845 | echo "configure: failed program was:" >&5 |
| 3846 | cat conftest.$ac_ext >&5 |
| 3847 | rm -rf conftest* |
| 3848 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3849 | fi |
| 3850 | rm -f conftest* |
| 3851 | LIBS="$ac_save_LIBS" |
| 3852 | |
| 3853 | fi |
| 3854 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3855 | echo "$ac_t""yes" 1>&6 |
| 3856 | cat >> confdefs.h <<\EOF |
| 3857 | #define WITH_THREAD 1 |
| 3858 | EOF |
| 3859 | |
| 3860 | cat >> confdefs.h <<\EOF |
| 3861 | #define _POSIX_THREADS 1 |
| 3862 | EOF |
| 3863 | |
| 3864 | LIBS="$LIBS -lpthreads" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3865 | LIBOBJS="$LIBOBJS Python/thread.o" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3866 | else |
| 3867 | echo "$ac_t""no" 1>&6 |
| 3868 | |
| 3869 | echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3870 | echo "configure:3871: checking for pthread_create in -lc_r" >&5 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3871 | ac_lib_var=`echo c_r'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3872 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3873 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3874 | else |
| 3875 | ac_save_LIBS="$LIBS" |
| 3876 | LIBS="-lc_r $LIBS" |
| 3877 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3878 | #line 3879 "configure" |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3879 | #include "confdefs.h" |
| 3880 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3881 | /* We use char because int might match the return type of a gcc2 |
| 3882 | builtin and then its argument prototype would still apply. */ |
| 3883 | char pthread_create(); |
| 3884 | |
| 3885 | int main() { |
| 3886 | pthread_create() |
| 3887 | ; return 0; } |
| 3888 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3889 | if { (eval echo configure:3890: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3890 | rm -rf conftest* |
| 3891 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3892 | else |
| 3893 | echo "configure: failed program was:" >&5 |
| 3894 | cat conftest.$ac_ext >&5 |
| 3895 | rm -rf conftest* |
| 3896 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3897 | fi |
| 3898 | rm -f conftest* |
| 3899 | LIBS="$ac_save_LIBS" |
| 3900 | |
| 3901 | fi |
| 3902 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3903 | echo "$ac_t""yes" 1>&6 |
| 3904 | cat >> confdefs.h <<\EOF |
| 3905 | #define WITH_THREAD 1 |
| 3906 | EOF |
| 3907 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3908 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3909 | #define _POSIX_THREADS 1 |
| 3910 | EOF |
| 3911 | |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3912 | LIBS="$LIBS -lc_r" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3913 | LIBOBJS="$LIBOBJS Python/thread.o" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3914 | else |
| 3915 | echo "$ac_t""no" 1>&6 |
| 3916 | |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3917 | echo $ac_n "checking for __d6_pthread_create in -lthread""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3918 | echo "configure:3919: checking for __d6_pthread_create in -lthread" >&5 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3919 | ac_lib_var=`echo thread'_'__d6_pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3920 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3921 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3922 | else |
| 3923 | ac_save_LIBS="$LIBS" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3924 | LIBS="-lthread $LIBS" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3925 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3926 | #line 3927 "configure" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3927 | #include "confdefs.h" |
| 3928 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3929 | /* We use char because int might match the return type of a gcc2 |
| 3930 | builtin and then its argument prototype would still apply. */ |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3931 | char __d6_pthread_create(); |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3932 | |
| 3933 | int main() { |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3934 | __d6_pthread_create() |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3935 | ; return 0; } |
| 3936 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3937 | if { (eval echo configure:3938: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3938 | rm -rf conftest* |
| 3939 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3940 | else |
| 3941 | echo "configure: failed program was:" >&5 |
| 3942 | cat conftest.$ac_ext >&5 |
| 3943 | rm -rf conftest* |
| 3944 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3945 | fi |
| 3946 | rm -f conftest* |
| 3947 | LIBS="$ac_save_LIBS" |
| 3948 | |
| 3949 | fi |
| 3950 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3951 | echo "$ac_t""yes" 1>&6 |
| 3952 | cat >> confdefs.h <<\EOF |
| 3953 | #define WITH_THREAD 1 |
| 3954 | EOF |
| 3955 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3956 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3957 | #define _POSIX_THREADS 1 |
| 3958 | EOF |
| 3959 | |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3960 | LIBS="$LIBS -lthread" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3961 | LIBOBJS="$LIBOBJS Python/thread.o" |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3962 | else |
| 3963 | echo "$ac_t""no" 1>&6 |
| 3964 | |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3965 | echo $ac_n "checking for __pthread_create_system in -lpthread""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3966 | echo "configure:3967: checking for __pthread_create_system in -lpthread" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3967 | ac_lib_var=`echo pthread'_'__pthread_create_system | sed 'y%./+-%__p_%'` |
| 3968 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 3969 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3970 | else |
| 3971 | ac_save_LIBS="$LIBS" |
| 3972 | LIBS="-lpthread $LIBS" |
| 3973 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3974 | #line 3975 "configure" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3975 | #include "confdefs.h" |
| 3976 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3977 | /* We use char because int might match the return type of a gcc2 |
| 3978 | builtin and then its argument prototype would still apply. */ |
| 3979 | char __pthread_create_system(); |
| 3980 | |
| 3981 | int main() { |
| 3982 | __pthread_create_system() |
| 3983 | ; return 0; } |
| 3984 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 3985 | if { (eval echo configure:3986: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3986 | rm -rf conftest* |
| 3987 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3988 | else |
| 3989 | echo "configure: failed program was:" >&5 |
| 3990 | cat conftest.$ac_ext >&5 |
| 3991 | rm -rf conftest* |
| 3992 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3993 | fi |
| 3994 | rm -f conftest* |
| 3995 | LIBS="$ac_save_LIBS" |
| 3996 | |
| 3997 | fi |
| 3998 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3999 | echo "$ac_t""yes" 1>&6 |
| 4000 | cat >> confdefs.h <<\EOF |
| 4001 | #define WITH_THREAD 1 |
| 4002 | EOF |
| 4003 | |
| 4004 | cat >> confdefs.h <<\EOF |
| 4005 | #define _POSIX_THREADS 1 |
| 4006 | EOF |
| 4007 | |
| 4008 | LIBS="$LIBS -lpthread" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 4009 | LIBOBJS="$LIBOBJS Python/thread.o" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4010 | else |
| 4011 | echo "$ac_t""no" 1>&6 |
| 4012 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 4013 | echo $ac_n "checking for pthread_create in -lcma""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4014 | echo "configure:4015: checking for pthread_create in -lcma" >&5 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4015 | ac_lib_var=`echo cma'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4016 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4017 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4018 | else |
| 4019 | ac_save_LIBS="$LIBS" |
| 4020 | LIBS="-lcma $LIBS" |
| 4021 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4022 | #line 4023 "configure" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4023 | #include "confdefs.h" |
| 4024 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4025 | /* We use char because int might match the return type of a gcc2 |
| 4026 | builtin and then its argument prototype would still apply. */ |
| 4027 | char pthread_create(); |
| 4028 | |
| 4029 | int main() { |
| 4030 | pthread_create() |
| 4031 | ; return 0; } |
| 4032 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4033 | if { (eval echo configure:4034: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4034 | rm -rf conftest* |
| 4035 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 4036 | else |
| 4037 | echo "configure: failed program was:" >&5 |
| 4038 | cat conftest.$ac_ext >&5 |
| 4039 | rm -rf conftest* |
| 4040 | eval "ac_cv_lib_$ac_lib_var=no" |
| 4041 | fi |
| 4042 | rm -f conftest* |
| 4043 | LIBS="$ac_save_LIBS" |
| 4044 | |
| 4045 | fi |
| 4046 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 4047 | echo "$ac_t""yes" 1>&6 |
| 4048 | cat >> confdefs.h <<\EOF |
| 4049 | #define WITH_THREAD 1 |
| 4050 | EOF |
| 4051 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 4052 | cat >> confdefs.h <<\EOF |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4053 | #define _POSIX_THREADS 1 |
| 4054 | EOF |
| 4055 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 4056 | LIBS="$LIBS -lcma" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 4057 | LIBOBJS="$LIBOBJS Python/thread.o" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4058 | else |
| 4059 | echo "$ac_t""no" 1>&6 |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 4060 | |
| 4061 | USE_THREAD_MODULE="#" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 4062 | fi |
| 4063 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 4064 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4065 | fi |
| 4066 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 4067 | fi |
| 4068 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 4069 | fi |
| 4070 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 4071 | fi |
| 4072 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4073 | fi |
| 4074 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 4075 | fi |
| 4076 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 4077 | fi |
| 4078 | |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 4079 | fi |
| 4080 | |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4081 | fi |
| 4082 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 4083 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 4084 | echo $ac_n "checking for usconfig in -lmpc""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4085 | echo "configure:4086: checking for usconfig in -lmpc" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4086 | ac_lib_var=`echo mpc'_'usconfig | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4087 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4088 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4089 | else |
| 4090 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4091 | LIBS="-lmpc $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4092 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4093 | #line 4094 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4094 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4095 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4096 | /* We use char because int might match the return type of a gcc2 |
| 4097 | builtin and then its argument prototype would still apply. */ |
| 4098 | char usconfig(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4099 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4100 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4101 | usconfig() |
| 4102 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4103 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4104 | if { (eval echo configure:4105: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4105 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4106 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4107 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4108 | echo "configure: failed program was:" >&5 |
| 4109 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4110 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4111 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4112 | fi |
| 4113 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4114 | LIBS="$ac_save_LIBS" |
| 4115 | |
| 4116 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4117 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4118 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4119 | cat >> confdefs.h <<\EOF |
| 4120 | #define WITH_THREAD 1 |
| 4121 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4122 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 4123 | LIBS="$LIBS -lmpc" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 4124 | LIBOBJS="$LIBOBJS Python/thread.o" |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 4125 | USE_THREAD_MODULE="" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4126 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4127 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4128 | fi |
| 4129 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 4130 | echo $ac_n "checking for thr_create in -lthread""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4131 | echo "configure:4132: checking for thr_create in -lthread" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4132 | ac_lib_var=`echo thread'_'thr_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4133 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4134 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4135 | else |
| 4136 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4137 | LIBS="-lthread $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4138 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4139 | #line 4140 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4140 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4141 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4142 | /* We use char because int might match the return type of a gcc2 |
| 4143 | builtin and then its argument prototype would still apply. */ |
| 4144 | char thr_create(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4145 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4146 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4147 | thr_create() |
| 4148 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4149 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4150 | if { (eval echo configure:4151: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4151 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4152 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4153 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4154 | echo "configure: failed program was:" >&5 |
| 4155 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4156 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4157 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4158 | fi |
| 4159 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4160 | LIBS="$ac_save_LIBS" |
| 4161 | |
| 4162 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4163 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4164 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4165 | cat >> confdefs.h <<\EOF |
| 4166 | #define WITH_THREAD 1 |
| 4167 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4168 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 4169 | LIBS="$LIBS -lthread" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 4170 | LIBOBJS="$LIBOBJS Python/thread.o" |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 4171 | USE_THREAD_MODULE="" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4172 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4173 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4174 | fi |
| 4175 | |
Jeremy Hylton | 1a2ca86 | 2000-10-16 16:59:12 +0000 | [diff] [blame] | 4176 | |
| 4177 | if test "$USE_THREAD_MODULE" != "#" |
| 4178 | then |
| 4179 | # If the above checks didn't disable threads, (at least) OSF1 |
| 4180 | # needs this '-threads' argument during linking. |
| 4181 | case $ac_sys_system in |
| 4182 | OSF1) LDLAST=-threads;; |
| 4183 | esac |
| 4184 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4185 | fi |
| 4186 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 4187 | # Check for GC support |
| 4188 | |
| 4189 | USE_GC_MODULE="" |
| 4190 | echo $ac_n "checking for --with-cycle-gc""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4191 | echo "configure:4192: checking for --with-cycle-gc" >&5 |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 4192 | # Check whether --with-cycle-gc or --without-cycle-gc was given. |
| 4193 | if test "${with_cycle_gc+set}" = set; then |
| 4194 | withval="$with_cycle_gc" |
| 4195 | : |
| 4196 | fi |
| 4197 | |
| 4198 | |
| 4199 | if test -z "$with_cycle_gc" |
| 4200 | then with_cycle_gc="yes" |
| 4201 | fi |
| 4202 | if test "$with_cycle_gc" = "no" |
| 4203 | then |
| 4204 | USE_GC_MODULE="#" |
| 4205 | else |
| 4206 | cat >> confdefs.h <<\EOF |
| 4207 | #define WITH_CYCLE_GC 1 |
| 4208 | EOF |
| 4209 | |
| 4210 | fi |
| 4211 | echo "$ac_t""$with_cycle_gc" 1>&6 |
| 4212 | |
Barry Warsaw | a57b89b | 2001-01-15 17:07:21 +0000 | [diff] [blame] | 4213 | # Check for DBM support |
| 4214 | |
| 4215 | USE_DBM_MODULE="" |
| 4216 | echo $ac_n "checking for --with-dbm""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4217 | echo "configure:4218: checking for --with-dbm" >&5 |
Barry Warsaw | a57b89b | 2001-01-15 17:07:21 +0000 | [diff] [blame] | 4218 | # Check whether --with-dbm or --without-dbm was given. |
| 4219 | if test "${with_dbm+set}" = set; then |
| 4220 | withval="$with_dbm" |
| 4221 | : |
| 4222 | fi |
| 4223 | |
| 4224 | |
| 4225 | # enabled by default but one of the dbm.h files must be found |
Sjoerd Mullender | 124698c | 2001-01-17 09:42:21 +0000 | [diff] [blame] | 4226 | if test "$ac_cv_header_ndbm_h" = "yes" -o "$ac_cv_header_db1_ndbm_h" = "yes" -o "$ac_cv_header_gdbm_ndbm_h" = "yes" |
Barry Warsaw | a57b89b | 2001-01-15 17:07:21 +0000 | [diff] [blame] | 4227 | then |
| 4228 | if test "$with_dbm" != "no" |
| 4229 | then with_dbm="yes" |
| 4230 | fi |
| 4231 | else |
| 4232 | # make sure user knows why dbm support wasn't enabled even though |
| 4233 | # s/he requested it |
| 4234 | if test "$with_dbm" = "yes" |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 4235 | then echo $ac_n "(requested but no ndbm.h was found) $ac_c" |
Barry Warsaw | a57b89b | 2001-01-15 17:07:21 +0000 | [diff] [blame] | 4236 | fi |
| 4237 | with_dbm="no" |
| 4238 | fi |
| 4239 | |
| 4240 | if test "$with_dbm" = "no" |
| 4241 | then |
| 4242 | USE_DBM_MODULE="#" |
| 4243 | else |
| 4244 | cat >> confdefs.h <<\EOF |
| 4245 | #define WITH_LIBNDBM 1 |
| 4246 | EOF |
| 4247 | |
| 4248 | fi |
| 4249 | echo "$ac_t""$with_dbm" 1>&6 |
| 4250 | |
| 4251 | if test "$with_dbm" = "yes" |
| 4252 | then |
| 4253 | # check for libndbm |
| 4254 | |
| 4255 | echo $ac_n "checking for dbmopen""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4256 | echo "configure:4257: checking for dbmopen" >&5 |
Barry Warsaw | a57b89b | 2001-01-15 17:07:21 +0000 | [diff] [blame] | 4257 | if eval "test \"`echo '$''{'ac_cv_func_dbmopen'+set}'`\" = set"; then |
| 4258 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4259 | else |
| 4260 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4261 | #line 4262 "configure" |
Barry Warsaw | a57b89b | 2001-01-15 17:07:21 +0000 | [diff] [blame] | 4262 | #include "confdefs.h" |
| 4263 | /* System header to define __stub macros and hopefully few prototypes, |
| 4264 | which can conflict with char dbmopen(); below. */ |
| 4265 | #include <assert.h> |
| 4266 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4267 | /* We use char because int might match the return type of a gcc2 |
| 4268 | builtin and then its argument prototype would still apply. */ |
| 4269 | char dbmopen(); |
| 4270 | |
| 4271 | int main() { |
| 4272 | |
| 4273 | /* The GNU C library defines this for functions which it implements |
| 4274 | to always fail with ENOSYS. Some functions are actually named |
| 4275 | something starting with __ and the normal name is an alias. */ |
| 4276 | #if defined (__stub_dbmopen) || defined (__stub___dbmopen) |
| 4277 | choke me |
| 4278 | #else |
| 4279 | dbmopen(); |
| 4280 | #endif |
| 4281 | |
| 4282 | ; return 0; } |
| 4283 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4284 | if { (eval echo configure:4285: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Barry Warsaw | a57b89b | 2001-01-15 17:07:21 +0000 | [diff] [blame] | 4285 | rm -rf conftest* |
| 4286 | eval "ac_cv_func_dbmopen=yes" |
| 4287 | else |
| 4288 | echo "configure: failed program was:" >&5 |
| 4289 | cat conftest.$ac_ext >&5 |
| 4290 | rm -rf conftest* |
| 4291 | eval "ac_cv_func_dbmopen=no" |
| 4292 | fi |
| 4293 | rm -f conftest* |
| 4294 | fi |
| 4295 | |
| 4296 | if eval "test \"`echo '$ac_cv_func_'dbmopen`\" = yes"; then |
| 4297 | echo "$ac_t""yes" 1>&6 |
| 4298 | HAVE_LIBNDBM= |
| 4299 | else |
| 4300 | echo "$ac_t""no" 1>&6 |
| 4301 | HAVE_LIBNDBM=-lndbm |
| 4302 | fi |
| 4303 | |
| 4304 | fi |
| 4305 | |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 4306 | # Check for LIBDB support |
| 4307 | # either --with-libdb or, in its absence, the presence of db.h |
| 4308 | |
| 4309 | USE_BSDDB_MODULE="" |
| 4310 | echo $ac_n "checking for --with-libdb""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4311 | echo "configure:4312: checking for --with-libdb" >&5 |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 4312 | # Check whether --with-libdb or --without-libdb was given. |
| 4313 | if test "${with_libdb+set}" = set; then |
| 4314 | withval="$with_libdb" |
| 4315 | : |
| 4316 | fi |
| 4317 | |
| 4318 | |
Skip Montanaro | b89f41e | 2000-09-04 04:06:05 +0000 | [diff] [blame] | 4319 | # enabled by default, but db.h must be found |
| 4320 | if test "$ac_cv_header_db_h" = "yes" |
| 4321 | then |
| 4322 | if test "$with_libdb" != "no" |
| 4323 | then with_libdb="yes" |
| 4324 | fi |
| 4325 | else |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 4326 | # make sure user knows why bsddb support wasn't enabled even |
Skip Montanaro | b89f41e | 2000-09-04 04:06:05 +0000 | [diff] [blame] | 4327 | # though s/he requested it |
| 4328 | if test "$with_libdb" = "yes" |
| 4329 | then echo $ac_n "(requested, but db.h was not found) $ac_c" |
| 4330 | fi |
| 4331 | with_libdb="no" |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 4332 | fi |
Skip Montanaro | b89f41e | 2000-09-04 04:06:05 +0000 | [diff] [blame] | 4333 | |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 4334 | if test "$with_libdb" = "no" |
| 4335 | then |
| 4336 | USE_BSDDB_MODULE="#" |
| 4337 | else |
| 4338 | cat >> confdefs.h <<\EOF |
| 4339 | #define WITH_LIBDB 1 |
| 4340 | EOF |
| 4341 | |
| 4342 | fi |
| 4343 | echo "$ac_t""$with_libdb" 1>&6 |
| 4344 | |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 4345 | if test "$with_libdb" = "yes" |
| 4346 | then |
| 4347 | # check for libdb; BSD systems have the DB routines in libc --tg |
| 4348 | |
Martin v. Löwis | 05a65d6 | 2000-09-24 19:40:25 +0000 | [diff] [blame] | 4349 | # If dbopen is not in libc, then checking whether it is in libdb |
| 4350 | # is difficult: db_185.h may #define it as __db185_open |
Fred Drake | 02706f5 | 2000-09-25 15:08:46 +0000 | [diff] [blame] | 4351 | # Instead, we just trust it is in libdb; linking will fail if it |
| 4352 | # is not. |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 4353 | echo $ac_n "checking for dbopen""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4354 | echo "configure:4355: checking for dbopen" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4355 | if eval "test \"`echo '$''{'ac_cv_func_dbopen'+set}'`\" = set"; then |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 4356 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4357 | else |
| 4358 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4359 | #line 4360 "configure" |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 4360 | #include "confdefs.h" |
| 4361 | /* System header to define __stub macros and hopefully few prototypes, |
| 4362 | which can conflict with char dbopen(); below. */ |
| 4363 | #include <assert.h> |
| 4364 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4365 | /* We use char because int might match the return type of a gcc2 |
| 4366 | builtin and then its argument prototype would still apply. */ |
| 4367 | char dbopen(); |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 4368 | |
| 4369 | int main() { |
| 4370 | |
| 4371 | /* The GNU C library defines this for functions which it implements |
| 4372 | to always fail with ENOSYS. Some functions are actually named |
| 4373 | something starting with __ and the normal name is an alias. */ |
| 4374 | #if defined (__stub_dbopen) || defined (__stub___dbopen) |
| 4375 | choke me |
| 4376 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4377 | dbopen(); |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 4378 | #endif |
| 4379 | |
| 4380 | ; return 0; } |
| 4381 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4382 | if { (eval echo configure:4383: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 4383 | rm -rf conftest* |
| 4384 | eval "ac_cv_func_dbopen=yes" |
| 4385 | else |
| 4386 | echo "configure: failed program was:" >&5 |
| 4387 | cat conftest.$ac_ext >&5 |
| 4388 | rm -rf conftest* |
| 4389 | eval "ac_cv_func_dbopen=no" |
| 4390 | fi |
| 4391 | rm -f conftest* |
| 4392 | fi |
| 4393 | |
| 4394 | if eval "test \"`echo '$ac_cv_func_'dbopen`\" = yes"; then |
| 4395 | echo "$ac_t""yes" 1>&6 |
| 4396 | HAVE_LIBDB= |
| 4397 | else |
| 4398 | echo "$ac_t""no" 1>&6 |
Martin v. Löwis | 05a65d6 | 2000-09-24 19:40:25 +0000 | [diff] [blame] | 4399 | HAVE_LIBDB=-ldb |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 4400 | fi |
| 4401 | |
| 4402 | fi |
| 4403 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 4404 | # Check for --with-wctype-functions |
| 4405 | echo $ac_n "checking for --with-wctype-functions""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4406 | echo "configure:4407: checking for --with-wctype-functions" >&5 |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 4407 | # Check whether --with-wctype-functions or --without-wctype-functions was given. |
| 4408 | if test "${with_wctype_functions+set}" = set; then |
| 4409 | withval="$with_wctype_functions" |
| 4410 | |
| 4411 | if test "$withval" != no |
| 4412 | then cat >> confdefs.h <<\EOF |
| 4413 | #define WANT_WCTYPE_FUNCTIONS 1 |
| 4414 | EOF |
| 4415 | echo "$ac_t""yes" 1>&6 |
| 4416 | else echo "$ac_t""no" 1>&6 |
| 4417 | fi |
| 4418 | else |
| 4419 | echo "$ac_t""no" 1>&6 |
| 4420 | fi |
| 4421 | |
| 4422 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4423 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4424 | |
| 4425 | DLINCLDIR=/ |
| 4426 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4427 | echo $ac_n "checking for --with-sgi-dl""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4428 | echo "configure:4429: checking for --with-sgi-dl" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4429 | # Check whether --with-sgi-dl or --without-sgi-dl was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4430 | if test "${with_sgi_dl+set}" = set; then |
| 4431 | withval="$with_sgi_dl" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4432 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4433 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4434 | cat >> confdefs.h <<\EOF |
| 4435 | #define WITH_SGI_DL 1 |
| 4436 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4437 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4438 | DYNLOADFILE="dynload_dl.o" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4439 | dldir=$withval |
Guido van Rossum | 4095101 | 2000-10-07 16:21:27 +0000 | [diff] [blame] | 4440 | if test ! -z "$dldir" -a -d "$dldir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 4441 | then LDFLAGS="$LDFLAGS -L$dldir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4442 | 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] | 4443 | fi |
| 4444 | DLINCLDIR=${dldir} |
| 4445 | LIBS="$LIBS -ldl -lmld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4446 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4447 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4448 | fi |
| 4449 | |
| 4450 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4451 | echo $ac_n "checking for --with-dl-dld""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4452 | echo "configure:4453: checking for --with-dl-dld" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4453 | # Check whether --with-dl-dld or --without-dl-dld was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4454 | if test "${with_dl_dld+set}" = set; then |
| 4455 | withval="$with_dl_dld" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4456 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4457 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4458 | cat >> confdefs.h <<\EOF |
| 4459 | #define WITH_DL_DLD 1 |
| 4460 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4461 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4462 | DYNLOADFILE="dynload_dl.o" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4463 | dldir=`echo "$withval" | sed 's/,.*//'` |
| 4464 | dlddir=`echo "$withval" | sed 's/.*,//'` |
Barry Warsaw | 7d1219d | 2000-10-05 18:45:53 +0000 | [diff] [blame] | 4465 | if test ! -z "$dldir" -a -d "$dldir" -a ! -z "$dlddir" -a -d "$dlddir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 4466 | then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4467 | 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] | 4468 | fi |
| 4469 | DLINCLDIR=${dldir} |
| 4470 | LIBS="$LIBS -ldl -ldld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4471 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4472 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4473 | fi |
| 4474 | |
| 4475 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4476 | # the dlopen() function means we might want to use dynload_shlib.o. some |
| 4477 | # platforms, such as AIX, have dlopen(), but don't want to use it. |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4478 | for ac_func in dlopen |
| 4479 | do |
| 4480 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4481 | echo "configure:4482: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4482 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4483 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4484 | else |
| 4485 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4486 | #line 4487 "configure" |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4487 | #include "confdefs.h" |
| 4488 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4489 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4490 | #include <assert.h> |
| 4491 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4492 | /* We use char because int might match the return type of a gcc2 |
| 4493 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4494 | char $ac_func(); |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4495 | |
| 4496 | int main() { |
| 4497 | |
| 4498 | /* The GNU C library defines this for functions which it implements |
| 4499 | to always fail with ENOSYS. Some functions are actually named |
| 4500 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4501 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4502 | choke me |
| 4503 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4504 | $ac_func(); |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4505 | #endif |
| 4506 | |
| 4507 | ; return 0; } |
| 4508 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4509 | if { (eval echo configure:4510: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4510 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4511 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4512 | else |
| 4513 | echo "configure: failed program was:" >&5 |
| 4514 | cat conftest.$ac_ext >&5 |
| 4515 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4516 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4517 | fi |
| 4518 | rm -f conftest* |
| 4519 | fi |
| 4520 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4521 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4522 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4523 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4524 | cat >> confdefs.h <<EOF |
| 4525 | #define $ac_tr_func 1 |
| 4526 | EOF |
| 4527 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4528 | else |
| 4529 | echo "$ac_t""no" 1>&6 |
| 4530 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4531 | done |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4532 | |
| 4533 | |
| 4534 | # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic |
| 4535 | # loading of modules. |
| 4536 | |
| 4537 | echo $ac_n "checking DYNLOADFILE""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4538 | echo "configure:4539: checking DYNLOADFILE" >&5 |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4539 | if test -z "$DYNLOADFILE" |
| 4540 | then |
| 4541 | case $ac_sys_system/$ac_sys_release in |
| 4542 | AIX*) DYNLOADFILE="dynload_aix.o";; |
| 4543 | BeOS*) DYNLOADFILE="dynload_beos.o";; |
| 4544 | hp*|HP*) DYNLOADFILE="dynload_hpux.o";; |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 4545 | Darwin/*|next/*) DYNLOADFILE="dynload_next.o";; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4546 | *) |
| 4547 | # use dynload_shlib.c and dlopen() if we have it; otherwise stub |
| 4548 | # out any dynamic loading |
| 4549 | if test "$ac_cv_func_dlopen" = yes |
| 4550 | then DYNLOADFILE="dynload_shlib.o" |
| 4551 | else DYNLOADFILE="dynload_stub.o" |
| 4552 | fi |
| 4553 | ;; |
| 4554 | esac |
| 4555 | fi |
| 4556 | echo "$ac_t""$DYNLOADFILE" 1>&6 |
| 4557 | if test "$DYNLOADFILE" != "dynload_stub.o" |
| 4558 | then |
| 4559 | cat >> confdefs.h <<\EOF |
| 4560 | #define HAVE_DYNAMIC_LOADING 1 |
| 4561 | EOF |
| 4562 | |
| 4563 | fi |
| 4564 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4565 | # checks for library functions |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4566 | for ac_func in alarm chown clock confstr ctermid ctermid_r execv \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 4567 | flock fork fsync fdatasync fpathconf ftime ftruncate \ |
Andrew M. Kuchling | a9586c7 | 2001-01-08 17:58:56 +0000 | [diff] [blame] | 4568 | getgroups getlogin getpeername getpid getpwent getwd \ |
Andrew M. Kuchling | 22c6934 | 2000-06-18 15:07:40 +0000 | [diff] [blame] | 4569 | kill link lstat mkfifo mktime mremap \ |
Andrew M. Kuchling | 5821b77 | 2000-08-25 01:14:08 +0000 | [diff] [blame] | 4570 | nice pathconf pause plock poll pthread_init \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 4571 | putenv readlink \ |
Andrew M. Kuchling | 8d2f2b2 | 2000-07-13 01:26:58 +0000 | [diff] [blame] | 4572 | select setegid seteuid setgid \ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4573 | setlocale setregid setreuid setsid setpgid setuid setvbuf \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 4574 | sigaction siginterrupt sigrelse strftime strptime symlink sysconf \ |
Fred Drake | 89143df | 1999-12-09 22:03:25 +0000 | [diff] [blame] | 4575 | tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ |
Thomas Wouters | 70c21a1 | 2000-07-14 14:28:33 +0000 | [diff] [blame] | 4576 | truncate uname waitpid _getpty |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4577 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4578 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4579 | echo "configure:4580: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4580 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4581 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4582 | else |
| 4583 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4584 | #line 4585 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4585 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4586 | /* System header to define __stub macros and hopefully few prototypes, |
| 4587 | which can conflict with char $ac_func(); below. */ |
| 4588 | #include <assert.h> |
| 4589 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4590 | /* We use char because int might match the return type of a gcc2 |
| 4591 | builtin and then its argument prototype would still apply. */ |
| 4592 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4593 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4594 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4595 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4596 | /* The GNU C library defines this for functions which it implements |
| 4597 | to always fail with ENOSYS. Some functions are actually named |
| 4598 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4599 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4600 | choke me |
| 4601 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4602 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4603 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4604 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4605 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4606 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4607 | if { (eval echo configure:4608: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4608 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4609 | eval "ac_cv_func_$ac_func=yes" |
| 4610 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4611 | echo "configure: failed program was:" >&5 |
| 4612 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4613 | rm -rf conftest* |
| 4614 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4615 | fi |
| 4616 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4617 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4618 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4619 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4620 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4621 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4622 | cat >> confdefs.h <<EOF |
| 4623 | #define $ac_tr_func 1 |
| 4624 | EOF |
| 4625 | |
| 4626 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4627 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4628 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4629 | done |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 4630 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4631 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4632 | # check for openpty and forkpty |
| 4633 | |
| 4634 | for ac_func in openpty |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4635 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4636 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4637 | echo "configure:4638: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4638 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4639 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4640 | else |
| 4641 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4642 | #line 4643 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4643 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4644 | /* System header to define __stub macros and hopefully few prototypes, |
| 4645 | which can conflict with char $ac_func(); below. */ |
| 4646 | #include <assert.h> |
| 4647 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4648 | /* We use char because int might match the return type of a gcc2 |
| 4649 | builtin and then its argument prototype would still apply. */ |
| 4650 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4651 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4652 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4653 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4654 | /* The GNU C library defines this for functions which it implements |
| 4655 | to always fail with ENOSYS. Some functions are actually named |
| 4656 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4657 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4658 | choke me |
| 4659 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4660 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4661 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4662 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4663 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4664 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4665 | if { (eval echo configure:4666: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4666 | rm -rf conftest* |
| 4667 | eval "ac_cv_func_$ac_func=yes" |
| 4668 | else |
| 4669 | echo "configure: failed program was:" >&5 |
| 4670 | cat conftest.$ac_ext >&5 |
| 4671 | rm -rf conftest* |
| 4672 | eval "ac_cv_func_$ac_func=no" |
| 4673 | fi |
| 4674 | rm -f conftest* |
| 4675 | fi |
| 4676 | |
| 4677 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4678 | echo "$ac_t""yes" 1>&6 |
| 4679 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4680 | cat >> confdefs.h <<EOF |
| 4681 | #define $ac_tr_func 1 |
| 4682 | EOF |
| 4683 | |
| 4684 | else |
| 4685 | echo "$ac_t""no" 1>&6 |
| 4686 | echo $ac_n "checking for openpty in -lutil""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4687 | echo "configure:4688: checking for openpty in -lutil" >&5 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4688 | ac_lib_var=`echo util'_'openpty | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4689 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4690 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4691 | else |
| 4692 | ac_save_LIBS="$LIBS" |
| 4693 | LIBS="-lutil $LIBS" |
| 4694 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4695 | #line 4696 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4696 | #include "confdefs.h" |
| 4697 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4698 | /* We use char because int might match the return type of a gcc2 |
| 4699 | builtin and then its argument prototype would still apply. */ |
| 4700 | char openpty(); |
| 4701 | |
| 4702 | int main() { |
| 4703 | openpty() |
| 4704 | ; return 0; } |
| 4705 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4706 | if { (eval echo configure:4707: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4707 | rm -rf conftest* |
| 4708 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 4709 | else |
| 4710 | echo "configure: failed program was:" >&5 |
| 4711 | cat conftest.$ac_ext >&5 |
| 4712 | rm -rf conftest* |
| 4713 | eval "ac_cv_lib_$ac_lib_var=no" |
| 4714 | fi |
| 4715 | rm -f conftest* |
| 4716 | LIBS="$ac_save_LIBS" |
| 4717 | |
| 4718 | fi |
| 4719 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 4720 | echo "$ac_t""yes" 1>&6 |
| 4721 | cat >> confdefs.h <<\EOF |
| 4722 | #define HAVE_OPENPTY 1 |
| 4723 | EOF |
| 4724 | LIBS="$LIBS -lutil" |
| 4725 | else |
| 4726 | echo "$ac_t""no" 1>&6 |
| 4727 | fi |
| 4728 | |
| 4729 | fi |
| 4730 | done |
| 4731 | |
| 4732 | for ac_func in forkpty |
| 4733 | do |
| 4734 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4735 | echo "configure:4736: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4736 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4737 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4738 | else |
| 4739 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4740 | #line 4741 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4741 | #include "confdefs.h" |
| 4742 | /* System header to define __stub macros and hopefully few prototypes, |
| 4743 | which can conflict with char $ac_func(); below. */ |
| 4744 | #include <assert.h> |
| 4745 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4746 | /* We use char because int might match the return type of a gcc2 |
| 4747 | builtin and then its argument prototype would still apply. */ |
| 4748 | char $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4749 | |
| 4750 | int main() { |
| 4751 | |
| 4752 | /* The GNU C library defines this for functions which it implements |
| 4753 | to always fail with ENOSYS. Some functions are actually named |
| 4754 | something starting with __ and the normal name is an alias. */ |
| 4755 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4756 | choke me |
| 4757 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4758 | $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4759 | #endif |
| 4760 | |
| 4761 | ; return 0; } |
| 4762 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4763 | if { (eval echo configure:4764: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4764 | rm -rf conftest* |
| 4765 | eval "ac_cv_func_$ac_func=yes" |
| 4766 | else |
| 4767 | echo "configure: failed program was:" >&5 |
| 4768 | cat conftest.$ac_ext >&5 |
| 4769 | rm -rf conftest* |
| 4770 | eval "ac_cv_func_$ac_func=no" |
| 4771 | fi |
| 4772 | rm -f conftest* |
| 4773 | fi |
| 4774 | |
| 4775 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4776 | echo "$ac_t""yes" 1>&6 |
| 4777 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4778 | cat >> confdefs.h <<EOF |
| 4779 | #define $ac_tr_func 1 |
| 4780 | EOF |
| 4781 | |
| 4782 | else |
| 4783 | echo "$ac_t""no" 1>&6 |
| 4784 | echo $ac_n "checking for forkpty in -lutil""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4785 | echo "configure:4786: checking for forkpty in -lutil" >&5 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4786 | ac_lib_var=`echo util'_'forkpty | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4787 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4788 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4789 | else |
| 4790 | ac_save_LIBS="$LIBS" |
| 4791 | LIBS="-lutil $LIBS" |
| 4792 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4793 | #line 4794 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4794 | #include "confdefs.h" |
| 4795 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4796 | /* We use char because int might match the return type of a gcc2 |
| 4797 | builtin and then its argument prototype would still apply. */ |
| 4798 | char forkpty(); |
| 4799 | |
| 4800 | int main() { |
| 4801 | forkpty() |
| 4802 | ; return 0; } |
| 4803 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4804 | if { (eval echo configure:4805: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4805 | rm -rf conftest* |
| 4806 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 4807 | else |
| 4808 | echo "configure: failed program was:" >&5 |
| 4809 | cat conftest.$ac_ext >&5 |
| 4810 | rm -rf conftest* |
| 4811 | eval "ac_cv_lib_$ac_lib_var=no" |
| 4812 | fi |
| 4813 | rm -f conftest* |
| 4814 | LIBS="$ac_save_LIBS" |
| 4815 | |
| 4816 | fi |
| 4817 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 4818 | echo "$ac_t""yes" 1>&6 |
| 4819 | cat >> confdefs.h <<\EOF |
| 4820 | #define HAVE_FORKPTY 1 |
| 4821 | EOF |
| 4822 | LIBS="$LIBS -lutil" |
| 4823 | else |
| 4824 | echo "$ac_t""no" 1>&6 |
| 4825 | fi |
| 4826 | |
| 4827 | fi |
| 4828 | done |
| 4829 | |
| 4830 | |
| 4831 | # check for long file support functions |
| 4832 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
| 4833 | do |
| 4834 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4835 | echo "configure:4836: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4836 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4837 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4838 | else |
| 4839 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4840 | #line 4841 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4841 | #include "confdefs.h" |
| 4842 | /* System header to define __stub macros and hopefully few prototypes, |
| 4843 | which can conflict with char $ac_func(); below. */ |
| 4844 | #include <assert.h> |
| 4845 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4846 | /* We use char because int might match the return type of a gcc2 |
| 4847 | builtin and then its argument prototype would still apply. */ |
| 4848 | char $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4849 | |
| 4850 | int main() { |
| 4851 | |
| 4852 | /* The GNU C library defines this for functions which it implements |
| 4853 | to always fail with ENOSYS. Some functions are actually named |
| 4854 | something starting with __ and the normal name is an alias. */ |
| 4855 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4856 | choke me |
| 4857 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4858 | $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4859 | #endif |
| 4860 | |
| 4861 | ; return 0; } |
| 4862 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4863 | if { (eval echo configure:4864: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4864 | rm -rf conftest* |
| 4865 | eval "ac_cv_func_$ac_func=yes" |
| 4866 | else |
| 4867 | echo "configure: failed program was:" >&5 |
| 4868 | cat conftest.$ac_ext >&5 |
| 4869 | rm -rf conftest* |
| 4870 | eval "ac_cv_func_$ac_func=no" |
| 4871 | fi |
| 4872 | rm -f conftest* |
| 4873 | fi |
| 4874 | |
| 4875 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4876 | echo "$ac_t""yes" 1>&6 |
| 4877 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4878 | cat >> confdefs.h <<EOF |
| 4879 | #define $ac_tr_func 1 |
| 4880 | EOF |
| 4881 | |
| 4882 | else |
| 4883 | echo "$ac_t""no" 1>&6 |
| 4884 | fi |
| 4885 | done |
| 4886 | |
| 4887 | |
| 4888 | for ac_func in dup2 getcwd strdup strerror memmove |
| 4889 | do |
| 4890 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4891 | echo "configure:4892: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4892 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4893 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4894 | else |
| 4895 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4896 | #line 4897 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4897 | #include "confdefs.h" |
| 4898 | /* System header to define __stub macros and hopefully few prototypes, |
| 4899 | which can conflict with char $ac_func(); below. */ |
| 4900 | #include <assert.h> |
| 4901 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4902 | /* We use char because int might match the return type of a gcc2 |
| 4903 | builtin and then its argument prototype would still apply. */ |
| 4904 | char $ac_func(); |
| 4905 | |
| 4906 | int main() { |
| 4907 | |
| 4908 | /* The GNU C library defines this for functions which it implements |
| 4909 | to always fail with ENOSYS. Some functions are actually named |
| 4910 | something starting with __ and the normal name is an alias. */ |
| 4911 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4912 | choke me |
| 4913 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4914 | $ac_func(); |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4915 | #endif |
| 4916 | |
| 4917 | ; return 0; } |
| 4918 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4919 | if { (eval echo configure:4920: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4920 | rm -rf conftest* |
| 4921 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4922 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4923 | echo "configure: failed program was:" >&5 |
| 4924 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4925 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4926 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4927 | fi |
| 4928 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4929 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4930 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4931 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4932 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4933 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4934 | cat >> confdefs.h <<EOF |
| 4935 | #define $ac_tr_func 1 |
| 4936 | EOF |
| 4937 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4938 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4939 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4940 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4941 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4942 | done |
| 4943 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4944 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4945 | for ac_func in getpgrp |
| 4946 | do |
| 4947 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4948 | echo "configure:4949: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4949 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4950 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4951 | else |
| 4952 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4953 | #line 4954 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4954 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4955 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4956 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4957 | #include <assert.h> |
| 4958 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4959 | /* We use char because int might match the return type of a gcc2 |
| 4960 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4961 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4962 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4963 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4964 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4965 | /* The GNU C library defines this for functions which it implements |
| 4966 | to always fail with ENOSYS. Some functions are actually named |
| 4967 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4968 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4969 | choke me |
| 4970 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4971 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4972 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4973 | |
| 4974 | ; return 0; } |
| 4975 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4976 | if { (eval echo configure:4977: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4977 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4978 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4979 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4980 | echo "configure: failed program was:" >&5 |
| 4981 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4982 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4983 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4984 | fi |
| 4985 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4986 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4987 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4988 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4989 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4990 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4991 | cat >> confdefs.h <<EOF |
| 4992 | #define $ac_tr_func 1 |
| 4993 | EOF |
| 4994 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 4995 | #line 4996 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4996 | #include "confdefs.h" |
| 4997 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4998 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4999 | getpgrp(0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5000 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5001 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5002 | if { (eval echo configure:5003: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5003 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5004 | cat >> confdefs.h <<\EOF |
| 5005 | #define GETPGRP_HAVE_ARG 1 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5006 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5007 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5008 | else |
| 5009 | echo "configure: failed program was:" >&5 |
| 5010 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5011 | fi |
| 5012 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5013 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5014 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5015 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5016 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5017 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5018 | for ac_func in setpgrp |
| 5019 | do |
| 5020 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5021 | echo "configure:5022: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5022 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5023 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5024 | else |
| 5025 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5026 | #line 5027 "configure" |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5027 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5028 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5029 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5030 | #include <assert.h> |
| 5031 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5032 | /* We use char because int might match the return type of a gcc2 |
| 5033 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5034 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5035 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5036 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5037 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5038 | /* The GNU C library defines this for functions which it implements |
| 5039 | to always fail with ENOSYS. Some functions are actually named |
| 5040 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5041 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5042 | choke me |
| 5043 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5044 | $ac_func(); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5045 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5046 | |
| 5047 | ; return 0; } |
| 5048 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5049 | if { (eval echo configure:5050: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5050 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5051 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5052 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5053 | echo "configure: failed program was:" >&5 |
| 5054 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5055 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5056 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5057 | fi |
| 5058 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5059 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5060 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5061 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5062 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5063 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 5064 | cat >> confdefs.h <<EOF |
| 5065 | #define $ac_tr_func 1 |
| 5066 | EOF |
| 5067 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5068 | #line 5069 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5069 | #include "confdefs.h" |
| 5070 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5071 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5072 | setpgrp(0,0); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5073 | ; return 0; } |
| 5074 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5075 | if { (eval echo configure:5076: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5076 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5077 | cat >> confdefs.h <<\EOF |
| 5078 | #define SETPGRP_HAVE_ARG 1 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5079 | EOF |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5080 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5081 | else |
| 5082 | echo "configure: failed program was:" >&5 |
| 5083 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5084 | fi |
| 5085 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5086 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5087 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5088 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5089 | done |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5090 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5091 | for ac_func in gettimeofday |
| 5092 | do |
| 5093 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5094 | echo "configure:5095: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5095 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5096 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5097 | else |
| 5098 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5099 | #line 5100 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5100 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5101 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5102 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5103 | #include <assert.h> |
| 5104 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5105 | /* We use char because int might match the return type of a gcc2 |
| 5106 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5107 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5108 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5109 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5110 | |
| 5111 | /* The GNU C library defines this for functions which it implements |
| 5112 | to always fail with ENOSYS. Some functions are actually named |
| 5113 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5114 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5115 | choke me |
| 5116 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5117 | $ac_func(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5118 | #endif |
| 5119 | |
| 5120 | ; return 0; } |
| 5121 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5122 | if { (eval echo configure:5123: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5123 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5124 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5125 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5126 | echo "configure: failed program was:" >&5 |
| 5127 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5128 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5129 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5130 | fi |
| 5131 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5132 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5133 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5134 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5135 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5136 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 5137 | cat >> confdefs.h <<EOF |
| 5138 | #define $ac_tr_func 1 |
| 5139 | EOF |
| 5140 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5141 | #line 5142 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5142 | #include "confdefs.h" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5143 | #include <sys/time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5144 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5145 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
| 5146 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5147 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5148 | if { (eval echo configure:5149: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5149 | : |
| 5150 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5151 | echo "configure: failed program was:" >&5 |
| 5152 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5153 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5154 | cat >> confdefs.h <<\EOF |
| 5155 | #define GETTIMEOFDAY_NO_TZ 1 |
| 5156 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5157 | |
| 5158 | fi |
| 5159 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5160 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5161 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5162 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5163 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5164 | |
| 5165 | |
| 5166 | # checks for structures |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5167 | echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5168 | echo "configure:5169: checking whether time.h and sys/time.h may both be included" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5169 | if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5170 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5171 | else |
| 5172 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5173 | #line 5174 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5174 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5175 | #include <sys/types.h> |
| 5176 | #include <sys/time.h> |
| 5177 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5178 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5179 | struct tm *tp; |
| 5180 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5181 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5182 | if { (eval echo configure:5183: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5183 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5184 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5185 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5186 | echo "configure: failed program was:" >&5 |
| 5187 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5188 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5189 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5190 | fi |
| 5191 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5192 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5193 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5194 | echo "$ac_t""$ac_cv_header_time" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5195 | if test $ac_cv_header_time = yes; then |
| 5196 | cat >> confdefs.h <<\EOF |
| 5197 | #define TIME_WITH_SYS_TIME 1 |
| 5198 | EOF |
| 5199 | |
| 5200 | fi |
| 5201 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5202 | echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5203 | echo "configure:5204: checking whether struct tm is in sys/time.h or time.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5204 | if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5205 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5206 | else |
| 5207 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5208 | #line 5209 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5209 | #include "confdefs.h" |
| 5210 | #include <sys/types.h> |
| 5211 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5212 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5213 | struct tm *tp; tp->tm_sec; |
| 5214 | ; return 0; } |
| 5215 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5216 | if { (eval echo configure:5217: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5217 | rm -rf conftest* |
| 5218 | ac_cv_struct_tm=time.h |
| 5219 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5220 | echo "configure: failed program was:" >&5 |
| 5221 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5222 | rm -rf conftest* |
| 5223 | ac_cv_struct_tm=sys/time.h |
| 5224 | fi |
| 5225 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5226 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5227 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5228 | echo "$ac_t""$ac_cv_struct_tm" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5229 | if test $ac_cv_struct_tm = sys/time.h; then |
| 5230 | cat >> confdefs.h <<\EOF |
| 5231 | #define TM_IN_SYS_TIME 1 |
| 5232 | EOF |
| 5233 | |
| 5234 | fi |
| 5235 | |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5236 | echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5237 | echo "configure:5238: checking for tm_zone in struct tm" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5238 | if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5239 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5240 | else |
| 5241 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5242 | #line 5243 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5243 | #include "confdefs.h" |
| 5244 | #include <sys/types.h> |
| 5245 | #include <$ac_cv_struct_tm> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5246 | int main() { |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5247 | struct tm tm; tm.tm_zone; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5248 | ; return 0; } |
| 5249 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5250 | if { (eval echo configure:5251: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5251 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5252 | ac_cv_struct_tm_zone=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5253 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5254 | echo "configure: failed program was:" >&5 |
| 5255 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5256 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5257 | ac_cv_struct_tm_zone=no |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5258 | fi |
| 5259 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5260 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5261 | |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5262 | echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6 |
| 5263 | if test "$ac_cv_struct_tm_zone" = yes; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5264 | cat >> confdefs.h <<\EOF |
| 5265 | #define HAVE_TM_ZONE 1 |
| 5266 | EOF |
| 5267 | |
| 5268 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5269 | echo $ac_n "checking for tzname""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5270 | echo "configure:5271: checking for tzname" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5271 | if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5272 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5273 | else |
| 5274 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5275 | #line 5276 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5276 | #include "confdefs.h" |
| 5277 | #include <time.h> |
| 5278 | #ifndef tzname /* For SGI. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5279 | extern char *tzname[]; /* RS6000 and others reject char **tzname. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5280 | #endif |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5281 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5282 | atoi(*tzname); |
| 5283 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5284 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5285 | if { (eval echo configure:5286: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5286 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5287 | ac_cv_var_tzname=yes |
| 5288 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5289 | echo "configure: failed program was:" >&5 |
| 5290 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5291 | rm -rf conftest* |
| 5292 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5293 | fi |
| 5294 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5295 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5296 | |
| 5297 | echo "$ac_t""$ac_cv_var_tzname" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5298 | if test $ac_cv_var_tzname = yes; then |
| 5299 | cat >> confdefs.h <<\EOF |
| 5300 | #define HAVE_TZNAME 1 |
| 5301 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5302 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5303 | fi |
| 5304 | fi |
| 5305 | |
| 5306 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5307 | echo $ac_n "checking for time.h that defines altzone""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5308 | echo "configure:5309: checking for time.h that defines altzone" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5309 | if eval "test \"`echo '$''{'ac_cv_header_time_altzone'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5310 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5311 | else |
| 5312 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5313 | #line 5314 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5314 | #include "confdefs.h" |
| 5315 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5316 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5317 | return altzone; |
| 5318 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5319 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5320 | if { (eval echo configure:5321: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5321 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5322 | ac_cv_header_time_altzone=yes |
| 5323 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5324 | echo "configure: failed program was:" >&5 |
| 5325 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5326 | rm -rf conftest* |
| 5327 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5328 | fi |
| 5329 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5330 | fi |
| 5331 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5332 | echo "$ac_t""$ac_cv_header_time_altzone" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5333 | if test $ac_cv_header_time_altzone = yes; then |
| 5334 | cat >> confdefs.h <<\EOF |
| 5335 | #define HAVE_ALTZONE 1 |
| 5336 | EOF |
| 5337 | |
| 5338 | fi |
| 5339 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5340 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5341 | echo $ac_n "checking whether sys/select.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5342 | echo "configure:5343: checking whether sys/select.h and sys/time.h may both be included" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5343 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5344 | #line 5345 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5345 | #include "confdefs.h" |
| 5346 | |
| 5347 | #include <sys/types.h> |
| 5348 | #include <sys/select.h> |
| 5349 | #include <sys/time.h> |
| 5350 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5351 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5352 | ; |
| 5353 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5354 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5355 | if { (eval echo configure:5356: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5356 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5357 | cat >> confdefs.h <<\EOF |
| 5358 | #define SYS_SELECT_WITH_SYS_TIME 1 |
| 5359 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5360 | was_it_defined=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5361 | else |
| 5362 | echo "configure: failed program was:" >&5 |
| 5363 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5364 | fi |
| 5365 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5366 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5367 | |
| 5368 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5369 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5370 | echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5371 | echo "configure:5372: checking whether char is unsigned" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5372 | if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5373 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5374 | else |
| 5375 | if test "$GCC" = yes; then |
| 5376 | # GCC predefines this symbol on systems where it applies. |
| 5377 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5378 | #line 5379 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5379 | #include "confdefs.h" |
| 5380 | #ifdef __CHAR_UNSIGNED__ |
| 5381 | yes |
| 5382 | #endif |
| 5383 | |
| 5384 | EOF |
| 5385 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 5386 | egrep "yes" >/dev/null 2>&1; then |
| 5387 | rm -rf conftest* |
| 5388 | ac_cv_c_char_unsigned=yes |
| 5389 | else |
| 5390 | rm -rf conftest* |
| 5391 | ac_cv_c_char_unsigned=no |
| 5392 | fi |
| 5393 | rm -f conftest* |
| 5394 | |
| 5395 | else |
| 5396 | if test "$cross_compiling" = yes; then |
| 5397 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5398 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5399 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5400 | #line 5401 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5401 | #include "confdefs.h" |
| 5402 | /* volatile prevents gcc2 from optimizing the test away on sparcs. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5403 | #if !defined(__STDC__) || __STDC__ != 1 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5404 | #define volatile |
| 5405 | #endif |
| 5406 | main() { |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5407 | volatile char c = 255; exit(c < 0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5408 | } |
| 5409 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5410 | if { (eval echo configure:5411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5411 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5412 | ac_cv_c_char_unsigned=yes |
| 5413 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5414 | echo "configure: failed program was:" >&5 |
| 5415 | cat conftest.$ac_ext >&5 |
| 5416 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5417 | ac_cv_c_char_unsigned=no |
| 5418 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5419 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5420 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5421 | |
| 5422 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5423 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5424 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5425 | echo "$ac_t""$ac_cv_c_char_unsigned" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5426 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
| 5427 | cat >> confdefs.h <<\EOF |
| 5428 | #define __CHAR_UNSIGNED__ 1 |
| 5429 | EOF |
| 5430 | |
| 5431 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5432 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5433 | echo $ac_n "checking for working const""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5434 | echo "configure:5435: checking for working const" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5435 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5436 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5437 | else |
| 5438 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5439 | #line 5440 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5440 | #include "confdefs.h" |
| 5441 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5442 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5443 | |
| 5444 | /* Ultrix mips cc rejects this. */ |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5445 | typedef int charset[2]; const charset x = {0,0}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5446 | /* SunOS 4.1.1 cc rejects this. */ |
| 5447 | char const *const *ccp; |
| 5448 | char **p; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5449 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 5450 | struct point {int x, y;}; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5451 | static struct point const zero = {0,0}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5452 | /* AIX XL C 1.02.0.0 rejects this. |
| 5453 | It does not let you subtract one const X* pointer from another in an arm |
| 5454 | of an if-expression whose if-part is not a constant expression */ |
| 5455 | const char *g = "string"; |
| 5456 | ccp = &g + (g ? g-g : 0); |
| 5457 | /* HPUX 7.0 cc rejects these. */ |
| 5458 | ++ccp; |
| 5459 | p = (char**) ccp; |
| 5460 | ccp = (char const *const *) p; |
| 5461 | { /* SCO 3.2v4 cc rejects this. */ |
| 5462 | char *t; |
| 5463 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
| 5464 | |
| 5465 | *t++ = 0; |
| 5466 | } |
| 5467 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5468 | int x[] = {25, 17}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5469 | const int *foo = &x[0]; |
| 5470 | ++foo; |
| 5471 | } |
| 5472 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 5473 | typedef const int *iptr; |
| 5474 | iptr p = 0; |
| 5475 | ++p; |
| 5476 | } |
| 5477 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 5478 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 5479 | struct s { int j; const int *ap[3]; }; |
| 5480 | struct s *b; b->j = 5; |
| 5481 | } |
| 5482 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 5483 | const int foo = 10; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5484 | } |
| 5485 | |
| 5486 | ; return 0; } |
| 5487 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5488 | if { (eval echo configure:5489: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5489 | rm -rf conftest* |
| 5490 | ac_cv_c_const=yes |
| 5491 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5492 | echo "configure: failed program was:" >&5 |
| 5493 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5494 | rm -rf conftest* |
| 5495 | ac_cv_c_const=no |
| 5496 | fi |
| 5497 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5498 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5499 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5500 | echo "$ac_t""$ac_cv_c_const" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5501 | if test $ac_cv_c_const = no; then |
| 5502 | cat >> confdefs.h <<\EOF |
| 5503 | #define const |
| 5504 | EOF |
| 5505 | |
| 5506 | fi |
| 5507 | |
| 5508 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5509 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5510 | echo $ac_n "checking for working volatile""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5511 | echo "configure:5512: checking for working volatile" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5512 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5513 | #line 5514 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5514 | #include "confdefs.h" |
| 5515 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5516 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5517 | volatile int x; x = 0; |
| 5518 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5519 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5520 | if { (eval echo configure:5521: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5521 | rm -rf conftest* |
| 5522 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5523 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5524 | echo "configure: failed program was:" >&5 |
| 5525 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5526 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5527 | cat >> confdefs.h <<\EOF |
| 5528 | #define volatile |
| 5529 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5530 | |
| 5531 | fi |
| 5532 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5533 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5534 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5535 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5536 | echo $ac_n "checking for working signed char""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5537 | echo "configure:5538: checking for working signed char" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5538 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5539 | #line 5540 "configure" |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 5540 | #include "confdefs.h" |
| 5541 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5542 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5543 | signed char c; |
| 5544 | ; return 0; } |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 5545 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5546 | if { (eval echo configure:5547: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5547 | rm -rf conftest* |
| 5548 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 5549 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5550 | echo "configure: failed program was:" >&5 |
| 5551 | cat conftest.$ac_ext >&5 |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 5552 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5553 | cat >> confdefs.h <<\EOF |
| 5554 | #define signed |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5555 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5556 | |
| 5557 | fi |
| 5558 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5559 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5560 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5561 | have_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5562 | echo $ac_n "checking for prototypes""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5563 | echo "configure:5564: checking for prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5564 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5565 | #line 5566 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5566 | #include "confdefs.h" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5567 | int foo(int x) { return 0; } |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5568 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5569 | return foo(10); |
| 5570 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5571 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5572 | if { (eval echo configure:5573: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5573 | rm -rf conftest* |
| 5574 | cat >> confdefs.h <<\EOF |
| 5575 | #define HAVE_PROTOTYPES 1 |
| 5576 | EOF |
| 5577 | have_prototypes=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5578 | else |
| 5579 | echo "configure: failed program was:" >&5 |
| 5580 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5581 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5582 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5583 | echo "$ac_t""$have_prototypes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5584 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5585 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5586 | echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5587 | echo "configure:5588: checking for variable length prototypes and stdarg.h" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5588 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5589 | #line 5590 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5590 | #include "confdefs.h" |
| 5591 | |
| 5592 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 5593 | int foo(int x, ...) { |
| 5594 | va_list va; |
| 5595 | va_start(va, x); |
| 5596 | va_arg(va, int); |
| 5597 | va_arg(va, char *); |
| 5598 | va_arg(va, double); |
| 5599 | return 0; |
| 5600 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5601 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5602 | int main() { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 5603 | return foo(10, "", 3.14); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5604 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5605 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5606 | if { (eval echo configure:5607: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5607 | rm -rf conftest* |
| 5608 | cat >> confdefs.h <<\EOF |
| 5609 | #define HAVE_STDARG_PROTOTYPES 1 |
| 5610 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5611 | works=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5612 | else |
| 5613 | echo "configure: failed program was:" >&5 |
| 5614 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5615 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5616 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5617 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5618 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5619 | if test "$have_prototypes" = yes; then |
| 5620 | bad_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5621 | echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5622 | echo "configure:5623: checking for bad exec* prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5623 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5624 | #line 5625 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5625 | #include "confdefs.h" |
| 5626 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5627 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5628 | char **t;execve("@",t,t); |
| 5629 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5630 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5631 | if { (eval echo configure:5632: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5632 | : |
| 5633 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5634 | echo "configure: failed program was:" >&5 |
| 5635 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5636 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5637 | cat >> confdefs.h <<\EOF |
| 5638 | #define BAD_EXEC_PROTOTYPES 1 |
| 5639 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5640 | bad_prototypes=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5641 | fi |
| 5642 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5643 | echo "$ac_t""$bad_prototypes" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5644 | fi |
| 5645 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5646 | bad_forward=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5647 | echo $ac_n "checking for bad static forward""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5648 | echo "configure:5649: checking for bad static forward" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5649 | if test "$cross_compiling" = yes; then |
| 5650 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5651 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5652 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5653 | #line 5654 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5654 | #include "confdefs.h" |
| 5655 | |
| 5656 | struct s { int a; int b; }; |
| 5657 | static struct s foo; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5658 | int foobar() { |
| 5659 | static int random; |
| 5660 | random = (int) &foo; |
| 5661 | return random; |
| 5662 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5663 | static struct s foo = { 1, 2 }; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5664 | main() { |
| 5665 | exit(!((int)&foo == foobar())); |
| 5666 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5667 | |
| 5668 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5669 | if { (eval echo configure:5670: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5670 | then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5671 | : |
| 5672 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5673 | echo "configure: failed program was:" >&5 |
| 5674 | cat conftest.$ac_ext >&5 |
| 5675 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5676 | cat >> confdefs.h <<\EOF |
| 5677 | #define BAD_STATIC_FORWARD 1 |
| 5678 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5679 | bad_forward=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5680 | fi |
| 5681 | rm -fr conftest* |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5682 | fi |
| 5683 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5684 | echo "$ac_t""$bad_forward" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5685 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5686 | va_list_is_array=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5687 | echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5688 | echo "configure:5689: checking whether va_list is an array" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5689 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5690 | #line 5691 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5691 | #include "confdefs.h" |
| 5692 | |
| 5693 | #ifdef HAVE_STDARG_PROTOTYPES |
| 5694 | #include <stdarg.h> |
| 5695 | #else |
| 5696 | #include <varargs.h> |
| 5697 | #endif |
| 5698 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5699 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5700 | va_list list1, list2; list1 = list2; |
| 5701 | ; return 0; } |
| 5702 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5703 | if { (eval echo configure:5704: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5704 | : |
| 5705 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5706 | echo "configure: failed program was:" >&5 |
| 5707 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5708 | rm -rf conftest* |
| 5709 | cat >> confdefs.h <<\EOF |
| 5710 | #define VA_LIST_IS_ARRAY 1 |
| 5711 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5712 | va_list_is_array=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5713 | fi |
| 5714 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5715 | echo "$ac_t""$va_list_is_array" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5716 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5717 | # sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-( |
| 5718 | echo $ac_n "checking for gethostbyname_r""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5719 | echo "configure:5720: checking for gethostbyname_r" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5720 | if eval "test \"`echo '$''{'ac_cv_func_gethostbyname_r'+set}'`\" = set"; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5721 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5722 | else |
| 5723 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5724 | #line 5725 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5725 | #include "confdefs.h" |
| 5726 | /* System header to define __stub macros and hopefully few prototypes, |
| 5727 | which can conflict with char gethostbyname_r(); below. */ |
| 5728 | #include <assert.h> |
| 5729 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5730 | /* We use char because int might match the return type of a gcc2 |
| 5731 | builtin and then its argument prototype would still apply. */ |
| 5732 | char gethostbyname_r(); |
| 5733 | |
| 5734 | int main() { |
| 5735 | |
| 5736 | /* The GNU C library defines this for functions which it implements |
| 5737 | to always fail with ENOSYS. Some functions are actually named |
| 5738 | something starting with __ and the normal name is an alias. */ |
| 5739 | #if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r) |
| 5740 | choke me |
| 5741 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5742 | gethostbyname_r(); |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5743 | #endif |
| 5744 | |
| 5745 | ; return 0; } |
| 5746 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5747 | if { (eval echo configure:5748: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5748 | rm -rf conftest* |
| 5749 | eval "ac_cv_func_gethostbyname_r=yes" |
| 5750 | else |
| 5751 | echo "configure: failed program was:" >&5 |
| 5752 | cat conftest.$ac_ext >&5 |
| 5753 | rm -rf conftest* |
| 5754 | eval "ac_cv_func_gethostbyname_r=no" |
| 5755 | fi |
| 5756 | rm -f conftest* |
| 5757 | fi |
| 5758 | |
| 5759 | if eval "test \"`echo '$ac_cv_func_'gethostbyname_r`\" = yes"; then |
| 5760 | echo "$ac_t""yes" 1>&6 |
| 5761 | |
| 5762 | cat >> confdefs.h <<\EOF |
| 5763 | #define HAVE_GETHOSTBYNAME_R 1 |
| 5764 | EOF |
| 5765 | |
| 5766 | echo $ac_n "checking gethostbyname_r with 6 args""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5767 | echo "configure:5768: checking gethostbyname_r with 6 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5768 | OLD_CFLAGS=$CFLAGS |
| 5769 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
| 5770 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5771 | #line 5772 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5772 | #include "confdefs.h" |
| 5773 | |
| 5774 | # include <netdb.h> |
| 5775 | |
| 5776 | int main() { |
| 5777 | |
| 5778 | char *name; |
| 5779 | struct hostent *he, *res; |
| 5780 | char buffer[2048]; |
| 5781 | int buflen = 2048; |
| 5782 | int h_errnop; |
| 5783 | |
| 5784 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
| 5785 | |
| 5786 | ; return 0; } |
| 5787 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5788 | if { (eval echo configure:5789: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5789 | rm -rf conftest* |
| 5790 | |
| 5791 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 5792 | #define HAVE_GETHOSTBYNAME_R 1 |
| 5793 | EOF |
| 5794 | |
| 5795 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5796 | #define HAVE_GETHOSTBYNAME_R_6_ARG 1 |
| 5797 | EOF |
| 5798 | |
| 5799 | echo "$ac_t""yes" 1>&6 |
| 5800 | |
| 5801 | else |
| 5802 | echo "configure: failed program was:" >&5 |
| 5803 | cat conftest.$ac_ext >&5 |
| 5804 | rm -rf conftest* |
| 5805 | |
| 5806 | echo "$ac_t""no" 1>&6 |
| 5807 | echo $ac_n "checking gethostbyname_r with 5 args""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5808 | echo "configure:5809: checking gethostbyname_r with 5 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5809 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5810 | #line 5811 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5811 | #include "confdefs.h" |
| 5812 | |
| 5813 | # include <netdb.h> |
| 5814 | |
| 5815 | int main() { |
| 5816 | |
| 5817 | char *name; |
| 5818 | struct hostent *he; |
| 5819 | char buffer[2048]; |
| 5820 | int buflen = 2048; |
| 5821 | int h_errnop; |
| 5822 | |
| 5823 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
| 5824 | |
| 5825 | ; return 0; } |
| 5826 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5827 | if { (eval echo configure:5828: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5828 | rm -rf conftest* |
| 5829 | |
| 5830 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 5831 | #define HAVE_GETHOSTBYNAME_R 1 |
| 5832 | EOF |
| 5833 | |
| 5834 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5835 | #define HAVE_GETHOSTBYNAME_R_5_ARG 1 |
| 5836 | EOF |
| 5837 | |
| 5838 | echo "$ac_t""yes" 1>&6 |
| 5839 | |
| 5840 | else |
| 5841 | echo "configure: failed program was:" >&5 |
| 5842 | cat conftest.$ac_ext >&5 |
| 5843 | rm -rf conftest* |
| 5844 | |
| 5845 | echo "$ac_t""no" 1>&6 |
| 5846 | echo $ac_n "checking gethostbyname_r with 3 args""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5847 | echo "configure:5848: checking gethostbyname_r with 3 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5848 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5849 | #line 5850 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5850 | #include "confdefs.h" |
| 5851 | |
| 5852 | # include <netdb.h> |
| 5853 | |
| 5854 | int main() { |
| 5855 | |
| 5856 | char *name; |
| 5857 | struct hostent *he; |
| 5858 | struct hostent_data data; |
| 5859 | |
| 5860 | (void) gethostbyname_r(name, he, &data); |
| 5861 | |
| 5862 | ; return 0; } |
| 5863 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5864 | if { (eval echo configure:5865: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5865 | rm -rf conftest* |
| 5866 | |
| 5867 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 5868 | #define HAVE_GETHOSTBYNAME_R 1 |
| 5869 | EOF |
| 5870 | |
| 5871 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5872 | #define HAVE_GETHOSTBYNAME_R_3_ARG 1 |
| 5873 | EOF |
| 5874 | |
| 5875 | echo "$ac_t""yes" 1>&6 |
| 5876 | |
| 5877 | else |
| 5878 | echo "configure: failed program was:" >&5 |
| 5879 | cat conftest.$ac_ext >&5 |
| 5880 | rm -rf conftest* |
| 5881 | |
| 5882 | echo "$ac_t""no" 1>&6 |
| 5883 | |
| 5884 | fi |
| 5885 | rm -f conftest* |
| 5886 | |
| 5887 | fi |
| 5888 | rm -f conftest* |
| 5889 | |
| 5890 | fi |
| 5891 | rm -f conftest* |
| 5892 | CFLAGS=$OLD_CFLAGS |
| 5893 | |
| 5894 | else |
| 5895 | echo "$ac_t""no" 1>&6 |
| 5896 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5897 | for ac_func in gethostbyname |
| 5898 | do |
| 5899 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5900 | echo "configure:5901: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5901 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5902 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5903 | else |
| 5904 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5905 | #line 5906 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5906 | #include "confdefs.h" |
| 5907 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5908 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5909 | #include <assert.h> |
| 5910 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5911 | /* We use char because int might match the return type of a gcc2 |
| 5912 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5913 | char $ac_func(); |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5914 | |
| 5915 | int main() { |
| 5916 | |
| 5917 | /* The GNU C library defines this for functions which it implements |
| 5918 | to always fail with ENOSYS. Some functions are actually named |
| 5919 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5920 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5921 | choke me |
| 5922 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5923 | $ac_func(); |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5924 | #endif |
| 5925 | |
| 5926 | ; return 0; } |
| 5927 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5928 | if { (eval echo configure:5929: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5929 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5930 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5931 | else |
| 5932 | echo "configure: failed program was:" >&5 |
| 5933 | cat conftest.$ac_ext >&5 |
| 5934 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5935 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5936 | fi |
| 5937 | rm -f conftest* |
| 5938 | fi |
| 5939 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5940 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5941 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5942 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 5943 | cat >> confdefs.h <<EOF |
| 5944 | #define $ac_tr_func 1 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5945 | EOF |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5946 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5947 | else |
| 5948 | echo "$ac_t""no" 1>&6 |
| 5949 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5950 | done |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5951 | |
| 5952 | |
| 5953 | fi |
| 5954 | |
| 5955 | |
| 5956 | |
| 5957 | |
| 5958 | |
| 5959 | |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 5960 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5961 | # checks for system services |
| 5962 | # (none yet) |
| 5963 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5964 | # Linux requires this for correct f.p. operations |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 5965 | echo $ac_n "checking for __fpu_control""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5966 | echo "configure:5967: checking for __fpu_control" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5967 | if eval "test \"`echo '$''{'ac_cv_func___fpu_control'+set}'`\" = set"; then |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 5968 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5969 | else |
| 5970 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5971 | #line 5972 "configure" |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 5972 | #include "confdefs.h" |
| 5973 | /* System header to define __stub macros and hopefully few prototypes, |
| 5974 | which can conflict with char __fpu_control(); below. */ |
| 5975 | #include <assert.h> |
| 5976 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5977 | /* We use char because int might match the return type of a gcc2 |
| 5978 | builtin and then its argument prototype would still apply. */ |
| 5979 | char __fpu_control(); |
| 5980 | |
| 5981 | int main() { |
| 5982 | |
| 5983 | /* The GNU C library defines this for functions which it implements |
| 5984 | to always fail with ENOSYS. Some functions are actually named |
| 5985 | something starting with __ and the normal name is an alias. */ |
| 5986 | #if defined (__stub___fpu_control) || defined (__stub_____fpu_control) |
| 5987 | choke me |
| 5988 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5989 | __fpu_control(); |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 5990 | #endif |
| 5991 | |
| 5992 | ; return 0; } |
| 5993 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 5994 | if { (eval echo configure:5995: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 5995 | rm -rf conftest* |
| 5996 | eval "ac_cv_func___fpu_control=yes" |
| 5997 | else |
| 5998 | echo "configure: failed program was:" >&5 |
| 5999 | cat conftest.$ac_ext >&5 |
| 6000 | rm -rf conftest* |
| 6001 | eval "ac_cv_func___fpu_control=no" |
| 6002 | fi |
| 6003 | rm -f conftest* |
| 6004 | fi |
| 6005 | |
| 6006 | if eval "test \"`echo '$ac_cv_func_'__fpu_control`\" = yes"; then |
| 6007 | echo "$ac_t""yes" 1>&6 |
| 6008 | : |
| 6009 | else |
| 6010 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6011 | echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6012 | echo "configure:6013: checking for __fpu_control in -lieee" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6013 | ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6014 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6015 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6016 | else |
| 6017 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6018 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6019 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6020 | #line 6021 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6021 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6022 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 6023 | /* We use char because int might match the return type of a gcc2 |
| 6024 | builtin and then its argument prototype would still apply. */ |
| 6025 | char __fpu_control(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6026 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6027 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6028 | __fpu_control() |
| 6029 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6030 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6031 | if { (eval echo configure:6032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6032 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6033 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6034 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6035 | echo "configure: failed program was:" >&5 |
| 6036 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6037 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6038 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6039 | fi |
| 6040 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6041 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6042 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6043 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6044 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6045 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6046 | ac_tr_lib=HAVE_LIB`echo ieee | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 6047 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6048 | cat >> confdefs.h <<EOF |
| 6049 | #define $ac_tr_lib 1 |
| 6050 | EOF |
| 6051 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6052 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6053 | |
| 6054 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6055 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6056 | fi |
| 6057 | |
| 6058 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 6059 | fi |
| 6060 | |
| 6061 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6062 | # Check for --with-fpectl |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6063 | echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6064 | echo "configure:6065: checking for --with-fpectl" >&5 |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6065 | # Check whether --with-fpectl or --without-fpectl was given. |
| 6066 | if test "${with_fpectl+set}" = set; then |
| 6067 | withval="$with_fpectl" |
| 6068 | |
| 6069 | if test "$withval" != no |
| 6070 | then cat >> confdefs.h <<\EOF |
| 6071 | #define WANT_SIGFPE_HANDLER 1 |
| 6072 | EOF |
| 6073 | echo "$ac_t""yes" 1>&6 |
| 6074 | else echo "$ac_t""no" 1>&6 |
| 6075 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6076 | else |
| 6077 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6078 | fi |
| 6079 | |
| 6080 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6081 | # check for --with-libm=... |
| 6082 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 6083 | case $ac_sys_system in |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 6084 | Darwin) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 6085 | next) ;; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6086 | BeOS) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 6087 | *) LIBM=-lm |
| 6088 | esac |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6089 | echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6090 | echo "configure:6091: checking for --with-libm=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6091 | # Check whether --with-libm or --without-libm was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6092 | if test "${with_libm+set}" = set; then |
| 6093 | withval="$with_libm" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6094 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6095 | if test "$withval" = no |
| 6096 | then LIBM= |
| 6097 | echo "$ac_t""force LIBM empty" 1>&6 |
| 6098 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6099 | then LIBM=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6100 | echo "$ac_t""set LIBM=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6101 | 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] | 6102 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6103 | else |
| 6104 | echo "$ac_t""default LIBM=\"$LIBM\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6105 | fi |
| 6106 | |
| 6107 | |
| 6108 | # check for --with-libc=... |
| 6109 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6110 | echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6111 | echo "configure:6112: checking for --with-libc=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6112 | # Check whether --with-libc or --without-libc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6113 | if test "${with_libc+set}" = set; then |
| 6114 | withval="$with_libc" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6115 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6116 | if test "$withval" = no |
| 6117 | then LIBC= |
| 6118 | echo "$ac_t""force LIBC empty" 1>&6 |
| 6119 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6120 | then LIBC=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6121 | echo "$ac_t""set LIBC=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6122 | 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] | 6123 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6124 | else |
| 6125 | echo "$ac_t""default LIBC=\"$LIBC\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6126 | fi |
| 6127 | |
| 6128 | |
Guido van Rossum | 4c3f57c | 2001-01-10 20:40:46 +0000 | [diff] [blame] | 6129 | # check for --with-check-import-case |
| 6130 | # Check whether --with-check-import-case or --without-check-import-case was given. |
| 6131 | if test "${with_check_import_case+set}" = set; then |
| 6132 | withval="$with_check_import_case" |
| 6133 | : |
| 6134 | fi |
| 6135 | |
| 6136 | echo $ac_n "checking for --with-check-import-case""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6137 | echo "configure:6138: checking for --with-check-import-case" >&5 |
Guido van Rossum | 4c3f57c | 2001-01-10 20:40:46 +0000 | [diff] [blame] | 6138 | if test "$with_check_import_case" |
| 6139 | then |
| 6140 | cat >> confdefs.h <<\EOF |
| 6141 | #define CHECK_IMPORT_CASE 1 |
| 6142 | EOF |
| 6143 | |
| 6144 | echo "$ac_t""yes" 1>&6 |
| 6145 | else |
| 6146 | echo "$ac_t""no" 1>&6 |
| 6147 | fi |
| 6148 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6149 | # check for hypot() in math library |
| 6150 | LIBS_SAVE=$LIBS |
| 6151 | LIBS="$LIBS $LIBM" |
| 6152 | for ac_func in hypot |
| 6153 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6154 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6155 | echo "configure:6156: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6156 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6157 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6158 | else |
| 6159 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6160 | #line 6161 "configure" |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6161 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6162 | /* System header to define __stub macros and hopefully few prototypes, |
| 6163 | which can conflict with char $ac_func(); below. */ |
| 6164 | #include <assert.h> |
| 6165 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6166 | /* We use char because int might match the return type of a gcc2 |
| 6167 | builtin and then its argument prototype would still apply. */ |
| 6168 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6169 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6170 | int main() { |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6171 | |
| 6172 | /* The GNU C library defines this for functions which it implements |
| 6173 | to always fail with ENOSYS. Some functions are actually named |
| 6174 | something starting with __ and the normal name is an alias. */ |
| 6175 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 6176 | choke me |
| 6177 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6178 | $ac_func(); |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6179 | #endif |
| 6180 | |
| 6181 | ; return 0; } |
| 6182 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6183 | if { (eval echo configure:6184: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6184 | rm -rf conftest* |
| 6185 | eval "ac_cv_func_$ac_func=yes" |
| 6186 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6187 | echo "configure: failed program was:" >&5 |
| 6188 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6189 | rm -rf conftest* |
| 6190 | eval "ac_cv_func_$ac_func=no" |
| 6191 | fi |
| 6192 | rm -f conftest* |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6193 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6194 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6195 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 6196 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6197 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 6198 | cat >> confdefs.h <<EOF |
| 6199 | #define $ac_tr_func 1 |
| 6200 | EOF |
| 6201 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6202 | else |
| 6203 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 6204 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6205 | fi |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6206 | done |
| 6207 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6208 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6209 | LIBS=$LIBS_SAVE |
| 6210 | |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 6211 | # check whether malloc(0) returns NULL or not |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 6212 | echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6213 | echo "configure:6214: checking what malloc(0) returns" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6214 | if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 6215 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6216 | else |
| 6217 | if test "$cross_compiling" = yes; then |
| 6218 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 6219 | else |
| 6220 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6221 | #line 6222 "configure" |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 6222 | #include "confdefs.h" |
| 6223 | #include <stdio.h> |
| 6224 | #ifdef HAVE_STDLIB |
| 6225 | #include <stdlib.h> |
| 6226 | #else |
| 6227 | char *malloc(), *realloc(); |
| 6228 | int *free(); |
| 6229 | #endif |
| 6230 | main() { |
| 6231 | char *p; |
| 6232 | p = malloc(0); |
| 6233 | if (p == NULL) exit(1); |
| 6234 | p = realloc(p, 0); |
| 6235 | if (p == NULL) exit(1); |
| 6236 | free(p); |
| 6237 | exit(0); |
| 6238 | } |
| 6239 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6240 | if { (eval echo configure:6241: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 6241 | then |
| 6242 | ac_cv_malloc_zero=nonnull |
| 6243 | else |
| 6244 | echo "configure: failed program was:" >&5 |
| 6245 | cat conftest.$ac_ext >&5 |
| 6246 | rm -fr conftest* |
| 6247 | ac_cv_malloc_zero=null |
| 6248 | fi |
| 6249 | rm -fr conftest* |
| 6250 | fi |
| 6251 | |
| 6252 | fi |
| 6253 | |
| 6254 | echo "$ac_t""$ac_cv_malloc_zero" 1>&6 |
| 6255 | if test "$ac_cv_malloc_zero" = null |
| 6256 | then |
| 6257 | cat >> confdefs.h <<\EOF |
| 6258 | #define MALLOC_ZERO_RETURNS_NULL 1 |
| 6259 | EOF |
| 6260 | |
| 6261 | fi |
| 6262 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6263 | # check for wchar.h |
| 6264 | ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'` |
| 6265 | echo $ac_n "checking for wchar.h""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6266 | echo "configure:6267: checking for wchar.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6267 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6268 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6269 | else |
| 6270 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6271 | #line 6272 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6272 | #include "confdefs.h" |
| 6273 | #include <wchar.h> |
| 6274 | EOF |
| 6275 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6276 | { (eval echo configure:6277: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6277 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 6278 | if test -z "$ac_err"; then |
| 6279 | rm -rf conftest* |
| 6280 | eval "ac_cv_header_$ac_safe=yes" |
| 6281 | else |
| 6282 | echo "$ac_err" >&5 |
| 6283 | echo "configure: failed program was:" >&5 |
| 6284 | cat conftest.$ac_ext >&5 |
| 6285 | rm -rf conftest* |
| 6286 | eval "ac_cv_header_$ac_safe=no" |
| 6287 | fi |
| 6288 | rm -f conftest* |
| 6289 | fi |
| 6290 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 6291 | echo "$ac_t""yes" 1>&6 |
| 6292 | cat >> confdefs.h <<\EOF |
| 6293 | #define HAVE_WCHAR_H 1 |
| 6294 | EOF |
| 6295 | wchar_h="yes" |
| 6296 | else |
| 6297 | echo "$ac_t""no" 1>&6 |
| 6298 | wchar_h="no" |
| 6299 | |
| 6300 | fi |
| 6301 | |
| 6302 | |
| 6303 | # check for usable wchar_t |
| 6304 | usable_wchar_t="unkown" |
| 6305 | echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6306 | echo "configure:6307: checking for usable wchar_t" >&5 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6307 | if test "$cross_compiling" = yes; then |
| 6308 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 6309 | else |
| 6310 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6311 | #line 6312 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6312 | #include "confdefs.h" |
| 6313 | |
| 6314 | #include "wchar.h" |
| 6315 | #include "wctype.h" |
| 6316 | main() { |
| 6317 | wchar_t s; |
| 6318 | if (sizeof(s) == 2) |
| 6319 | exit(0); |
| 6320 | else |
| 6321 | exit(1); |
| 6322 | } |
| 6323 | |
| 6324 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6325 | if { (eval echo configure:6326: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6326 | then |
| 6327 | cat >> confdefs.h <<\EOF |
| 6328 | #define HAVE_USABLE_WCHAR_T 1 |
| 6329 | EOF |
| 6330 | usable_wchar_t="yes" |
| 6331 | else |
| 6332 | echo "configure: failed program was:" >&5 |
| 6333 | cat conftest.$ac_ext >&5 |
| 6334 | rm -fr conftest* |
| 6335 | usable_wchar_t="no" |
| 6336 | fi |
| 6337 | rm -fr conftest* |
| 6338 | fi |
| 6339 | |
| 6340 | echo "$ac_t""$usable_wchar_t" 1>&6 |
| 6341 | |
| 6342 | # check for endianness |
| 6343 | echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6344 | echo "configure:6345: checking whether byte ordering is bigendian" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6345 | if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6346 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6347 | else |
| 6348 | ac_cv_c_bigendian=unknown |
| 6349 | # See if sys/param.h defines the BYTE_ORDER macro. |
| 6350 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6351 | #line 6352 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6352 | #include "confdefs.h" |
| 6353 | #include <sys/types.h> |
| 6354 | #include <sys/param.h> |
| 6355 | int main() { |
| 6356 | |
| 6357 | #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN |
| 6358 | bogus endian macros |
| 6359 | #endif |
| 6360 | ; return 0; } |
| 6361 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6362 | if { (eval echo configure:6363: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6363 | rm -rf conftest* |
| 6364 | # It does; now see whether it defined to BIG_ENDIAN or not. |
| 6365 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6366 | #line 6367 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6367 | #include "confdefs.h" |
| 6368 | #include <sys/types.h> |
| 6369 | #include <sys/param.h> |
| 6370 | int main() { |
| 6371 | |
| 6372 | #if BYTE_ORDER != BIG_ENDIAN |
| 6373 | not big endian |
| 6374 | #endif |
| 6375 | ; return 0; } |
| 6376 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6377 | if { (eval echo configure:6378: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6378 | rm -rf conftest* |
| 6379 | ac_cv_c_bigendian=yes |
| 6380 | else |
| 6381 | echo "configure: failed program was:" >&5 |
| 6382 | cat conftest.$ac_ext >&5 |
| 6383 | rm -rf conftest* |
| 6384 | ac_cv_c_bigendian=no |
| 6385 | fi |
| 6386 | rm -f conftest* |
| 6387 | else |
| 6388 | echo "configure: failed program was:" >&5 |
| 6389 | cat conftest.$ac_ext >&5 |
| 6390 | fi |
| 6391 | rm -f conftest* |
| 6392 | if test $ac_cv_c_bigendian = unknown; then |
| 6393 | if test "$cross_compiling" = yes; then |
| 6394 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 6395 | else |
| 6396 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6397 | #line 6398 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6398 | #include "confdefs.h" |
| 6399 | main () { |
| 6400 | /* Are we little or big endian? From Harbison&Steele. */ |
| 6401 | union |
| 6402 | { |
| 6403 | long l; |
| 6404 | char c[sizeof (long)]; |
| 6405 | } u; |
| 6406 | u.l = 1; |
| 6407 | exit (u.c[sizeof (long) - 1] == 1); |
| 6408 | } |
| 6409 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6410 | if { (eval echo configure:6411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6411 | then |
| 6412 | ac_cv_c_bigendian=no |
| 6413 | else |
| 6414 | echo "configure: failed program was:" >&5 |
| 6415 | cat conftest.$ac_ext >&5 |
| 6416 | rm -fr conftest* |
| 6417 | ac_cv_c_bigendian=yes |
| 6418 | fi |
| 6419 | rm -fr conftest* |
| 6420 | fi |
| 6421 | |
| 6422 | fi |
| 6423 | fi |
| 6424 | |
| 6425 | echo "$ac_t""$ac_cv_c_bigendian" 1>&6 |
| 6426 | if test $ac_cv_c_bigendian = yes; then |
| 6427 | cat >> confdefs.h <<\EOF |
| 6428 | #define WORDS_BIGENDIAN 1 |
| 6429 | EOF |
| 6430 | |
| 6431 | fi |
| 6432 | |
| 6433 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6434 | # Check whether right shifting a negative integer extends the sign bit |
| 6435 | # or fills with zeros (like the Cray J90, according to Tim Peters). |
| 6436 | echo $ac_n "checking whether right shift extends the sign bit""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6437 | echo "configure:6438: checking whether right shift extends the sign bit" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6438 | if eval "test \"`echo '$''{'ac_cv_rshift_extends_sign'+set}'`\" = set"; then |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 6439 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6440 | else |
| 6441 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6442 | if test "$cross_compiling" = yes; then |
| 6443 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 6444 | else |
| 6445 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6446 | #line 6447 "configure" |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6447 | #include "confdefs.h" |
| 6448 | |
| 6449 | int main() |
| 6450 | { |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 6451 | exit(((-1)>>3 == -1) ? 0 : 1); |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6452 | } |
| 6453 | |
| 6454 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6455 | if { (eval echo configure:6456: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 6456 | then |
| 6457 | ac_cv_rshift_extends_sign=yes |
| 6458 | else |
| 6459 | echo "configure: failed program was:" >&5 |
| 6460 | cat conftest.$ac_ext >&5 |
| 6461 | rm -fr conftest* |
| 6462 | ac_cv_rshift_extends_sign=no |
| 6463 | fi |
| 6464 | rm -fr conftest* |
| 6465 | fi |
| 6466 | |
| 6467 | fi |
| 6468 | |
| 6469 | echo "$ac_t""$ac_cv_rshift_extends_sign" 1>&6 |
| 6470 | if test "$ac_cv_rshift_extends_sign" = no |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6471 | then |
| 6472 | cat >> confdefs.h <<\EOF |
| 6473 | #define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1 |
| 6474 | EOF |
| 6475 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6476 | fi |
| 6477 | |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 6478 | # check for getc_unlocked and related locking functions |
| 6479 | echo $ac_n "checking for getc_unlocked() and friends""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6480 | echo "configure:6481: checking for getc_unlocked() and friends" >&5 |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 6481 | if eval "test \"`echo '$''{'ac_cv_have_getc_unlocked'+set}'`\" = set"; then |
| 6482 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6483 | else |
| 6484 | |
| 6485 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6486 | #line 6487 "configure" |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 6487 | #include "confdefs.h" |
| 6488 | #include <stdio.h> |
| 6489 | int main() { |
| 6490 | |
| 6491 | FILE *f = fopen("/dev/null", "r"); |
| 6492 | flockfile(f); |
| 6493 | getc_unlocked(f); |
| 6494 | funlockfile(f); |
| 6495 | |
| 6496 | ; return 0; } |
| 6497 | EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6498 | if { (eval echo configure:6499: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 6499 | rm -rf conftest* |
| 6500 | ac_cv_have_getc_unlocked=yes |
| 6501 | else |
| 6502 | echo "configure: failed program was:" >&5 |
| 6503 | cat conftest.$ac_ext >&5 |
| 6504 | rm -rf conftest* |
| 6505 | ac_cv_have_getc_unlocked=no |
| 6506 | fi |
| 6507 | rm -f conftest* |
| 6508 | fi |
| 6509 | |
| 6510 | echo "$ac_t""$ac_cv_have_getc_unlocked" 1>&6 |
| 6511 | if test "$ac_cv_have_getc_unlocked" = yes |
| 6512 | then |
| 6513 | cat >> confdefs.h <<\EOF |
| 6514 | #define HAVE_GETC_UNLOCKED 1 |
| 6515 | EOF |
| 6516 | |
| 6517 | fi |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6518 | |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6519 | # THIS MUST BE LAST, IT CAN BREAK OTHER TESTS! |
| 6520 | # Add sys/socket.h to confdefs.h |
| 6521 | cat >> confdefs.h <<\EOF |
| 6522 | #ifdef HAVE_SYS_SOCKET_H |
| 6523 | #include <sys/socket.h> |
| 6524 | #endif |
| 6525 | EOF |
| 6526 | echo $ac_n "checking for socklen_t""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6527 | echo "configure:6528: checking for socklen_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6528 | if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6529 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6530 | else |
| 6531 | cat > conftest.$ac_ext <<EOF |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6532 | #line 6533 "configure" |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6533 | #include "confdefs.h" |
| 6534 | #include <sys/types.h> |
| 6535 | #if STDC_HEADERS |
| 6536 | #include <stdlib.h> |
| 6537 | #include <stddef.h> |
| 6538 | #endif |
| 6539 | EOF |
| 6540 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 6541 | egrep "(^|[^a-zA-Z_0-9])socklen_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
| 6542 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6543 | ac_cv_type_socklen_t=yes |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6544 | else |
| 6545 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6546 | ac_cv_type_socklen_t=no |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6547 | fi |
| 6548 | rm -f conftest* |
| 6549 | |
| 6550 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6551 | echo "$ac_t""$ac_cv_type_socklen_t" 1>&6 |
| 6552 | if test $ac_cv_type_socklen_t = no; then |
| 6553 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6554 | #define socklen_t int |
| 6555 | EOF |
| 6556 | |
| 6557 | fi |
| 6558 | |
| 6559 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6560 | #AC_MSG_CHECKING(for Modules/Setup) |
| 6561 | #if test ! -f Modules/Setup ; then |
| 6562 | # if test ! -d Modules ; then |
| 6563 | # mkdir Modules |
| 6564 | # fi |
| 6565 | # cp "$srcdir/Modules/Setup.dist" Modules/Setup |
| 6566 | # AC_MSG_RESULT(creating) |
| 6567 | #else |
| 6568 | # AC_MSG_RESULT(already exists) |
| 6569 | #fi |
| 6570 | |
| 6571 | |
| 6572 | SRCDIRS="Parser Grammar Objects Python Modules" |
Andrew M. Kuchling | 8abedde | 2001-01-26 22:55:24 +0000 | [diff] [blame] | 6573 | echo $ac_n "checking for build directories""... $ac_c" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6574 | echo "configure:6575: checking for build directories" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6575 | for dir in $SRCDIRS; do |
| 6576 | if test ! -d $dir; then |
| 6577 | mkdir $dir |
Guido van Rossum | 262cf20 | 2000-11-02 19:33:53 +0000 | [diff] [blame] | 6578 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6579 | done |
| 6580 | echo "$ac_t""done" 1>&6 |
Fred Drake | 036144d | 2000-10-26 17:09:35 +0000 | [diff] [blame] | 6581 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6582 | # generate output files |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6583 | trap '' 1 2 15 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6584 | cat > confcache <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6585 | # This file is a shell script that caches the results of configure |
| 6586 | # tests run on this system so they can be shared between configure |
| 6587 | # scripts and configure runs. It is not useful on other systems. |
| 6588 | # If it contains results you don't want to keep, you may remove or edit it. |
| 6589 | # |
| 6590 | # By default, configure uses ./config.cache as the cache file, |
| 6591 | # creating it if it does not exist already. You can give configure |
| 6592 | # the --cache-file=FILE option to use a different cache file; that is |
| 6593 | # what configure does when it calls configure scripts in |
| 6594 | # subdirectories, so they share the cache. |
| 6595 | # Giving --cache-file=/dev/null disables caching, for debugging configure. |
| 6596 | # config.status only pays attention to the cache file if you give it the |
| 6597 | # --recheck option to rerun configure. |
| 6598 | # |
| 6599 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6600 | # The following way of writing the cache mishandles newlines in values, |
| 6601 | # but we know of no workaround that is simple, portable, and efficient. |
| 6602 | # So, don't put newlines in cache variables' values. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6603 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 6604 | # and sets the high bit in the cache file unless we assign to the vars. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6605 | (set) 2>&1 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 6606 | case `(ac_space=' '; set | grep ac_space) 2>&1` in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6607 | *ac_space=\ *) |
| 6608 | # `set' does not quote correctly, so add quotes (double-quote substitution |
| 6609 | # turns \\\\ into \\, and sed turns \\ into \). |
| 6610 | sed -n \ |
| 6611 | -e "s/'/'\\\\''/g" \ |
| 6612 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" |
| 6613 | ;; |
| 6614 | *) |
| 6615 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
| 6616 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' |
| 6617 | ;; |
| 6618 | esac >> confcache |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6619 | if cmp -s $cache_file confcache; then |
| 6620 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6621 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6622 | if test -w $cache_file; then |
| 6623 | echo "updating cache $cache_file" |
| 6624 | cat confcache > $cache_file |
| 6625 | else |
| 6626 | echo "not updating unwritable cache $cache_file" |
| 6627 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6628 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6629 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 6630 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6631 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6632 | |
| 6633 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 6634 | # Let make expand exec_prefix. |
| 6635 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 6636 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6637 | # Any assignment to VPATH causes Sun make to only execute |
| 6638 | # the first set of double-colon rules, so remove it if not needed. |
| 6639 | # If there is a colon in the path, we need to keep it. |
| 6640 | if test "x$srcdir" = x.; then |
| 6641 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
| 6642 | fi |
| 6643 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6644 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6645 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6646 | DEFS=-DHAVE_CONFIG_H |
| 6647 | |
| 6648 | # Without the "./", some shells look in PATH for config.status. |
| 6649 | : ${CONFIG_STATUS=./config.status} |
| 6650 | |
| 6651 | echo creating $CONFIG_STATUS |
| 6652 | rm -f $CONFIG_STATUS |
| 6653 | cat > $CONFIG_STATUS <<EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6654 | #! /bin/sh |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6655 | # Generated automatically by configure. |
| 6656 | # Run this file to recreate the current configuration. |
| 6657 | # This directory was configured as follows, |
| 6658 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
| 6659 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6660 | # $0 $ac_configure_args |
| 6661 | # |
| 6662 | # Compiler output produced by configure, useful for debugging |
| 6663 | # configure, is in ./config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6664 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6665 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6666 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6667 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6668 | case "\$ac_option" in |
| 6669 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6670 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
| 6671 | 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] | 6672 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6673 | echo "$CONFIG_STATUS generated by autoconf version 2.13" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6674 | exit 0 ;; |
| 6675 | -help | --help | --hel | --he | --h) |
| 6676 | echo "\$ac_cs_usage"; exit 0 ;; |
| 6677 | *) echo "\$ac_cs_usage"; exit 1 ;; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6678 | esac |
| 6679 | done |
| 6680 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6681 | ac_given_srcdir=$srcdir |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6682 | ac_given_INSTALL="$INSTALL" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6683 | |
Andrew M. Kuchling | 8abedde | 2001-01-26 22:55:24 +0000 | [diff] [blame] | 6684 | trap 'rm -fr `echo "Makefile.pre Modules/Setup.config config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6685 | EOF |
| 6686 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6687 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6688 | # Protect against being on the right side of a sed subst in config.status. |
| 6689 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; |
| 6690 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6691 | $ac_vpsub |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6692 | $extrasub |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 6693 | s%@SHELL@%$SHELL%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6694 | s%@CFLAGS@%$CFLAGS%g |
| 6695 | s%@CPPFLAGS@%$CPPFLAGS%g |
| 6696 | s%@CXXFLAGS@%$CXXFLAGS%g |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 6697 | s%@FFLAGS@%$FFLAGS%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6698 | s%@DEFS@%$DEFS%g |
| 6699 | s%@LDFLAGS@%$LDFLAGS%g |
| 6700 | s%@LIBS@%$LIBS%g |
| 6701 | s%@exec_prefix@%$exec_prefix%g |
| 6702 | s%@prefix@%$prefix%g |
| 6703 | s%@program_transform_name@%$program_transform_name%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6704 | s%@bindir@%$bindir%g |
| 6705 | s%@sbindir@%$sbindir%g |
| 6706 | s%@libexecdir@%$libexecdir%g |
| 6707 | s%@datadir@%$datadir%g |
| 6708 | s%@sysconfdir@%$sysconfdir%g |
| 6709 | s%@sharedstatedir@%$sharedstatedir%g |
| 6710 | s%@localstatedir@%$localstatedir%g |
| 6711 | s%@libdir@%$libdir%g |
| 6712 | s%@includedir@%$includedir%g |
| 6713 | s%@oldincludedir@%$oldincludedir%g |
| 6714 | s%@infodir@%$infodir%g |
| 6715 | s%@mandir@%$mandir%g |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 6716 | s%@VERSION@%$VERSION%g |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 6717 | s%@MACHDEP@%$MACHDEP%g |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 6718 | s%@SGI_ABI@%$SGI_ABI%g |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 6719 | s%@CXX@%$CXX%g |
Guido van Rossum | ca563f2 | 2001-01-23 01:52:44 +0000 | [diff] [blame] | 6720 | s%@MAINOBJ@%$MAINOBJ%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6721 | s%@CC@%$CC%g |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6722 | s%@EXEEXT@%$EXEEXT%g |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 6723 | s%@LIBRARY@%$LIBRARY%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 6724 | s%@LDLIBRARY@%$LDLIBRARY%g |
Guido van Rossum | ca563f2 | 2001-01-23 01:52:44 +0000 | [diff] [blame] | 6725 | s%@DLLLIBRARY@%$DLLLIBRARY%g |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 6726 | s%@LINKCC@%$LINKCC%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6727 | s%@RANLIB@%$RANLIB%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6728 | s%@AR@%$AR%g |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6729 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6730 | s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6731 | s%@INSTALL_DATA@%$INSTALL_DATA%g |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6732 | s%@LN@%$LN%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 6733 | s%@OPT@%$OPT%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6734 | s%@CPP@%$CPP%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 6735 | s%@LIBTOOL_CRUFT@%$LIBTOOL_CRUFT%g |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 6736 | s%@SO@%$SO%g |
| 6737 | s%@LDSHARED@%$LDSHARED%g |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame^] | 6738 | s%@BLDSHARED@%$BLDSHARED%g |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 6739 | s%@CCSHARED@%$CCSHARED%g |
| 6740 | s%@LINKFORSHARED@%$LINKFORSHARED%g |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 6741 | s%@CFLAGSFORSHARED@%$CFLAGSFORSHARED%g |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 6742 | s%@USE_NCURSES_MODULE@%$USE_NCURSES_MODULE%g |
| 6743 | s%@USE_READLINE_MODULE@%$USE_READLINE_MODULE%g |
Eric S. Raymond | a888540 | 2001-01-17 08:25:11 +0000 | [diff] [blame] | 6744 | s%@USE_GDBM_MODULE@%$USE_GDBM_MODULE%g |
| 6745 | s%@HAVE_LIBGDBM@%$HAVE_LIBGDBM%g |
| 6746 | s%@USE_NDBM_MODULE@%$USE_NDBM_MODULE%g |
| 6747 | s%@HAVE_LIBNDBM@%$HAVE_LIBNDBM%g |
| 6748 | s%@USE_CRYPT_MODULE@%$USE_CRYPT_MODULE%g |
| 6749 | s%@HAVE_LIBCRYPT@%$HAVE_LIBCRYPT%g |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6750 | s%@USE_SIGNAL_MODULE@%$USE_SIGNAL_MODULE%g |
| 6751 | s%@SIGNAL_OBJS@%$SIGNAL_OBJS%g |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 6752 | s%@USE_THREAD_MODULE@%$USE_THREAD_MODULE%g |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 6753 | s%@LDLAST@%$LDLAST%g |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 6754 | s%@USE_GC_MODULE@%$USE_GC_MODULE%g |
Barry Warsaw | a57b89b | 2001-01-15 17:07:21 +0000 | [diff] [blame] | 6755 | s%@USE_DBM_MODULE@%$USE_DBM_MODULE%g |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 6756 | s%@USE_BSDDB_MODULE@%$USE_BSDDB_MODULE%g |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 6757 | s%@HAVE_LIBDB@%$HAVE_LIBDB%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6758 | s%@DLINCLDIR@%$DLINCLDIR%g |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 6759 | s%@DYNLOADFILE@%$DYNLOADFILE%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6760 | s%@LIBOBJS@%$LIBOBJS%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6761 | s%@HAVE_GETHOSTBYNAME_R_6_ARG@%$HAVE_GETHOSTBYNAME_R_6_ARG%g |
| 6762 | s%@HAVE_GETHOSTBYNAME_R_5_ARG@%$HAVE_GETHOSTBYNAME_R_5_ARG%g |
| 6763 | s%@HAVE_GETHOSTBYNAME_R_3_ARG@%$HAVE_GETHOSTBYNAME_R_3_ARG%g |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 6764 | s%@HAVE_GETHOSTBYNAME_R@%$HAVE_GETHOSTBYNAME_R%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6765 | s%@HAVE_GETHOSTBYNAME@%$HAVE_GETHOSTBYNAME%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6766 | s%@LIBM@%$LIBM%g |
| 6767 | s%@LIBC@%$LIBC%g |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6768 | s%@SRCDIRS@%$SRCDIRS%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6769 | |
| 6770 | CEOF |
| 6771 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6772 | |
| 6773 | cat >> $CONFIG_STATUS <<\EOF |
| 6774 | |
| 6775 | # Split the substitutions into bite-sized pieces for seds with |
| 6776 | # small command number limits, like on Digital OSF/1 and HP-UX. |
| 6777 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. |
| 6778 | ac_file=1 # Number of current file. |
| 6779 | ac_beg=1 # First line for current file. |
| 6780 | ac_end=$ac_max_sed_cmds # Line after last line for current file. |
| 6781 | ac_more_lines=: |
| 6782 | ac_sed_cmds="" |
| 6783 | while $ac_more_lines; do |
| 6784 | if test $ac_beg -gt 1; then |
| 6785 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file |
| 6786 | else |
| 6787 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file |
| 6788 | fi |
| 6789 | if test ! -s conftest.s$ac_file; then |
| 6790 | ac_more_lines=false |
| 6791 | rm -f conftest.s$ac_file |
| 6792 | else |
| 6793 | if test -z "$ac_sed_cmds"; then |
| 6794 | ac_sed_cmds="sed -f conftest.s$ac_file" |
| 6795 | else |
| 6796 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" |
| 6797 | fi |
| 6798 | ac_file=`expr $ac_file + 1` |
| 6799 | ac_beg=$ac_end |
| 6800 | ac_end=`expr $ac_end + $ac_max_sed_cmds` |
| 6801 | fi |
| 6802 | done |
| 6803 | if test -z "$ac_sed_cmds"; then |
| 6804 | ac_sed_cmds=cat |
| 6805 | fi |
| 6806 | EOF |
| 6807 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6808 | cat >> $CONFIG_STATUS <<EOF |
| 6809 | |
Andrew M. Kuchling | 8abedde | 2001-01-26 22:55:24 +0000 | [diff] [blame] | 6810 | CONFIG_FILES=\${CONFIG_FILES-"Makefile.pre Modules/Setup.config"} |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6811 | EOF |
| 6812 | cat >> $CONFIG_STATUS <<\EOF |
| 6813 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6814 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6815 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6816 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6817 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 6818 | *) ac_file_in="${ac_file}.in" ;; |
| 6819 | esac |
| 6820 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6821 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6822 | |
| 6823 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 6824 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 6825 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 6826 | # The file is in a subdirectory. |
| 6827 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6828 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6829 | # A "../" for each directory in $ac_dir_suffix. |
| 6830 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
| 6831 | else |
| 6832 | ac_dir_suffix= ac_dots= |
| 6833 | fi |
| 6834 | |
| 6835 | case "$ac_given_srcdir" in |
| 6836 | .) srcdir=. |
| 6837 | if test -z "$ac_dots"; then top_srcdir=. |
| 6838 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; |
| 6839 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; |
| 6840 | *) # Relative path. |
| 6841 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
| 6842 | top_srcdir="$ac_dots$ac_given_srcdir" ;; |
| 6843 | esac |
| 6844 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6845 | case "$ac_given_INSTALL" in |
| 6846 | [/$]*) INSTALL="$ac_given_INSTALL" ;; |
| 6847 | *) INSTALL="$ac_dots$ac_given_INSTALL" ;; |
| 6848 | esac |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6849 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6850 | echo creating "$ac_file" |
| 6851 | rm -f "$ac_file" |
| 6852 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." |
| 6853 | case "$ac_file" in |
| 6854 | *Makefile*) ac_comsub="1i\\ |
| 6855 | # $configure_input" ;; |
| 6856 | *) ac_comsub= ;; |
| 6857 | esac |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6858 | |
| 6859 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6860 | sed -e "$ac_comsub |
| 6861 | s%@configure_input@%$configure_input%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6862 | s%@srcdir@%$srcdir%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6863 | s%@top_srcdir@%$top_srcdir%g |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6864 | s%@INSTALL@%$INSTALL%g |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6865 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6866 | fi; done |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6867 | rm -f conftest.s* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6868 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6869 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
| 6870 | # 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] | 6871 | # |
| 6872 | # ac_d sets the value in "#define NAME VALUE" lines. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6873 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
| 6874 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6875 | ac_dC='\3' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6876 | ac_dD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6877 | # 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] | 6878 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 6879 | ac_uB='\([ ]\)%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6880 | ac_uC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6881 | ac_uD='\4%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6882 | # 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] | 6883 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 6884 | ac_eB='$%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6885 | ac_eC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6886 | ac_eD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6887 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6888 | if test "${CONFIG_HEADERS+set}" != set; then |
| 6889 | EOF |
| 6890 | cat >> $CONFIG_STATUS <<EOF |
| 6891 | CONFIG_HEADERS="config.h" |
| 6892 | EOF |
| 6893 | cat >> $CONFIG_STATUS <<\EOF |
| 6894 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6895 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6896 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6897 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6898 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6899 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 6900 | *) ac_file_in="${ac_file}.in" ;; |
| 6901 | esac |
| 6902 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6903 | echo creating $ac_file |
| 6904 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6905 | rm -f conftest.frag conftest.in conftest.out |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6906 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
| 6907 | cat $ac_file_inputs > conftest.in |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6908 | |
| 6909 | EOF |
| 6910 | |
| 6911 | # Transform confdefs.h into a sed script conftest.vals that substitutes |
| 6912 | # the proper values into config.h.in to produce config.h. And first: |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6913 | # Protect against being on the right side of a sed subst in config.status. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6914 | # Protect against being in an unquoted here document in config.status. |
| 6915 | rm -f conftest.vals |
| 6916 | cat > conftest.hdr <<\EOF |
| 6917 | s/[\\&%]/\\&/g |
| 6918 | s%[\\$`]%\\&%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6919 | s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6920 | s%ac_d%ac_u%gp |
| 6921 | s%ac_u%ac_e%gp |
| 6922 | EOF |
| 6923 | sed -n -f conftest.hdr confdefs.h > conftest.vals |
| 6924 | rm -f conftest.hdr |
| 6925 | |
| 6926 | # This sed command replaces #undef with comments. This is necessary, for |
| 6927 | # example, in the case of _POSIX_SOURCE, which is predefined and required |
| 6928 | # on some systems where configure will not decide to define it. |
| 6929 | cat >> conftest.vals <<\EOF |
| 6930 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% |
| 6931 | EOF |
| 6932 | |
| 6933 | # Break up conftest.vals because some shells have a limit on |
| 6934 | # the size of here documents, and old seds have small limits too. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6935 | |
| 6936 | rm -f conftest.tail |
| 6937 | while : |
| 6938 | do |
| 6939 | ac_lines=`grep -c . conftest.vals` |
| 6940 | # grep -c gives empty output for an empty file on some AIX systems. |
| 6941 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi |
| 6942 | # Write a limited-size here document to conftest.frag. |
| 6943 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS |
| 6944 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS |
| 6945 | echo 'CEOF |
| 6946 | sed -f conftest.frag conftest.in > conftest.out |
| 6947 | rm -f conftest.in |
| 6948 | mv conftest.out conftest.in |
| 6949 | ' >> $CONFIG_STATUS |
| 6950 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
| 6951 | rm -f conftest.vals |
| 6952 | mv conftest.tail conftest.vals |
| 6953 | done |
| 6954 | rm -f conftest.vals |
| 6955 | |
| 6956 | cat >> $CONFIG_STATUS <<\EOF |
| 6957 | rm -f conftest.frag conftest.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6958 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6959 | cat conftest.in >> conftest.h |
| 6960 | rm -f conftest.in |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6961 | if cmp -s $ac_file conftest.h 2>/dev/null; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6962 | echo "$ac_file is unchanged" |
| 6963 | rm -f conftest.h |
| 6964 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6965 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 6966 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 6967 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 6968 | # The file is in a subdirectory. |
| 6969 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
| 6970 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6971 | rm -f $ac_file |
| 6972 | mv conftest.h $ac_file |
| 6973 | fi |
| 6974 | fi; done |
| 6975 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6976 | EOF |
| 6977 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6978 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6979 | EOF |
| 6980 | cat >> $CONFIG_STATUS <<\EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6981 | |
| 6982 | exit 0 |
| 6983 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6984 | chmod +x $CONFIG_STATUS |
| 6985 | rm -fr confdefs* $ac_clean_files |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6986 | test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6987 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 6988 | |
| 6989 | echo "creating Setup" |
| 6990 | if test ! -f Modules/Setup |
| 6991 | then |
| 6992 | cp $srcdir/Modules/Setup.dist Modules/Setup |
| 6993 | fi |
| 6994 | |
| 6995 | echo "creating Setup.local" |
| 6996 | if test ! -f Modules/Setup.local |
| 6997 | then |
| 6998 | echo "# Edit this file for local setup changes" >Modules/Setup.local |
| 6999 | fi |
| 7000 | |
| 7001 | echo "creating Makefile" |
| 7002 | $SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \ |
| 7003 | -s Modules Modules/Setup.config \ |
| 7004 | Modules/Setup Modules/Setup.local |