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 | |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3 | # From configure.in Revision: 1.165 |
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. |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +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 |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 19 | --with-next-framework Build (OpenStep|Rhapsody|MacOSX) framework" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 20 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 21 | --with-dyld Use (OpenStep|Rhapsody|MacOSX) 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 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +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 |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 33 | --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries" |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 34 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 35 | --with(out)-threads[=DIRECTORY] disable/enable thread support" |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 36 | ac_help="$ac_help |
Barry Warsaw | a0f3c5c | 2000-06-30 16:39:35 +0000 | [diff] [blame] | 37 | --with(out)-thread[=DIRECTORY] deprecated; use --with(out)-threads" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 38 | ac_help="$ac_help |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 39 | --with-pth use GNU pth threading libraries" |
| 40 | ac_help="$ac_help |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 41 | --with(out)-cycle-gc disable/enable garbage collection" |
| 42 | ac_help="$ac_help |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 43 | --with(out)-libdb disable/enable bsddb module" |
| 44 | ac_help="$ac_help |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 45 | --with-wctype-functions use wctype.h functions" |
| 46 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 47 | --with-sgi-dl=DIRECTORY IRIX 4 dynamic linking" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 48 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 49 | --with-dl-dld=DL_DIR,DLD_DIR GNU dynamic linking" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 50 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 51 | --with-fpectl enable SIGFPE catching" |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 52 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 53 | --with-libm=STRING math library" |
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-libc=STRING C library" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 56 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 57 | # Initialize some variables set by options. |
| 58 | # The variables have the same names as the options, with |
| 59 | # dashes changed to underlines. |
| 60 | build=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 61 | cache_file=./config.cache |
| 62 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 63 | host=NONE |
| 64 | no_create= |
| 65 | nonopt=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 66 | no_recursion= |
| 67 | prefix=NONE |
| 68 | program_prefix=NONE |
| 69 | program_suffix=NONE |
| 70 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 71 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 72 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 73 | srcdir= |
| 74 | target=NONE |
| 75 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 76 | x_includes=NONE |
| 77 | x_libraries=NONE |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 78 | bindir='${exec_prefix}/bin' |
| 79 | sbindir='${exec_prefix}/sbin' |
| 80 | libexecdir='${exec_prefix}/libexec' |
| 81 | datadir='${prefix}/share' |
| 82 | sysconfdir='${prefix}/etc' |
| 83 | sharedstatedir='${prefix}/com' |
| 84 | localstatedir='${prefix}/var' |
| 85 | libdir='${exec_prefix}/lib' |
| 86 | includedir='${prefix}/include' |
| 87 | oldincludedir='/usr/include' |
| 88 | infodir='${prefix}/info' |
| 89 | mandir='${prefix}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 90 | |
| 91 | # Initialize some other variables. |
| 92 | subdirs= |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 93 | MFLAGS= MAKEFLAGS= |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 94 | SHELL=${CONFIG_SHELL-/bin/sh} |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 95 | # Maximum number of lines to put in a shell here document. |
| 96 | ac_max_here_lines=12 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 97 | |
| 98 | ac_prev= |
| 99 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 100 | do |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 101 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 102 | # If the previous option needs an argument, assign it. |
| 103 | if test -n "$ac_prev"; then |
| 104 | eval "$ac_prev=\$ac_option" |
| 105 | ac_prev= |
| 106 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 107 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 108 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 109 | case "$ac_option" in |
| 110 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; |
| 111 | *) ac_optarg= ;; |
| 112 | esac |
| 113 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 114 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 115 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 116 | case "$ac_option" in |
| 117 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 118 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 119 | ac_prev=bindir ;; |
| 120 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
| 121 | bindir="$ac_optarg" ;; |
| 122 | |
| 123 | -build | --build | --buil | --bui | --bu) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 124 | ac_prev=build ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 125 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 126 | build="$ac_optarg" ;; |
| 127 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 128 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 129 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 130 | ac_prev=cache_file ;; |
| 131 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 132 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
| 133 | cache_file="$ac_optarg" ;; |
| 134 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 135 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
| 136 | ac_prev=datadir ;; |
| 137 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ |
| 138 | | --da=*) |
| 139 | datadir="$ac_optarg" ;; |
| 140 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 141 | -disable-* | --disable-*) |
| 142 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 143 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 144 | 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] | 145 | { 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] | 146 | fi |
| 147 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 148 | eval "enable_${ac_feature}=no" ;; |
| 149 | |
| 150 | -enable-* | --enable-*) |
| 151 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 152 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 153 | 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] | 154 | { 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] | 155 | fi |
| 156 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 157 | case "$ac_option" in |
| 158 | *=*) ;; |
| 159 | *) ac_optarg=yes ;; |
| 160 | esac |
| 161 | eval "enable_${ac_feature}='$ac_optarg'" ;; |
| 162 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 163 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 164 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 165 | | --exec | --exe | --ex) |
| 166 | ac_prev=exec_prefix ;; |
| 167 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 168 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 169 | | --exec=* | --exe=* | --ex=*) |
| 170 | exec_prefix="$ac_optarg" ;; |
| 171 | |
| 172 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 173 | # Obsolete; use --with-gas. |
| 174 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 175 | |
| 176 | -help | --help | --hel | --he) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 177 | # Omit some internal or obsolete options to make the list less imposing. |
| 178 | # 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] | 179 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 180 | Usage: configure [options] [host] |
| 181 | Options: [defaults in brackets after descriptions] |
| 182 | Configuration: |
| 183 | --cache-file=FILE cache test results in FILE |
| 184 | --help print this message |
| 185 | --no-create do not create output files |
| 186 | --quiet, --silent do not print \`checking...' messages |
| 187 | --version print the version of autoconf that created configure |
| 188 | Directory and file names: |
| 189 | --prefix=PREFIX install architecture-independent files in PREFIX |
| 190 | [$ac_default_prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 191 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 192 | [same as prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 193 | --bindir=DIR user executables in DIR [EPREFIX/bin] |
| 194 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] |
| 195 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] |
| 196 | --datadir=DIR read-only architecture-independent data in DIR |
| 197 | [PREFIX/share] |
| 198 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] |
| 199 | --sharedstatedir=DIR modifiable architecture-independent data in DIR |
| 200 | [PREFIX/com] |
| 201 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] |
| 202 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] |
| 203 | --includedir=DIR C header files in DIR [PREFIX/include] |
| 204 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] |
| 205 | --infodir=DIR info documentation in DIR [PREFIX/info] |
| 206 | --mandir=DIR man documentation in DIR [PREFIX/man] |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 207 | --srcdir=DIR find the sources in DIR [configure dir or ..] |
| 208 | --program-prefix=PREFIX prepend PREFIX to installed program names |
| 209 | --program-suffix=SUFFIX append SUFFIX to installed program names |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 210 | --program-transform-name=PROGRAM |
| 211 | run sed PROGRAM on installed program names |
| 212 | EOF |
| 213 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 214 | Host type: |
| 215 | --build=BUILD configure for building on BUILD [BUILD=HOST] |
| 216 | --host=HOST configure for HOST [guessed] |
| 217 | --target=TARGET configure for TARGET [TARGET=HOST] |
| 218 | Features and packages: |
| 219 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 220 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
| 221 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 222 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
| 223 | --x-includes=DIR X include files are in DIR |
| 224 | --x-libraries=DIR X library files are in DIR |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 225 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 226 | if test -n "$ac_help"; then |
| 227 | echo "--enable and --with options recognized:$ac_help" |
| 228 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 229 | exit 0 ;; |
| 230 | |
| 231 | -host | --host | --hos | --ho) |
| 232 | ac_prev=host ;; |
| 233 | -host=* | --host=* | --hos=* | --ho=*) |
| 234 | host="$ac_optarg" ;; |
| 235 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 236 | -includedir | --includedir | --includedi | --included | --include \ |
| 237 | | --includ | --inclu | --incl | --inc) |
| 238 | ac_prev=includedir ;; |
| 239 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 240 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
| 241 | includedir="$ac_optarg" ;; |
| 242 | |
| 243 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 244 | ac_prev=infodir ;; |
| 245 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
| 246 | infodir="$ac_optarg" ;; |
| 247 | |
| 248 | -libdir | --libdir | --libdi | --libd) |
| 249 | ac_prev=libdir ;; |
| 250 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
| 251 | libdir="$ac_optarg" ;; |
| 252 | |
| 253 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 254 | | --libexe | --libex | --libe) |
| 255 | ac_prev=libexecdir ;; |
| 256 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 257 | | --libexe=* | --libex=* | --libe=*) |
| 258 | libexecdir="$ac_optarg" ;; |
| 259 | |
| 260 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
| 261 | | --localstate | --localstat | --localsta | --localst \ |
| 262 | | --locals | --local | --loca | --loc | --lo) |
| 263 | ac_prev=localstatedir ;; |
| 264 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
| 265 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ |
| 266 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) |
| 267 | localstatedir="$ac_optarg" ;; |
| 268 | |
| 269 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 270 | ac_prev=mandir ;; |
| 271 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
| 272 | mandir="$ac_optarg" ;; |
| 273 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 274 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 275 | # Obsolete; use --without-fp. |
| 276 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 277 | |
| 278 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 279 | | --no-cr | --no-c) |
| 280 | no_create=yes ;; |
| 281 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 282 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 283 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 284 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 285 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 286 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 287 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 288 | | --oldin | --oldi | --old | --ol | --o) |
| 289 | ac_prev=oldincludedir ;; |
| 290 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 291 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 292 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
| 293 | oldincludedir="$ac_optarg" ;; |
| 294 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 295 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 296 | ac_prev=prefix ;; |
| 297 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
| 298 | prefix="$ac_optarg" ;; |
| 299 | |
| 300 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 301 | | --program-pre | --program-pr | --program-p) |
| 302 | ac_prev=program_prefix ;; |
| 303 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 304 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
| 305 | program_prefix="$ac_optarg" ;; |
| 306 | |
| 307 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 308 | | --program-suf | --program-su | --program-s) |
| 309 | ac_prev=program_suffix ;; |
| 310 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 311 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
| 312 | program_suffix="$ac_optarg" ;; |
| 313 | |
| 314 | -program-transform-name | --program-transform-name \ |
| 315 | | --program-transform-nam | --program-transform-na \ |
| 316 | | --program-transform-n | --program-transform- \ |
| 317 | | --program-transform | --program-transfor \ |
| 318 | | --program-transfo | --program-transf \ |
| 319 | | --program-trans | --program-tran \ |
| 320 | | --progr-tra | --program-tr | --program-t) |
| 321 | ac_prev=program_transform_name ;; |
| 322 | -program-transform-name=* | --program-transform-name=* \ |
| 323 | | --program-transform-nam=* | --program-transform-na=* \ |
| 324 | | --program-transform-n=* | --program-transform-=* \ |
| 325 | | --program-transform=* | --program-transfor=* \ |
| 326 | | --program-transfo=* | --program-transf=* \ |
| 327 | | --program-trans=* | --program-tran=* \ |
| 328 | | --progr-tra=* | --program-tr=* | --program-t=*) |
| 329 | program_transform_name="$ac_optarg" ;; |
| 330 | |
| 331 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 332 | | -silent | --silent | --silen | --sile | --sil) |
| 333 | silent=yes ;; |
| 334 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 335 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 336 | ac_prev=sbindir ;; |
| 337 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 338 | | --sbi=* | --sb=*) |
| 339 | sbindir="$ac_optarg" ;; |
| 340 | |
| 341 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 342 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 343 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 344 | | --sha | --sh) |
| 345 | ac_prev=sharedstatedir ;; |
| 346 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 347 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 348 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 349 | | --sha=* | --sh=*) |
| 350 | sharedstatedir="$ac_optarg" ;; |
| 351 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 352 | -site | --site | --sit) |
| 353 | ac_prev=site ;; |
| 354 | -site=* | --site=* | --sit=*) |
| 355 | site="$ac_optarg" ;; |
| 356 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 357 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 358 | ac_prev=srcdir ;; |
| 359 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
| 360 | srcdir="$ac_optarg" ;; |
| 361 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 362 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 363 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 364 | ac_prev=sysconfdir ;; |
| 365 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 366 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
| 367 | sysconfdir="$ac_optarg" ;; |
| 368 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 369 | -target | --target | --targe | --targ | --tar | --ta | --t) |
| 370 | ac_prev=target ;; |
| 371 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
| 372 | target="$ac_optarg" ;; |
| 373 | |
| 374 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 375 | verbose=yes ;; |
| 376 | |
| 377 | -version | --version | --versio | --versi | --vers) |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 378 | echo "configure generated by autoconf version 2.13" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 379 | exit 0 ;; |
| 380 | |
| 381 | -with-* | --with-*) |
| 382 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 383 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 384 | 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] | 385 | { 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] | 386 | fi |
| 387 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 388 | case "$ac_option" in |
| 389 | *=*) ;; |
| 390 | *) ac_optarg=yes ;; |
| 391 | esac |
| 392 | eval "with_${ac_package}='$ac_optarg'" ;; |
| 393 | |
| 394 | -without-* | --without-*) |
| 395 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 396 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 397 | 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] | 398 | { 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] | 399 | fi |
| 400 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 401 | eval "with_${ac_package}=no" ;; |
| 402 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 403 | --x) |
| 404 | # Obsolete; use --with-x. |
| 405 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 406 | |
| 407 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 408 | | --x-incl | --x-inc | --x-in | --x-i) |
| 409 | ac_prev=x_includes ;; |
| 410 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 411 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
| 412 | x_includes="$ac_optarg" ;; |
| 413 | |
| 414 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 415 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 416 | ac_prev=x_libraries ;; |
| 417 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 418 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
| 419 | x_libraries="$ac_optarg" ;; |
| 420 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 421 | -*) { 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] | 422 | ;; |
| 423 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 424 | *) |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 425 | 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] | 426 | echo "configure: warning: $ac_option: invalid host type" 1>&2 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 427 | fi |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 428 | if test "x$nonopt" != xNONE; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 429 | { 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] | 430 | fi |
| 431 | nonopt="$ac_option" |
| 432 | ;; |
| 433 | |
| 434 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 435 | done |
| 436 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 437 | if test -n "$ac_prev"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 438 | { 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] | 439 | fi |
| 440 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 441 | 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] | 442 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 443 | # File descriptor usage: |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 444 | # 0 standard input |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 445 | # 1 file creation |
| 446 | # 2 errors and warnings |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 447 | # 3 some systems may open it to /dev/tty |
| 448 | # 4 used on the Kubota Titan |
| 449 | # 6 checking for... messages and results |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 450 | # 5 compiler messages saved in config.log |
| 451 | if test "$silent" = yes; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 452 | exec 6>/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 453 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 454 | exec 6>&1 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 455 | fi |
| 456 | exec 5>./config.log |
| 457 | |
| 458 | echo "\ |
| 459 | This file contains any messages produced by compilers while |
| 460 | running configure, to aid debugging if configure makes a mistake. |
| 461 | " 1>&5 |
| 462 | |
| 463 | # Strip out --no-create and --no-recursion so they do not pile up. |
| 464 | # Also quote any args containing shell metacharacters. |
| 465 | ac_configure_args= |
| 466 | for ac_arg |
| 467 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 468 | case "$ac_arg" in |
| 469 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 470 | | --no-cr | --no-c) ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 471 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 472 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; |
| 473 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) |
| 474 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; |
| 475 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 476 | esac |
| 477 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 478 | |
| 479 | # NLS nuisances. |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 480 | # Only set these to C if already set. These must not be set unconditionally |
| 481 | # because not all systems understand e.g. LANG=C (notably SCO). |
| 482 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! |
| 483 | # Non-C LC_CTYPE values break the ctype check. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 484 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 485 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi |
| 486 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi |
| 487 | 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] | 488 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 489 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
| 490 | rm -rf conftest* confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 491 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. |
| 492 | echo > confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 493 | |
| 494 | # A filename unique to this package, relative to the directory that |
| 495 | # 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] | 496 | ac_unique_file=Include/object.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 497 | |
| 498 | # Find the source files, if location was not specified. |
| 499 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 500 | ac_srcdir_defaulted=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 501 | # Try the directory containing this script, then its parent. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 502 | ac_prog=$0 |
| 503 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` |
| 504 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
| 505 | srcdir=$ac_confdir |
| 506 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 507 | srcdir=.. |
| 508 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 509 | else |
| 510 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 511 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 512 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 513 | if test "$ac_srcdir_defaulted" = yes; then |
| 514 | { 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] | 515 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 516 | { 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] | 517 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 518 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 519 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` |
| 520 | |
| 521 | # Prefer explicitly selected file to automatically selected ones. |
| 522 | if test -z "$CONFIG_SITE"; then |
| 523 | if test "x$prefix" != xNONE; then |
| 524 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" |
| 525 | else |
| 526 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" |
| 527 | fi |
| 528 | fi |
| 529 | for ac_site_file in $CONFIG_SITE; do |
| 530 | if test -r "$ac_site_file"; then |
| 531 | echo "loading site script $ac_site_file" |
| 532 | . "$ac_site_file" |
| 533 | fi |
| 534 | done |
| 535 | |
| 536 | if test -r "$cache_file"; then |
| 537 | echo "loading cache $cache_file" |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 538 | . $cache_file |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 539 | else |
| 540 | echo "creating cache $cache_file" |
| 541 | > $cache_file |
| 542 | fi |
| 543 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 544 | ac_ext=c |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 545 | # 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] | 546 | ac_cpp='$CPP $CPPFLAGS' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 547 | 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] | 548 | 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] | 549 | cross_compiling=$ac_cv_prog_cc_cross |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 550 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 551 | ac_exeext= |
| 552 | ac_objext=o |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 553 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then |
| 554 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. |
| 555 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then |
| 556 | ac_n= ac_c=' |
| 557 | ' ac_t=' ' |
| 558 | else |
| 559 | ac_n=-n ac_c= ac_t= |
| 560 | fi |
| 561 | else |
| 562 | ac_n= ac_c='\c' ac_t= |
| 563 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 564 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 565 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 566 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 567 | |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 568 | # Set VERSION so we only need to edit in one place (i.e., here) |
| 569 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 570 | VERSION=2.0 |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 571 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 572 | # NEXTSTEP stuff |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 573 | 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] | 574 | |
| 575 | echo $ac_n "checking for --with-next-archs""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 576 | echo "configure:577: checking for --with-next-archs" >&5 |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 577 | # Check whether --with-next-archs or --without-next-archs was given. |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 578 | if test "${with_next_archs+set}" = set; then |
| 579 | withval="$with_next_archs" |
| 580 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 581 | if test -n "$withval"; then |
| 582 | ac_arch_flags=`/usr/lib/arch_tool -archify_list $withval` |
| 583 | # GCC does not currently support multi archs on the NeXT |
| 584 | with_gcc=no |
| 585 | fi |
| 586 | echo "$ac_t""$with_next_archs" 1>&6 |
| 587 | |
| 588 | else |
| 589 | echo "$ac_t""none: using `arch`" 1>&6 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 590 | fi |
| 591 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 592 | |
| 593 | if test -z "$MACHDEP" |
| 594 | then |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 595 | set X `hostinfo | egrep '(NeXT Mach|Kernel Release).*:' | \ |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 596 | sed -e 's/://' -e 's/\./_/'` && \ |
| 597 | ac_sys_system=next && ac_sys_release=$4 |
| 598 | |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 599 | MACHDEP="$ac_sys_system$ac_sys_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 600 | fi |
| 601 | fi |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 602 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 603 | # Check whether --with-next-framework or --without-next-framework was given. |
| 604 | if test "${with_next_framework+set}" = set; then |
| 605 | withval="$with_next_framework" |
| 606 | : |
| 607 | fi |
| 608 | |
| 609 | # Check whether --with-dyld or --without-dyld was given. |
| 610 | if test "${with_dyld+set}" = set; then |
| 611 | withval="$with_dyld" |
| 612 | : |
| 613 | fi |
| 614 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 615 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 616 | # Set name for machine-dependent library files |
| 617 | |
| 618 | echo $ac_n "checking MACHDEP""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 619 | echo "configure:620: checking MACHDEP" >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 620 | if test -z "$MACHDEP" |
| 621 | then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 622 | ac_sys_system=`uname -s` |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 623 | 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] | 624 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 625 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 626 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 627 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 628 | ac_md_system=`echo $ac_sys_system | |
| 629 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 630 | ac_md_release=`echo $ac_sys_release | |
| 631 | tr -d '/ ' | sed 's/\..*//'` |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 632 | MACHDEP="$ac_md_system$ac_md_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 633 | |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 634 | case $MACHDEP in |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 635 | '') MACHDEP="unknown";; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 636 | esac |
| 637 | fi |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 638 | |
| 639 | # |
| 640 | # SGI compilers allow the specification of the both the ABI and the |
| 641 | # ISA on the command line. Depending on the values of these switches, |
| 642 | # different and often incompatable code will be generated. |
| 643 | # |
| 644 | # The SGI_ABI variable can be used to modify the CC and LDFLAGS and |
| 645 | # thus supply support for various ABI/ISA combinations. The MACHDEP |
| 646 | # variable is also adjusted. |
| 647 | # |
| 648 | |
| 649 | if test ! -z "$SGI_ABI" |
| 650 | then |
| 651 | CC="cc $SGI_ABI" |
| 652 | LDFLAGS="$SGI_ABI $LDFLAGS" |
| 653 | MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'` |
| 654 | fi |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 655 | echo "$ac_t""$MACHDEP" 1>&6 |
| 656 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 657 | # |
| 658 | # CCC is the command that compiles C++ programs |
| 659 | # |
| 660 | # Not all make programs have this predefined. |
| 661 | # |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 662 | #AC_SUBST(SET_CCC) |
| 663 | #AC_MSG_CHECKING(CCC) |
| 664 | #if test -z "$CCC" |
| 665 | #then |
| 666 | # case $ac_sys_system in |
| 667 | # IRIX*) SET_CCC="CCC= CC ${SGI_ABI}";; |
| 668 | # Linux*) SET_CCC="CCC= g++";; |
| 669 | # *) SET_CCC="" |
| 670 | # esac |
| 671 | #else |
| 672 | # SET_CCC="CCC= ${CCC}" |
| 673 | #fi |
| 674 | #AC_MSG_RESULT($SET_CCC) |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 675 | |
| 676 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 677 | # checks for alternative programs |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 678 | echo $ac_n "checking for --without-gcc""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 679 | echo "configure:680: checking for --without-gcc" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 680 | # Check whether --with-gcc or --without-gcc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 681 | if test "${with_gcc+set}" = set; then |
| 682 | withval="$with_gcc" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 683 | |
| 684 | case $withval in |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 685 | no) CC=cc |
| 686 | without_gcc=yes;; |
| 687 | yes) CC=gcc |
| 688 | without_gcc=no;; |
| 689 | *) CC=$withval |
| 690 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 691 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 692 | else |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 693 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 694 | case $ac_sys_system in |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 695 | OSF1) CC=cc |
| 696 | without_gcc=;; |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 697 | BeOS*) |
| 698 | # Dunno if it's a good idea to get this over with all at once, or |
| 699 | # to handle it in with the other goodies. |
| 700 | MACHDEP=beos |
| 701 | |
| 702 | case $BE_HOST_CPU in |
| 703 | ppc) |
Guido van Rossum | 8137680 | 1999-04-06 15:50:51 +0000 | [diff] [blame] | 704 | CC="mwcc -I$PWD/BeOS -nodup" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 705 | without_gcc=yes |
Guido van Rossum | 6b9da45 | 1999-03-24 17:48:12 +0000 | [diff] [blame] | 706 | case `uname -r` in |
| 707 | 4.0*) OPT="-DUSE_DL_EXPORT -O7 -opt schedule604 -export pragma" ;; |
| 708 | *) OPT="-DUSE_DL_EXPORT -O2 -proc 604e -export pragma" ;; |
| 709 | esac |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 710 | CCSHARED=-UUSE_DL_EXPORT |
| 711 | LDFLAGS="$LDFLAGS -nodup" |
| 712 | |
| 713 | AR="$PWD/BeOS/ar-fake" |
| 714 | RANLIB=: |
| 715 | |
| 716 | cat >> confdefs.h <<\EOF |
| 717 | #define DL_EXPORT_HEADER "dl_export.h" |
| 718 | EOF |
| 719 | |
| 720 | ;; |
| 721 | x86) |
| 722 | CC="gcc -I$PWD/BeOS" |
| 723 | without_gcc=no |
Guido van Rossum | 32000e8 | 2000-05-22 21:31:50 +0000 | [diff] [blame] | 724 | OPT="-DUSE_DL_EXPORT -O" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 725 | CCSHARED=-UUSE_DL_EXPORT |
| 726 | |
| 727 | AR="$PWD/BeOS/ar-fake" |
| 728 | RANLIB=: |
| 729 | |
| 730 | cat >> confdefs.h <<\EOF |
| 731 | #define DL_EXPORT_HEADER "dl_export.h" |
| 732 | EOF |
| 733 | |
| 734 | ;; |
| 735 | *) |
| 736 | { echo "configure: error: Your BeOS system isn't PowerPC or x86... neat" 1>&2; exit 1; } |
| 737 | ;; |
| 738 | esac |
| 739 | ;; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 740 | Monterey*) |
| 741 | RANLIB=: |
| 742 | without_gcc=;; |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 743 | *) without_gcc=no;; |
| 744 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 745 | fi |
| 746 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 747 | echo "$ac_t""$without_gcc" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 748 | |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 749 | |
| 750 | |
| 751 | MAINOBJ=python.o |
| 752 | echo $ac_n "checking for --with-cxx=<compiler>""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 753 | echo "configure:754: checking for --with-cxx=<compiler>" >&5 |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 754 | # Check whether --with-cxx or --without-cxx was given. |
| 755 | if test "${with_cxx+set}" = set; then |
| 756 | withval="$with_cxx" |
| 757 | |
| 758 | case $withval in |
| 759 | no) CXX= |
| 760 | with_cxx=no;; |
| 761 | *) CXX=$withval |
| 762 | MAINOBJ=ccpython.o |
| 763 | with_cxx=$withval;; |
| 764 | esac |
| 765 | else |
| 766 | |
| 767 | with_cxx=no |
| 768 | |
| 769 | fi |
| 770 | |
| 771 | echo "$ac_t""$with_cxx" 1>&6 |
Guido van Rossum | e126233 | 2000-09-22 19:41:56 +0000 | [diff] [blame] | 772 | SET_CXX="CXX=$CXX" |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 773 | |
| 774 | #AC_MSG_CHECKING(CCC) |
| 775 | #if test -z "$CCC" |
| 776 | #then |
| 777 | # case $ac_sys_system in |
| 778 | # IRIX*) SET_CCC="CCC= CC ${SGI_ABI}";; |
| 779 | # Linux*) SET_CCC="CCC= g++";; |
| 780 | # *) SET_CCC="" |
| 781 | # esac |
| 782 | #else |
| 783 | # SET_CCC="CCC= ${CCC}" |
| 784 | #fi |
| 785 | #AC_MSG_RESULT($SET_CCC) |
| 786 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 787 | # If the user switches compilers, we can't believe the cache |
| 788 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 789 | then |
| 790 | { echo "configure: error: cached CC is different -- throw away $cache_file |
| 791 | (it is also a good idea to do 'make clean' before compiling)" 1>&2; exit 1; } |
| 792 | fi |
| 793 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 794 | # Extract the first word of "gcc", so it can be a program name with args. |
| 795 | set dummy gcc; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 796 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 797 | echo "configure:798: checking for $ac_word" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 798 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 799 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 800 | else |
| 801 | if test -n "$CC"; then |
| 802 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 803 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 804 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 805 | ac_dummy="$PATH" |
| 806 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 807 | test -z "$ac_dir" && ac_dir=. |
| 808 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 809 | ac_cv_prog_CC="gcc" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 810 | break |
| 811 | fi |
| 812 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 813 | IFS="$ac_save_ifs" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 814 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 815 | fi |
| 816 | CC="$ac_cv_prog_CC" |
| 817 | if test -n "$CC"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 818 | echo "$ac_t""$CC" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 819 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 820 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 821 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 822 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 823 | if test -z "$CC"; then |
| 824 | # Extract the first word of "cc", so it can be a program name with args. |
| 825 | set dummy cc; ac_word=$2 |
| 826 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 827 | echo "configure:828: checking for $ac_word" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 828 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 829 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 830 | else |
| 831 | if test -n "$CC"; then |
| 832 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 833 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 834 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 835 | ac_prog_rejected=no |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 836 | ac_dummy="$PATH" |
| 837 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 838 | test -z "$ac_dir" && ac_dir=. |
| 839 | if test -f $ac_dir/$ac_word; then |
| 840 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then |
| 841 | ac_prog_rejected=yes |
| 842 | continue |
| 843 | fi |
| 844 | ac_cv_prog_CC="cc" |
| 845 | break |
| 846 | fi |
| 847 | done |
| 848 | IFS="$ac_save_ifs" |
| 849 | if test $ac_prog_rejected = yes; then |
| 850 | # We found a bogon in the path, so make sure we never use it. |
| 851 | set dummy $ac_cv_prog_CC |
| 852 | shift |
| 853 | if test $# -gt 0; then |
| 854 | # We chose a different compiler from the bogus one. |
| 855 | # However, it has the same basename, so the bogon will be chosen |
| 856 | # first if we set CC to just the basename; use the full file name. |
| 857 | shift |
| 858 | set dummy "$ac_dir/$ac_word" "$@" |
| 859 | shift |
| 860 | ac_cv_prog_CC="$@" |
| 861 | fi |
| 862 | fi |
| 863 | fi |
| 864 | fi |
| 865 | CC="$ac_cv_prog_CC" |
| 866 | if test -n "$CC"; then |
| 867 | echo "$ac_t""$CC" 1>&6 |
| 868 | else |
| 869 | echo "$ac_t""no" 1>&6 |
| 870 | fi |
| 871 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 872 | if test -z "$CC"; then |
| 873 | case "`uname -s`" in |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 874 | *win32* | *WIN32*) |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 875 | # Extract the first word of "cl", so it can be a program name with args. |
| 876 | set dummy cl; ac_word=$2 |
| 877 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 878 | echo "configure:879: checking for $ac_word" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 879 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +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 |
| 885 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 886 | ac_dummy="$PATH" |
| 887 | for ac_dir in $ac_dummy; do |
| 888 | test -z "$ac_dir" && ac_dir=. |
| 889 | if test -f $ac_dir/$ac_word; then |
| 890 | ac_cv_prog_CC="cl" |
| 891 | break |
| 892 | fi |
| 893 | done |
| 894 | IFS="$ac_save_ifs" |
| 895 | fi |
| 896 | fi |
| 897 | CC="$ac_cv_prog_CC" |
| 898 | if test -n "$CC"; then |
| 899 | echo "$ac_t""$CC" 1>&6 |
| 900 | else |
| 901 | echo "$ac_t""no" 1>&6 |
| 902 | fi |
| 903 | ;; |
| 904 | esac |
| 905 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 906 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } |
| 907 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 908 | |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 909 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 |
| 910 | echo "configure:911: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 911 | |
| 912 | ac_ext=c |
| 913 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 914 | ac_cpp='$CPP $CPPFLAGS' |
| 915 | 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] | 916 | 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] | 917 | cross_compiling=$ac_cv_prog_cc_cross |
| 918 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 919 | cat > conftest.$ac_ext << EOF |
| 920 | |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 921 | #line 922 "configure" |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 922 | #include "confdefs.h" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 923 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 924 | main(){return(0);} |
| 925 | EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 926 | if { (eval echo configure:927: \"$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] | 927 | ac_cv_prog_cc_works=yes |
| 928 | # If we can't run a trivial program, we are probably using a cross compiler. |
| 929 | if (./conftest; exit) 2>/dev/null; then |
| 930 | ac_cv_prog_cc_cross=no |
| 931 | else |
| 932 | ac_cv_prog_cc_cross=yes |
| 933 | fi |
| 934 | else |
| 935 | echo "configure: failed program was:" >&5 |
| 936 | cat conftest.$ac_ext >&5 |
| 937 | ac_cv_prog_cc_works=no |
| 938 | fi |
| 939 | rm -fr conftest* |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 940 | ac_ext=c |
| 941 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 942 | ac_cpp='$CPP $CPPFLAGS' |
| 943 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 944 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 945 | cross_compiling=$ac_cv_prog_cc_cross |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 946 | |
| 947 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 |
| 948 | if test $ac_cv_prog_cc_works = no; then |
| 949 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } |
| 950 | fi |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 951 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 |
| 952 | echo "configure:953: 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] | 953 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
| 954 | cross_compiling=$ac_cv_prog_cc_cross |
| 955 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 956 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 957 | echo "configure:958: checking whether we are using GNU C" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 958 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 959 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 960 | else |
| 961 | cat > conftest.c <<EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 962 | #ifdef __GNUC__ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 963 | yes; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 964 | #endif |
| 965 | EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 966 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:967: \"$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] | 967 | ac_cv_prog_gcc=yes |
| 968 | else |
| 969 | ac_cv_prog_gcc=no |
| 970 | fi |
| 971 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 972 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 973 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 974 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 975 | if test $ac_cv_prog_gcc = yes; then |
| 976 | GCC=yes |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 977 | else |
| 978 | GCC= |
| 979 | fi |
| 980 | |
| 981 | ac_test_CFLAGS="${CFLAGS+set}" |
| 982 | ac_save_CFLAGS="$CFLAGS" |
| 983 | CFLAGS= |
| 984 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 985 | echo "configure:986: checking whether ${CC-cc} accepts -g" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 986 | 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] | 987 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 988 | else |
| 989 | echo 'void f(){}' > conftest.c |
| 990 | 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] | 991 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 992 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 993 | ac_cv_prog_cc_g=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 994 | fi |
| 995 | rm -f conftest* |
| 996 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 997 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 998 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 999 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1000 | if test "$ac_test_CFLAGS" = set; then |
| 1001 | CFLAGS="$ac_save_CFLAGS" |
| 1002 | elif test $ac_cv_prog_cc_g = yes; then |
| 1003 | if test "$GCC" = yes; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1004 | CFLAGS="-g -O2" |
| 1005 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1006 | CFLAGS="-g" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1007 | fi |
| 1008 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1009 | if test "$GCC" = yes; then |
| 1010 | CFLAGS="-O2" |
| 1011 | else |
| 1012 | CFLAGS= |
| 1013 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1014 | fi |
| 1015 | |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1016 | |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1017 | echo $ac_n "checking for --with-suffix""... $ac_c" 1>&6 |
| 1018 | echo "configure:1019: checking for --with-suffix" >&5 |
| 1019 | # Check whether --with-suffix or --without-suffix was given. |
| 1020 | if test "${with_suffix+set}" = set; then |
| 1021 | withval="$with_suffix" |
| 1022 | |
| 1023 | case $withval in |
| 1024 | no) EXE=;; |
| 1025 | yes) EXE=.exe;; |
| 1026 | *) EXE=$withval;; |
| 1027 | esac |
| 1028 | fi |
| 1029 | |
| 1030 | echo "$ac_t""$EXE" 1>&6 |
| 1031 | |
Guido van Rossum | dd997f7 | 1998-10-07 19:58:26 +0000 | [diff] [blame] | 1032 | case $MACHDEP in |
| 1033 | bsdos*) |
| 1034 | case $CC in |
| 1035 | gcc) CC="$CC -D_HAVE_BSDI";; |
| 1036 | esac;; |
| 1037 | esac |
| 1038 | |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 1039 | case $ac_sys_system in |
| 1040 | hp*|HP*) |
| 1041 | case $CC in |
Guido van Rossum | cd5ff9f | 2000-09-22 16:15:54 +0000 | [diff] [blame] | 1042 | cc|*/cc) CC="$CC -Ae";; |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 1043 | esac;; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1044 | BeOS*) |
Guido van Rossum | cd5ff9f | 2000-09-22 16:15:54 +0000 | [diff] [blame] | 1045 | case $CC in |
| 1046 | cc) CC=cc;; |
| 1047 | esac;; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 1048 | Monterey*) |
| 1049 | case $CC in |
| 1050 | cc) CC="$CC -Wl,-Bexport";; |
| 1051 | esac;; |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 1052 | esac |
| 1053 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1054 | # LDLIBRARY is the name of the library to link against (as opposed to the |
| 1055 | # name of the library into which to insert object files). On systems |
| 1056 | # without shared libraries, LDLIBRARY is the same as LIBRARY (defined in |
| 1057 | # the Makefiles). |
| 1058 | |
| 1059 | |
| 1060 | LDLIBRARY='' |
| 1061 | |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1062 | # LINKCC is the command that links the python executable -- default is $(CC). |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1063 | # This is altered for AIX and BeOS in order to build the export list before |
| 1064 | # linking. |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1065 | |
| 1066 | echo $ac_n "checking LINKCC""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1067 | echo "configure:1068: checking LINKCC" >&5 |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 1068 | if test -z "$LINKCC" -a ! -z "$CXX" |
| 1069 | then |
| 1070 | LINKCC="$CXX" |
| 1071 | fi |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1072 | if test -z "$LINKCC" |
| 1073 | then |
| 1074 | case $ac_sys_system in |
| 1075 | AIX*) |
Guido van Rossum | 45140f9 | 1997-08-29 18:44:06 +0000 | [diff] [blame] | 1076 | LINKCC="\$(srcdir)/makexp_aix python.exp \"\" \$(LIBRARY); \$(PURIFY) \$(CC)";; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1077 | BeOS*) |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 1078 | LINKCC="\$(srcdir)/../BeOS/linkcc \$(LIBRARY) \$(PURIFY) \$(CC) \$(OPT)" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1079 | LDLIBRARY='libpython$(VERSION).so';; |
Guido van Rossum | 3c4bb80 | 1997-12-18 23:55:32 +0000 | [diff] [blame] | 1080 | dgux*) |
| 1081 | LINKCC="LD_RUN_PATH=$libdir \$(PURIFY) \$(CC)";; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 1082 | Monterey64*) |
| 1083 | LINKCC="\$(PURIFY) \$(CC) -L/usr/lib/ia64l64";; |
Guido van Rossum | 25f9303 | 1997-08-18 16:00:04 +0000 | [diff] [blame] | 1084 | *) LINKCC="\$(PURIFY) \$(CC)";; |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1085 | esac |
| 1086 | fi |
| 1087 | echo "$ac_t""$LINKCC" 1>&6 |
| 1088 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1089 | echo $ac_n "checking LDLIBRARY""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1090 | echo "configure:1091: checking LDLIBRARY" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1091 | |
| 1092 | # NeXT framework builds require that the 'ar' library be converted into |
| 1093 | # a bundle using libtool. |
| 1094 | if test "$with_next_framework" |
| 1095 | then |
| 1096 | LDLIBRARY='libpython$(VERSION).dylib' |
| 1097 | fi |
| 1098 | |
| 1099 | # DG/UX requires some fancy ld contortions to produce a .so from an .a |
| 1100 | if test "$MACHDEP" = "dguxR4" |
| 1101 | then |
| 1102 | LDLIBRARY='libpython$(VERSION).so' |
| 1103 | OPT="$OPT -pic" |
| 1104 | fi |
| 1105 | echo "$ac_t""$LDLIBRARY" 1>&6 |
| 1106 | |
| 1107 | # If LDLIBRARY is different from LIBRARY, emit a rule to build it. |
| 1108 | if test -z "$LDLIBRARY" |
| 1109 | then |
| 1110 | LDLIBRARY='libpython$(VERSION).a' |
| 1111 | MAKE_LDLIBRARY="true" |
| 1112 | else |
| 1113 | MAKE_LDLIBRARY='$(MAKE) $(LDLIBRARY)' |
| 1114 | fi |
| 1115 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1116 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 1117 | set dummy ranlib; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1118 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1119 | echo "configure:1120: checking for $ac_word" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1120 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1121 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1122 | else |
| 1123 | if test -n "$RANLIB"; then |
| 1124 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 1125 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1126 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 1127 | ac_dummy="$PATH" |
| 1128 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1129 | test -z "$ac_dir" && ac_dir=. |
| 1130 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1131 | ac_cv_prog_RANLIB="ranlib" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1132 | break |
| 1133 | fi |
| 1134 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1135 | IFS="$ac_save_ifs" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1136 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1137 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1138 | fi |
| 1139 | RANLIB="$ac_cv_prog_RANLIB" |
| 1140 | if test -n "$RANLIB"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1141 | echo "$ac_t""$RANLIB" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1142 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1143 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1144 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1145 | |
| 1146 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1147 | for ac_prog in ar aal |
| 1148 | do |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1149 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 1150 | set dummy $ac_prog; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1151 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1152 | echo "configure:1153: checking for $ac_word" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1153 | if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1154 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1155 | else |
| 1156 | if test -n "$AR"; then |
| 1157 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 1158 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1159 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 1160 | ac_dummy="$PATH" |
| 1161 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1162 | test -z "$ac_dir" && ac_dir=. |
| 1163 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1164 | ac_cv_prog_AR="$ac_prog" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1165 | break |
| 1166 | fi |
| 1167 | done |
| 1168 | IFS="$ac_save_ifs" |
| 1169 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1170 | fi |
| 1171 | AR="$ac_cv_prog_AR" |
| 1172 | if test -n "$AR"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1173 | echo "$ac_t""$AR" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1174 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1175 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1176 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1177 | |
| 1178 | test -n "$AR" && break |
| 1179 | done |
| 1180 | test -n "$AR" || AR="ar" |
| 1181 | |
| 1182 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1183 | |
| 1184 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1185 | # Install just never works :-( |
| 1186 | if test -z "$INSTALL" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1187 | then |
| 1188 | INSTALL=cp |
| 1189 | INSTALL_PROGRAM=cp |
| 1190 | INSTALL_DATA=cp |
| 1191 | else |
| 1192 | INSTALL_PROGRAM="$INSTALL" |
| 1193 | INSTALL_DATA="$INSTALL -m 644" |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1194 | fi |
| 1195 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1196 | # Not every filesystem supports hard links |
| 1197 | |
| 1198 | if test -z "$LN" ; then |
| 1199 | case $ac_sys_system in |
| 1200 | BeOS*) LN="ln -s";; |
| 1201 | *) LN=ln;; |
| 1202 | esac |
| 1203 | fi |
| 1204 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1205 | # Optimizer/debugger flags passed between Makefiles |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1206 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1207 | if test -z "$OPT" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1208 | then |
Guido van Rossum | edca74a | 1997-07-18 23:29:40 +0000 | [diff] [blame] | 1209 | case $GCC in |
| 1210 | yes) |
| 1211 | case $ac_cv_prog_cc_g in |
| 1212 | yes) OPT="-g -O2";; |
| 1213 | *) OPT="-O2";; |
| 1214 | esac |
| 1215 | ;; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1216 | *) OPT="-O";; |
| 1217 | esac |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1218 | fi |
| 1219 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 1220 | # The current (beta) Monterey compiler dies with optimizations |
| 1221 | case $ac_sys_system in |
| 1222 | Monterey*) OPT="";; |
| 1223 | esac |
| 1224 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1225 | if test "$ac_arch_flags" |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 1226 | then |
| 1227 | OPT="$OPT $ac_arch_flags" |
| 1228 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1229 | # checks for UNIX variants that set C preprocessor variables |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1230 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1231 | echo "configure:1232: checking how to run the C preprocessor" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1232 | # On Suns, sometimes $CPP names a directory. |
| 1233 | if test -n "$CPP" && test -d "$CPP"; then |
| 1234 | CPP= |
| 1235 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1236 | if test -z "$CPP"; then |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1237 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1238 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1239 | else |
| 1240 | # This must be in double quotes, not single quotes, because CPP may get |
| 1241 | # substituted into the Makefile and "${CC-cc}" will confuse make. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1242 | CPP="${CC-cc} -E" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1243 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 1244 | # not just through cpp. |
| 1245 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 1246 | #line 1247 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1247 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1248 | #include <assert.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1249 | Syntax Error |
| 1250 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1251 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 1252 | { (eval echo configure:1253: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1253 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 1254 | if test -z "$ac_err"; then |
| 1255 | : |
| 1256 | else |
| 1257 | echo "$ac_err" >&5 |
| 1258 | echo "configure: failed program was:" >&5 |
| 1259 | cat conftest.$ac_ext >&5 |
| 1260 | rm -rf conftest* |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1261 | CPP="${CC-cc} -E -traditional-cpp" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1262 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 1263 | #line 1264 "configure" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1264 | #include "confdefs.h" |
| 1265 | #include <assert.h> |
| 1266 | Syntax Error |
| 1267 | EOF |
| 1268 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 1269 | { (eval echo configure:1270: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1270 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1271 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1272 | : |
| 1273 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1274 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1275 | echo "configure: failed program was:" >&5 |
| 1276 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1277 | rm -rf conftest* |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1278 | CPP="${CC-cc} -nologo -E" |
| 1279 | cat > conftest.$ac_ext <<EOF |
| 1280 | #line 1281 "configure" |
| 1281 | #include "confdefs.h" |
| 1282 | #include <assert.h> |
| 1283 | Syntax Error |
| 1284 | EOF |
| 1285 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 1286 | { (eval echo configure:1287: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 1287 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 1288 | if test -z "$ac_err"; then |
| 1289 | : |
| 1290 | else |
| 1291 | echo "$ac_err" >&5 |
| 1292 | echo "configure: failed program was:" >&5 |
| 1293 | cat conftest.$ac_ext >&5 |
| 1294 | rm -rf conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1295 | CPP=/lib/cpp |
| 1296 | fi |
| 1297 | rm -f conftest* |
| 1298 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1299 | rm -f conftest* |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1300 | fi |
| 1301 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1302 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1303 | fi |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 1304 | CPP="$ac_cv_prog_CPP" |
| 1305 | else |
| 1306 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1307 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1308 | echo "$ac_t""$CPP" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1309 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1310 | echo $ac_n "checking for AIX""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1311 | echo "configure:1312: checking for AIX" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1312 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1313 | #line 1314 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1314 | #include "confdefs.h" |
| 1315 | #ifdef _AIX |
| 1316 | yes |
| 1317 | #endif |
| 1318 | |
| 1319 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1320 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1321 | egrep "yes" >/dev/null 2>&1; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1322 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1323 | echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1324 | #define _ALL_SOURCE 1 |
| 1325 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1326 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1327 | else |
| 1328 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1329 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1330 | fi |
| 1331 | rm -f conftest* |
| 1332 | |
| 1333 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1334 | ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1335 | echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1336 | echo "configure:1337: checking for minix/config.h" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1337 | 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] | 1338 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1339 | else |
| 1340 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1341 | #line 1342 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1342 | #include "confdefs.h" |
| 1343 | #include <minix/config.h> |
| 1344 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1345 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1346 | { (eval echo configure:1347: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1347 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1348 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1349 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1350 | eval "ac_cv_header_$ac_safe=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1351 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1352 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1353 | echo "configure: failed program was:" >&5 |
| 1354 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1355 | rm -rf conftest* |
| 1356 | eval "ac_cv_header_$ac_safe=no" |
| 1357 | fi |
| 1358 | rm -f conftest* |
| 1359 | fi |
| 1360 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1361 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1362 | MINIX=yes |
| 1363 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1364 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1365 | MINIX= |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1366 | fi |
| 1367 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1368 | if test "$MINIX" = yes; then |
| 1369 | cat >> confdefs.h <<\EOF |
| 1370 | #define _POSIX_SOURCE 1 |
| 1371 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1372 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1373 | cat >> confdefs.h <<\EOF |
| 1374 | #define _POSIX_1_SOURCE 2 |
| 1375 | EOF |
| 1376 | |
| 1377 | cat >> confdefs.h <<\EOF |
| 1378 | #define _MINIX 1 |
| 1379 | EOF |
| 1380 | |
| 1381 | fi |
| 1382 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1383 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1384 | echo $ac_n "checking whether $CC accepts -OPT:Olimit=0""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1385 | echo "configure:1386: checking whether $CC accepts -OPT:Olimit=0" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1386 | 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] | 1387 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1388 | else |
| 1389 | ac_save_cc="$CC" |
| 1390 | CC="$CC -OPT:Olimit=0" |
| 1391 | if test "$cross_compiling" = yes; then |
| 1392 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1393 | else |
| 1394 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1395 | #line 1396 "configure" |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1396 | #include "confdefs.h" |
| 1397 | int main() { return 0; } |
| 1398 | EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1399 | if { (eval echo configure:1400: \"$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] | 1400 | then |
| 1401 | ac_cv_opt_olimit_ok=yes |
| 1402 | else |
| 1403 | echo "configure: failed program was:" >&5 |
| 1404 | cat conftest.$ac_ext >&5 |
| 1405 | rm -fr conftest* |
| 1406 | ac_cv_opt_olimit_ok=no |
| 1407 | fi |
| 1408 | rm -fr conftest* |
| 1409 | fi |
| 1410 | |
| 1411 | CC="$ac_save_cc" |
| 1412 | fi |
| 1413 | |
| 1414 | echo "$ac_t""$ac_cv_opt_olimit_ok" 1>&6 |
Guido van Rossum | 2efa34b | 1997-10-23 17:43:11 +0000 | [diff] [blame] | 1415 | if test $ac_cv_opt_olimit_ok = yes; then |
Guido van Rossum | 304dd2d | 1997-10-20 23:10:56 +0000 | [diff] [blame] | 1416 | OPT="$OPT -OPT:Olimit=0" |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1417 | else |
| 1418 | echo $ac_n "checking whether $CC accepts -Olimit 1500""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1419 | echo "configure:1420: checking whether $CC accepts -Olimit 1500" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1420 | if eval "test \"`echo '$''{'ac_cv_olimit_ok'+set}'`\" = set"; then |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1421 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1422 | else |
| 1423 | ac_save_cc="$CC" |
| 1424 | CC="$CC -Olimit 1500" |
| 1425 | if test "$cross_compiling" = yes; then |
| 1426 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1427 | else |
| 1428 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1429 | #line 1430 "configure" |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1430 | #include "confdefs.h" |
| 1431 | int main() { return 0; } |
| 1432 | EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1433 | if { (eval echo configure:1434: \"$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] | 1434 | then |
| 1435 | ac_cv_olimit_ok=yes |
| 1436 | else |
| 1437 | echo "configure: failed program was:" >&5 |
| 1438 | cat conftest.$ac_ext >&5 |
| 1439 | rm -fr conftest* |
| 1440 | ac_cv_olimit_ok=no |
Guido van Rossum | 201afe5 | 1997-05-14 21:14:44 +0000 | [diff] [blame] | 1441 | fi |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1442 | rm -fr conftest* |
| 1443 | fi |
| 1444 | |
| 1445 | CC="$ac_save_cc" |
| 1446 | fi |
| 1447 | |
| 1448 | echo "$ac_t""$ac_cv_olimit_ok" 1>&6 |
| 1449 | if test $ac_cv_olimit_ok = yes; then |
| 1450 | OPT="$OPT -Olimit 1500" |
| 1451 | fi |
| 1452 | fi |
| 1453 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1454 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1455 | # checks for header files |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1456 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1457 | echo "configure:1458: checking for ANSI C header files" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1458 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1459 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1460 | else |
| 1461 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1462 | #line 1463 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1463 | #include "confdefs.h" |
| 1464 | #include <stdlib.h> |
| 1465 | #include <stdarg.h> |
| 1466 | #include <string.h> |
| 1467 | #include <float.h> |
| 1468 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1469 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1470 | { (eval echo configure:1471: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1471 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1472 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1473 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1474 | ac_cv_header_stdc=yes |
| 1475 | else |
| 1476 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1477 | echo "configure: failed program was:" >&5 |
| 1478 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1479 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1480 | ac_cv_header_stdc=no |
| 1481 | fi |
| 1482 | rm -f conftest* |
| 1483 | |
| 1484 | if test $ac_cv_header_stdc = yes; then |
| 1485 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 1486 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1487 | #line 1488 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1488 | #include "confdefs.h" |
| 1489 | #include <string.h> |
| 1490 | EOF |
| 1491 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1492 | egrep "memchr" >/dev/null 2>&1; then |
| 1493 | : |
| 1494 | else |
| 1495 | rm -rf conftest* |
| 1496 | ac_cv_header_stdc=no |
| 1497 | fi |
| 1498 | rm -f conftest* |
| 1499 | |
| 1500 | fi |
| 1501 | |
| 1502 | if test $ac_cv_header_stdc = yes; then |
| 1503 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 1504 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1505 | #line 1506 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1506 | #include "confdefs.h" |
| 1507 | #include <stdlib.h> |
| 1508 | EOF |
| 1509 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1510 | egrep "free" >/dev/null 2>&1; then |
| 1511 | : |
| 1512 | else |
| 1513 | rm -rf conftest* |
| 1514 | ac_cv_header_stdc=no |
| 1515 | fi |
| 1516 | rm -f conftest* |
| 1517 | |
| 1518 | fi |
| 1519 | |
| 1520 | if test $ac_cv_header_stdc = yes; then |
| 1521 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 1522 | if test "$cross_compiling" = yes; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1523 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1524 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1525 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1526 | #line 1527 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1527 | #include "confdefs.h" |
| 1528 | #include <ctype.h> |
| 1529 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 1530 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1531 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1532 | int main () { int i; for (i = 0; i < 256; i++) |
| 1533 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); |
| 1534 | exit (0); } |
| 1535 | |
| 1536 | EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1537 | if { (eval echo configure:1538: \"$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] | 1538 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1539 | : |
| 1540 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1541 | echo "configure: failed program was:" >&5 |
| 1542 | cat conftest.$ac_ext >&5 |
| 1543 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1544 | ac_cv_header_stdc=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1545 | fi |
| 1546 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1547 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1548 | |
| 1549 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1550 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1551 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1552 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1553 | if test $ac_cv_header_stdc = yes; then |
| 1554 | cat >> confdefs.h <<\EOF |
| 1555 | #define STDC_HEADERS 1 |
| 1556 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1557 | |
| 1558 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1559 | |
Andrew M. Kuchling | 5821b77 | 2000-08-25 01:14:08 +0000 | [diff] [blame] | 1560 | for ac_hdr in dlfcn.h fcntl.h limits.h locale.h ncurses.h poll.h pthread.h \ |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 1561 | signal.h stdarg.h stddef.h stdlib.h thread.h unistd.h utime.h \ |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 1562 | 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] | 1563 | 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] | 1564 | sys/un.h sys/utsname.h sys/wait.h pty.h libutil.h \ |
| 1565 | ndbm.h db1/ndbm.h gdbm/ndbm.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1566 | do |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1567 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1568 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1569 | echo "configure:1570: checking for $ac_hdr" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1570 | 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] | 1571 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1572 | else |
| 1573 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1574 | #line 1575 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1575 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1576 | #include <$ac_hdr> |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1577 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1578 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1579 | { (eval echo configure:1580: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1580 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1581 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1582 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1583 | eval "ac_cv_header_$ac_safe=yes" |
| 1584 | else |
| 1585 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1586 | echo "configure: failed program was:" >&5 |
| 1587 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1588 | rm -rf conftest* |
| 1589 | eval "ac_cv_header_$ac_safe=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1590 | fi |
| 1591 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1592 | fi |
| 1593 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1594 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1595 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1596 | cat >> confdefs.h <<EOF |
| 1597 | #define $ac_tr_hdr 1 |
| 1598 | EOF |
| 1599 | |
| 1600 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1601 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1602 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1603 | done |
| 1604 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1605 | ac_header_dirent=no |
| 1606 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h |
| 1607 | do |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1608 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1609 | echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1610 | echo "configure:1611: checking for $ac_hdr that defines DIR" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1611 | 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] | 1612 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1613 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1614 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1615 | #line 1616 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1616 | #include "confdefs.h" |
| 1617 | #include <sys/types.h> |
| 1618 | #include <$ac_hdr> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1619 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1620 | DIR *dirp = 0; |
| 1621 | ; return 0; } |
| 1622 | EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1623 | if { (eval echo configure:1624: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1624 | rm -rf conftest* |
| 1625 | eval "ac_cv_header_dirent_$ac_safe=yes" |
| 1626 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1627 | echo "configure: failed program was:" >&5 |
| 1628 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1629 | rm -rf conftest* |
| 1630 | eval "ac_cv_header_dirent_$ac_safe=no" |
| 1631 | fi |
| 1632 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1633 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1634 | 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] | 1635 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1636 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1637 | cat >> confdefs.h <<EOF |
| 1638 | #define $ac_tr_hdr 1 |
| 1639 | EOF |
| 1640 | ac_header_dirent=$ac_hdr; break |
| 1641 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1642 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1643 | fi |
| 1644 | done |
| 1645 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 1646 | if test $ac_header_dirent = dirent.h; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1647 | echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1648 | echo "configure:1649: checking for opendir in -ldir" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1649 | ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1650 | 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] | 1651 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1652 | else |
| 1653 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1654 | LIBS="-ldir $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1655 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1656 | #line 1657 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1657 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1658 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1659 | /* We use char because int might match the return type of a gcc2 |
| 1660 | builtin and then its argument prototype would still apply. */ |
| 1661 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1662 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1663 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1664 | opendir() |
| 1665 | ; return 0; } |
| 1666 | EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1667 | if { (eval echo configure:1668: \"$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] | 1668 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1669 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1670 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1671 | echo "configure: failed program was:" >&5 |
| 1672 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1673 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1674 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1675 | fi |
| 1676 | rm -f conftest* |
| 1677 | LIBS="$ac_save_LIBS" |
| 1678 | |
| 1679 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1680 | 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] | 1681 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1682 | LIBS="$LIBS -ldir" |
| 1683 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1684 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1685 | fi |
| 1686 | |
| 1687 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1688 | echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1689 | echo "configure:1690: checking for opendir in -lx" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1690 | ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1691 | 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] | 1692 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1693 | else |
| 1694 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1695 | LIBS="-lx $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1696 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1697 | #line 1698 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1698 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1699 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 1700 | /* We use char because int might match the return type of a gcc2 |
| 1701 | builtin and then its argument prototype would still apply. */ |
| 1702 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1703 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1704 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1705 | opendir() |
| 1706 | ; return 0; } |
| 1707 | EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1708 | if { (eval echo configure:1709: \"$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] | 1709 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1710 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1711 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1712 | echo "configure: failed program was:" >&5 |
| 1713 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1714 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1715 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1716 | fi |
| 1717 | rm -f conftest* |
| 1718 | LIBS="$ac_save_LIBS" |
| 1719 | |
| 1720 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1721 | 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] | 1722 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1723 | LIBS="$LIBS -lx" |
| 1724 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1725 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1726 | fi |
| 1727 | |
| 1728 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1729 | |
| 1730 | |
| 1731 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1732 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1733 | echo $ac_n "checking for clock_t in time.h""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1734 | echo "configure:1735: checking for clock_t in time.h" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1735 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1736 | #line 1737 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1737 | #include "confdefs.h" |
| 1738 | #include <time.h> |
| 1739 | EOF |
| 1740 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1741 | egrep "clock_t" >/dev/null 2>&1; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1742 | rm -rf conftest* |
| 1743 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1744 | else |
| 1745 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1746 | cat >> confdefs.h <<\EOF |
| 1747 | #define clock_t long |
| 1748 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1749 | |
| 1750 | fi |
| 1751 | rm -f conftest* |
| 1752 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1753 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1754 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1755 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 1756 | cat >> confdefs.h <<\EOF |
| 1757 | #if defined(SCO_DS) |
| 1758 | #undef _OFF_T |
| 1759 | #endif |
| 1760 | EOF |
| 1761 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1762 | # Type availability checks |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1763 | echo $ac_n "checking for mode_t""... $ac_c" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1764 | echo "configure:1765: checking for mode_t" >&5 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1765 | 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] | 1766 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1767 | else |
| 1768 | cat > conftest.$ac_ext <<EOF |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1769 | #line 1770 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1770 | #include "confdefs.h" |
| 1771 | #include <sys/types.h> |
| 1772 | #if STDC_HEADERS |
| 1773 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1774 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1775 | #endif |
| 1776 | EOF |
| 1777 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1778 | 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] | 1779 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1780 | ac_cv_type_mode_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1781 | else |
| 1782 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1783 | ac_cv_type_mode_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1784 | fi |
| 1785 | rm -f conftest* |
| 1786 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1787 | fi |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1788 | echo "$ac_t""$ac_cv_type_mode_t" 1>&6 |
| 1789 | if test $ac_cv_type_mode_t = no; then |
| 1790 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1791 | #define mode_t int |
| 1792 | EOF |
| 1793 | |
| 1794 | fi |
| 1795 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1796 | echo $ac_n "checking for off_t""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1797 | echo "configure:1798: checking for off_t" >&5 |
| 1798 | 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] | 1799 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1800 | else |
| 1801 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1802 | #line 1803 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1803 | #include "confdefs.h" |
| 1804 | #include <sys/types.h> |
| 1805 | #if STDC_HEADERS |
| 1806 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1807 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1808 | #endif |
| 1809 | EOF |
| 1810 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1811 | 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] | 1812 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1813 | ac_cv_type_off_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1814 | else |
| 1815 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1816 | ac_cv_type_off_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1817 | fi |
| 1818 | rm -f conftest* |
| 1819 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1820 | fi |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1821 | echo "$ac_t""$ac_cv_type_off_t" 1>&6 |
| 1822 | if test $ac_cv_type_off_t = no; then |
| 1823 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1824 | #define off_t long |
| 1825 | EOF |
| 1826 | |
| 1827 | fi |
| 1828 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1829 | echo $ac_n "checking for pid_t""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1830 | echo "configure:1831: checking for pid_t" >&5 |
| 1831 | 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] | 1832 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1833 | else |
| 1834 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1835 | #line 1836 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1836 | #include "confdefs.h" |
| 1837 | #include <sys/types.h> |
| 1838 | #if STDC_HEADERS |
| 1839 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1840 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1841 | #endif |
| 1842 | EOF |
| 1843 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1844 | 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] | 1845 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1846 | ac_cv_type_pid_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1847 | else |
| 1848 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1849 | ac_cv_type_pid_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1850 | fi |
| 1851 | rm -f conftest* |
| 1852 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1853 | fi |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1854 | echo "$ac_t""$ac_cv_type_pid_t" 1>&6 |
| 1855 | if test $ac_cv_type_pid_t = no; then |
| 1856 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1857 | #define pid_t int |
| 1858 | EOF |
| 1859 | |
| 1860 | fi |
| 1861 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1862 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1863 | echo "configure:1864: checking return type of signal handlers" >&5 |
| 1864 | if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1865 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1866 | else |
| 1867 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1868 | #line 1869 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1869 | #include "confdefs.h" |
| 1870 | #include <sys/types.h> |
| 1871 | #include <signal.h> |
| 1872 | #ifdef signal |
| 1873 | #undef signal |
| 1874 | #endif |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1875 | #ifdef __cplusplus |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1876 | extern "C" void (*signal (int, void (*)(int)))(int); |
| 1877 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1878 | void (*signal ()) (); |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1879 | #endif |
| 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 | int i; |
| 1883 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1884 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1885 | if { (eval echo configure:1886: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1886 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1887 | ac_cv_type_signal=void |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +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 | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1891 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1892 | ac_cv_type_signal=int |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1893 | fi |
| 1894 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1895 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1896 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1897 | echo "$ac_t""$ac_cv_type_signal" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1898 | cat >> confdefs.h <<EOF |
| 1899 | #define RETSIGTYPE $ac_cv_type_signal |
| 1900 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1901 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1902 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1903 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1904 | echo "configure:1905: checking for size_t" >&5 |
| 1905 | 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] | 1906 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1907 | else |
| 1908 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1909 | #line 1910 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1910 | #include "confdefs.h" |
| 1911 | #include <sys/types.h> |
| 1912 | #if STDC_HEADERS |
| 1913 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1914 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1915 | #endif |
| 1916 | EOF |
| 1917 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1918 | 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] | 1919 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1920 | ac_cv_type_size_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1921 | else |
| 1922 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1923 | ac_cv_type_size_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1924 | fi |
| 1925 | rm -f conftest* |
| 1926 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1927 | fi |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1928 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 |
| 1929 | if test $ac_cv_type_size_t = no; then |
| 1930 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1931 | #define size_t unsigned |
| 1932 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1933 | |
| 1934 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1935 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1936 | echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1937 | echo "configure:1938: checking for uid_t in sys/types.h" >&5 |
| 1938 | 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] | 1939 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1940 | else |
| 1941 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1942 | #line 1943 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1943 | #include "confdefs.h" |
| 1944 | #include <sys/types.h> |
| 1945 | EOF |
| 1946 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1947 | egrep "uid_t" >/dev/null 2>&1; then |
| 1948 | rm -rf conftest* |
| 1949 | ac_cv_type_uid_t=yes |
| 1950 | else |
| 1951 | rm -rf conftest* |
| 1952 | ac_cv_type_uid_t=no |
| 1953 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1954 | rm -f conftest* |
| 1955 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1956 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1957 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1958 | echo "$ac_t""$ac_cv_type_uid_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1959 | if test $ac_cv_type_uid_t = no; then |
| 1960 | cat >> confdefs.h <<\EOF |
| 1961 | #define uid_t int |
| 1962 | EOF |
| 1963 | |
| 1964 | cat >> confdefs.h <<\EOF |
| 1965 | #define gid_t int |
| 1966 | EOF |
| 1967 | |
| 1968 | fi |
| 1969 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1970 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 1971 | # Sizes of various common basic types |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1972 | echo $ac_n "checking size of int""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1973 | echo "configure:1974: checking size of int" >&5 |
| 1974 | if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1975 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1976 | else |
| 1977 | if test "$cross_compiling" = yes; then |
| 1978 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1979 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1980 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1981 | #line 1982 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1982 | #include "confdefs.h" |
| 1983 | #include <stdio.h> |
| 1984 | main() |
| 1985 | { |
| 1986 | FILE *f=fopen("conftestval", "w"); |
| 1987 | if (!f) exit(1); |
| 1988 | fprintf(f, "%d\n", sizeof(int)); |
| 1989 | exit(0); |
| 1990 | } |
| 1991 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 1992 | if { (eval echo configure:1993: \"$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] | 1993 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1994 | ac_cv_sizeof_int=`cat conftestval` |
| 1995 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1996 | echo "configure: failed program was:" >&5 |
| 1997 | cat conftest.$ac_ext >&5 |
| 1998 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 1999 | ac_cv_sizeof_int=0 |
| 2000 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2001 | rm -fr conftest* |
| 2002 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2003 | |
| 2004 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2005 | echo "$ac_t""$ac_cv_sizeof_int" 1>&6 |
| 2006 | cat >> confdefs.h <<EOF |
| 2007 | #define SIZEOF_INT $ac_cv_sizeof_int |
| 2008 | EOF |
| 2009 | |
| 2010 | |
| 2011 | echo $ac_n "checking size of long""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2012 | echo "configure:2013: checking size of long" >&5 |
| 2013 | if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2014 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2015 | else |
| 2016 | if test "$cross_compiling" = yes; then |
| 2017 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2018 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2019 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2020 | #line 2021 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2021 | #include "confdefs.h" |
| 2022 | #include <stdio.h> |
| 2023 | main() |
| 2024 | { |
| 2025 | FILE *f=fopen("conftestval", "w"); |
| 2026 | if (!f) exit(1); |
| 2027 | fprintf(f, "%d\n", sizeof(long)); |
| 2028 | exit(0); |
| 2029 | } |
| 2030 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2031 | if { (eval echo configure:2032: \"$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] | 2032 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2033 | ac_cv_sizeof_long=`cat conftestval` |
| 2034 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2035 | echo "configure: failed program was:" >&5 |
| 2036 | cat conftest.$ac_ext >&5 |
| 2037 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2038 | ac_cv_sizeof_long=0 |
| 2039 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2040 | rm -fr conftest* |
| 2041 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2042 | |
| 2043 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2044 | echo "$ac_t""$ac_cv_sizeof_long" 1>&6 |
| 2045 | cat >> confdefs.h <<EOF |
| 2046 | #define SIZEOF_LONG $ac_cv_sizeof_long |
| 2047 | EOF |
| 2048 | |
| 2049 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2050 | echo $ac_n "checking size of void *""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2051 | echo "configure:2052: checking size of void *" >&5 |
| 2052 | 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] | 2053 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2054 | else |
| 2055 | if test "$cross_compiling" = yes; then |
| 2056 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2057 | else |
| 2058 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2059 | #line 2060 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2060 | #include "confdefs.h" |
| 2061 | #include <stdio.h> |
| 2062 | main() |
| 2063 | { |
| 2064 | FILE *f=fopen("conftestval", "w"); |
| 2065 | if (!f) exit(1); |
| 2066 | fprintf(f, "%d\n", sizeof(void *)); |
| 2067 | exit(0); |
| 2068 | } |
| 2069 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2070 | if { (eval echo configure:2071: \"$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] | 2071 | then |
| 2072 | ac_cv_sizeof_void_p=`cat conftestval` |
| 2073 | else |
| 2074 | echo "configure: failed program was:" >&5 |
| 2075 | cat conftest.$ac_ext >&5 |
| 2076 | rm -fr conftest* |
| 2077 | ac_cv_sizeof_void_p=0 |
| 2078 | fi |
| 2079 | rm -fr conftest* |
| 2080 | fi |
| 2081 | |
| 2082 | fi |
| 2083 | echo "$ac_t""$ac_cv_sizeof_void_p" 1>&6 |
| 2084 | cat >> confdefs.h <<EOF |
| 2085 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
| 2086 | EOF |
| 2087 | |
| 2088 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2089 | echo $ac_n "checking size of char""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2090 | echo "configure:2091: checking size of char" >&5 |
| 2091 | if eval "test \"`echo '$''{'ac_cv_sizeof_char'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2092 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2093 | else |
| 2094 | if test "$cross_compiling" = yes; then |
| 2095 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2096 | else |
| 2097 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2098 | #line 2099 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2099 | #include "confdefs.h" |
| 2100 | #include <stdio.h> |
| 2101 | main() |
| 2102 | { |
| 2103 | FILE *f=fopen("conftestval", "w"); |
| 2104 | if (!f) exit(1); |
| 2105 | fprintf(f, "%d\n", sizeof(char)); |
| 2106 | exit(0); |
| 2107 | } |
| 2108 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2109 | if { (eval echo configure:2110: \"$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] | 2110 | then |
| 2111 | ac_cv_sizeof_char=`cat conftestval` |
| 2112 | else |
| 2113 | echo "configure: failed program was:" >&5 |
| 2114 | cat conftest.$ac_ext >&5 |
| 2115 | rm -fr conftest* |
| 2116 | ac_cv_sizeof_char=0 |
| 2117 | fi |
| 2118 | rm -fr conftest* |
| 2119 | fi |
| 2120 | |
| 2121 | fi |
| 2122 | echo "$ac_t""$ac_cv_sizeof_char" 1>&6 |
| 2123 | cat >> confdefs.h <<EOF |
| 2124 | #define SIZEOF_CHAR $ac_cv_sizeof_char |
| 2125 | EOF |
| 2126 | |
| 2127 | |
| 2128 | echo $ac_n "checking size of short""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2129 | echo "configure:2130: checking size of short" >&5 |
| 2130 | if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2131 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2132 | else |
| 2133 | if test "$cross_compiling" = yes; then |
| 2134 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2135 | else |
| 2136 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2137 | #line 2138 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2138 | #include "confdefs.h" |
| 2139 | #include <stdio.h> |
| 2140 | main() |
| 2141 | { |
| 2142 | FILE *f=fopen("conftestval", "w"); |
| 2143 | if (!f) exit(1); |
| 2144 | fprintf(f, "%d\n", sizeof(short)); |
| 2145 | exit(0); |
| 2146 | } |
| 2147 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2148 | if { (eval echo configure:2149: \"$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] | 2149 | then |
| 2150 | ac_cv_sizeof_short=`cat conftestval` |
| 2151 | else |
| 2152 | echo "configure: failed program was:" >&5 |
| 2153 | cat conftest.$ac_ext >&5 |
| 2154 | rm -fr conftest* |
| 2155 | ac_cv_sizeof_short=0 |
| 2156 | fi |
| 2157 | rm -fr conftest* |
| 2158 | fi |
| 2159 | |
| 2160 | fi |
| 2161 | echo "$ac_t""$ac_cv_sizeof_short" 1>&6 |
| 2162 | cat >> confdefs.h <<EOF |
| 2163 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
| 2164 | EOF |
| 2165 | |
| 2166 | |
| 2167 | echo $ac_n "checking size of float""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2168 | echo "configure:2169: checking size of float" >&5 |
| 2169 | if eval "test \"`echo '$''{'ac_cv_sizeof_float'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2170 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2171 | else |
| 2172 | if test "$cross_compiling" = yes; then |
| 2173 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2174 | else |
| 2175 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2176 | #line 2177 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2177 | #include "confdefs.h" |
| 2178 | #include <stdio.h> |
| 2179 | main() |
| 2180 | { |
| 2181 | FILE *f=fopen("conftestval", "w"); |
| 2182 | if (!f) exit(1); |
| 2183 | fprintf(f, "%d\n", sizeof(float)); |
| 2184 | exit(0); |
| 2185 | } |
| 2186 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2187 | if { (eval echo configure:2188: \"$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] | 2188 | then |
| 2189 | ac_cv_sizeof_float=`cat conftestval` |
| 2190 | else |
| 2191 | echo "configure: failed program was:" >&5 |
| 2192 | cat conftest.$ac_ext >&5 |
| 2193 | rm -fr conftest* |
| 2194 | ac_cv_sizeof_float=0 |
| 2195 | fi |
| 2196 | rm -fr conftest* |
| 2197 | fi |
| 2198 | |
| 2199 | fi |
| 2200 | echo "$ac_t""$ac_cv_sizeof_float" 1>&6 |
| 2201 | cat >> confdefs.h <<EOF |
| 2202 | #define SIZEOF_FLOAT $ac_cv_sizeof_float |
| 2203 | EOF |
| 2204 | |
| 2205 | |
| 2206 | echo $ac_n "checking size of double""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2207 | echo "configure:2208: checking size of double" >&5 |
| 2208 | if eval "test \"`echo '$''{'ac_cv_sizeof_double'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2209 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2210 | else |
| 2211 | if test "$cross_compiling" = yes; then |
| 2212 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2213 | else |
| 2214 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2215 | #line 2216 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2216 | #include "confdefs.h" |
| 2217 | #include <stdio.h> |
| 2218 | main() |
| 2219 | { |
| 2220 | FILE *f=fopen("conftestval", "w"); |
| 2221 | if (!f) exit(1); |
| 2222 | fprintf(f, "%d\n", sizeof(double)); |
| 2223 | exit(0); |
| 2224 | } |
| 2225 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2226 | if { (eval echo configure:2227: \"$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] | 2227 | then |
| 2228 | ac_cv_sizeof_double=`cat conftestval` |
| 2229 | else |
| 2230 | echo "configure: failed program was:" >&5 |
| 2231 | cat conftest.$ac_ext >&5 |
| 2232 | rm -fr conftest* |
| 2233 | ac_cv_sizeof_double=0 |
| 2234 | fi |
| 2235 | rm -fr conftest* |
| 2236 | fi |
| 2237 | |
| 2238 | fi |
| 2239 | echo "$ac_t""$ac_cv_sizeof_double" 1>&6 |
| 2240 | cat >> confdefs.h <<EOF |
| 2241 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
| 2242 | EOF |
| 2243 | |
| 2244 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2245 | echo $ac_n "checking size of fpos_t""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2246 | echo "configure:2247: checking size of fpos_t" >&5 |
| 2247 | 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] | 2248 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2249 | else |
| 2250 | if test "$cross_compiling" = yes; then |
| 2251 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2252 | else |
| 2253 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2254 | #line 2255 "configure" |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2255 | #include "confdefs.h" |
| 2256 | #include <stdio.h> |
| 2257 | main() |
| 2258 | { |
| 2259 | FILE *f=fopen("conftestval", "w"); |
| 2260 | if (!f) exit(1); |
| 2261 | fprintf(f, "%d\n", sizeof(fpos_t)); |
| 2262 | exit(0); |
| 2263 | } |
| 2264 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2265 | if { (eval echo configure:2266: \"$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] | 2266 | then |
| 2267 | ac_cv_sizeof_fpos_t=`cat conftestval` |
| 2268 | else |
| 2269 | echo "configure: failed program was:" >&5 |
| 2270 | cat conftest.$ac_ext >&5 |
| 2271 | rm -fr conftest* |
| 2272 | ac_cv_sizeof_fpos_t=0 |
| 2273 | fi |
| 2274 | rm -fr conftest* |
| 2275 | fi |
| 2276 | |
| 2277 | fi |
| 2278 | echo "$ac_t""$ac_cv_sizeof_fpos_t" 1>&6 |
| 2279 | cat >> confdefs.h <<EOF |
| 2280 | #define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t |
| 2281 | EOF |
| 2282 | |
| 2283 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2284 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2285 | echo $ac_n "checking for long long support""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2286 | echo "configure:2287: checking for long long support" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2287 | have_long_long=no |
| 2288 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2289 | #line 2290 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2290 | #include "confdefs.h" |
| 2291 | |
| 2292 | int main() { |
| 2293 | long long x; x = (long long)0; |
| 2294 | ; return 0; } |
| 2295 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2296 | if { (eval echo configure:2297: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2297 | rm -rf conftest* |
| 2298 | cat >> confdefs.h <<\EOF |
| 2299 | #define HAVE_LONG_LONG 1 |
| 2300 | EOF |
| 2301 | have_long_long=yes |
| 2302 | else |
| 2303 | echo "configure: failed program was:" >&5 |
| 2304 | cat conftest.$ac_ext >&5 |
| 2305 | fi |
| 2306 | rm -f conftest* |
| 2307 | echo "$ac_t""$have_long_long" 1>&6 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2308 | if test "$have_long_long" = yes ; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2309 | echo $ac_n "checking size of long long""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2310 | echo "configure:2311: checking size of long long" >&5 |
| 2311 | 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] | 2312 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2313 | else |
| 2314 | if test "$cross_compiling" = yes; then |
| 2315 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2316 | else |
| 2317 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2318 | #line 2319 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2319 | #include "confdefs.h" |
| 2320 | #include <stdio.h> |
| 2321 | main() |
| 2322 | { |
| 2323 | FILE *f=fopen("conftestval", "w"); |
| 2324 | if (!f) exit(1); |
| 2325 | fprintf(f, "%d\n", sizeof(long long)); |
| 2326 | exit(0); |
| 2327 | } |
| 2328 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2329 | if { (eval echo configure:2330: \"$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] | 2330 | then |
| 2331 | ac_cv_sizeof_long_long=`cat conftestval` |
| 2332 | else |
| 2333 | echo "configure: failed program was:" >&5 |
| 2334 | cat conftest.$ac_ext >&5 |
| 2335 | rm -fr conftest* |
| 2336 | ac_cv_sizeof_long_long=0 |
| 2337 | fi |
| 2338 | rm -fr conftest* |
| 2339 | fi |
| 2340 | |
| 2341 | fi |
| 2342 | echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6 |
| 2343 | cat >> confdefs.h <<EOF |
| 2344 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
| 2345 | EOF |
| 2346 | |
| 2347 | |
| 2348 | fi |
| 2349 | |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2350 | echo $ac_n "checking for uintptr_t support""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2351 | echo "configure:2352: checking for uintptr_t support" >&5 |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2352 | have_uintptr_t=no |
| 2353 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2354 | #line 2355 "configure" |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2355 | #include "confdefs.h" |
| 2356 | |
| 2357 | int main() { |
| 2358 | uintptr_t x; x = (uintptr_t)0; |
| 2359 | ; return 0; } |
| 2360 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2361 | if { (eval echo configure:2362: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2362 | rm -rf conftest* |
| 2363 | cat >> confdefs.h <<\EOF |
| 2364 | #define HAVE_UINTPTR_T 1 |
| 2365 | EOF |
| 2366 | have_uintptr_t=yes |
| 2367 | else |
| 2368 | echo "configure: failed program was:" >&5 |
| 2369 | cat conftest.$ac_ext >&5 |
| 2370 | fi |
| 2371 | rm -f conftest* |
| 2372 | echo "$ac_t""$have_uintptr_t" 1>&6 |
| 2373 | if test "$have_uintptr_t" = yes ; then |
| 2374 | echo $ac_n "checking size of uintptr_t""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2375 | echo "configure:2376: checking size of uintptr_t" >&5 |
| 2376 | if eval "test \"`echo '$''{'ac_cv_sizeof_uintptr_t'+set}'`\" = set"; then |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2377 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2378 | else |
| 2379 | if test "$cross_compiling" = yes; then |
| 2380 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2381 | else |
| 2382 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2383 | #line 2384 "configure" |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2384 | #include "confdefs.h" |
| 2385 | #include <stdio.h> |
| 2386 | main() |
| 2387 | { |
| 2388 | FILE *f=fopen("conftestval", "w"); |
| 2389 | if (!f) exit(1); |
| 2390 | fprintf(f, "%d\n", sizeof(uintptr_t)); |
| 2391 | exit(0); |
| 2392 | } |
| 2393 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2394 | if { (eval echo configure:2395: \"$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] | 2395 | then |
| 2396 | ac_cv_sizeof_uintptr_t=`cat conftestval` |
| 2397 | else |
| 2398 | echo "configure: failed program was:" >&5 |
| 2399 | cat conftest.$ac_ext >&5 |
| 2400 | rm -fr conftest* |
| 2401 | ac_cv_sizeof_uintptr_t=0 |
| 2402 | fi |
| 2403 | rm -fr conftest* |
| 2404 | fi |
| 2405 | |
| 2406 | fi |
| 2407 | echo "$ac_t""$ac_cv_sizeof_uintptr_t" 1>&6 |
| 2408 | cat >> confdefs.h <<EOF |
| 2409 | #define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t |
| 2410 | EOF |
| 2411 | |
| 2412 | |
| 2413 | fi |
| 2414 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2415 | # Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>. |
| 2416 | echo $ac_n "checking size of off_t""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2417 | echo "configure:2418: checking size of off_t" >&5 |
| 2418 | 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] | 2419 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2420 | else |
| 2421 | if test "$cross_compiling" = yes; then |
| 2422 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2423 | else |
| 2424 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2425 | #line 2426 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2426 | #include "confdefs.h" |
| 2427 | #include <stdio.h> |
| 2428 | #include <sys/types.h> |
| 2429 | main() |
| 2430 | { |
| 2431 | FILE *f=fopen("conftestval", "w"); |
| 2432 | if (!f) exit(1); |
| 2433 | fprintf(f, "%d\n", sizeof(off_t)); |
| 2434 | exit(0); |
| 2435 | } |
| 2436 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2437 | if { (eval echo configure:2438: \"$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] | 2438 | then |
| 2439 | ac_cv_sizeof_off_t=`cat conftestval` |
| 2440 | else |
| 2441 | echo "configure: failed program was:" >&5 |
| 2442 | cat conftest.$ac_ext >&5 |
| 2443 | rm -fr conftest* |
| 2444 | ac_cv_sizeof_off_t=0 |
| 2445 | fi |
| 2446 | rm -fr conftest* |
| 2447 | fi |
| 2448 | |
| 2449 | |
| 2450 | fi |
| 2451 | |
| 2452 | echo "$ac_t""$ac_cv_sizeof_off_t" 1>&6 |
| 2453 | cat >> confdefs.h <<EOF |
| 2454 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
| 2455 | EOF |
| 2456 | |
| 2457 | |
| 2458 | echo $ac_n "checking whether to enable large file support""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2459 | echo "configure:2460: checking whether to enable large file support" >&5 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2460 | if test "$have_long_long" = yes -a \ |
| 2461 | "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \ |
| 2462 | "$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] | 2463 | cat >> confdefs.h <<\EOF |
| 2464 | #define HAVE_LARGEFILE_SUPPORT 1 |
| 2465 | EOF |
| 2466 | |
| 2467 | echo "$ac_t""yes" 1>&6 |
| 2468 | else |
| 2469 | echo "$ac_t""no" 1>&6 |
| 2470 | fi |
| 2471 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2472 | # AC_CHECK_SIZEOF() doesn't include <time.h>. |
| 2473 | echo $ac_n "checking size of time_t""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2474 | echo "configure:2475: checking size of time_t" >&5 |
| 2475 | 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] | 2476 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2477 | else |
| 2478 | if test "$cross_compiling" = yes; then |
| 2479 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2480 | else |
| 2481 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2482 | #line 2483 "configure" |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2483 | #include "confdefs.h" |
| 2484 | #include <stdio.h> |
| 2485 | #include <time.h> |
| 2486 | main() |
| 2487 | { |
| 2488 | FILE *f=fopen("conftestval", "w"); |
| 2489 | if (!f) exit(1); |
| 2490 | fprintf(f, "%d\n", sizeof(time_t)); |
| 2491 | exit(0); |
| 2492 | } |
| 2493 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2494 | if { (eval echo configure:2495: \"$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] | 2495 | then |
| 2496 | ac_cv_sizeof_time_t=`cat conftestval` |
| 2497 | else |
| 2498 | echo "configure: failed program was:" >&5 |
| 2499 | cat conftest.$ac_ext >&5 |
| 2500 | rm -fr conftest* |
| 2501 | ac_cv_sizeof_time_t=0 |
| 2502 | fi |
| 2503 | rm -fr conftest* |
| 2504 | fi |
| 2505 | |
| 2506 | |
| 2507 | fi |
| 2508 | |
| 2509 | echo "$ac_t""$ac_cv_sizeof_time_t" 1>&6 |
| 2510 | cat >> confdefs.h <<EOF |
| 2511 | #define SIZEOF_TIME_T $ac_cv_sizeof_time_t |
| 2512 | EOF |
| 2513 | |
| 2514 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2515 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2516 | # if have pthread_t then define SIZEOF_PTHREAD_T |
| 2517 | echo $ac_n "checking for pthread_t""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2518 | echo "configure:2519: checking for pthread_t" >&5 |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2519 | have_pthread_t=no |
| 2520 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2521 | #line 2522 "configure" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2522 | #include "confdefs.h" |
| 2523 | #include <pthread.h> |
| 2524 | int main() { |
Guido van Rossum | 1258049 | 2000-09-24 16:47:19 +0000 | [diff] [blame] | 2525 | pthread_t x; x = *(pthread_t*)0; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2526 | ; return 0; } |
| 2527 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2528 | if { (eval echo configure:2529: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2529 | rm -rf conftest* |
| 2530 | have_pthread_t=yes |
| 2531 | else |
| 2532 | echo "configure: failed program was:" >&5 |
| 2533 | cat conftest.$ac_ext >&5 |
| 2534 | fi |
| 2535 | rm -f conftest* |
| 2536 | echo "$ac_t""$have_pthread_t" 1>&6 |
| 2537 | if test "$have_pthread_t" = yes ; then |
| 2538 | # AC_CHECK_SIZEOF() doesn't include <pthread.h>. |
| 2539 | echo $ac_n "checking size of pthread_t""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2540 | echo "configure:2541: checking size of pthread_t" >&5 |
| 2541 | if eval "test \"`echo '$''{'ac_cv_sizeof_pthread_t'+set}'`\" = set"; then |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2542 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2543 | else |
| 2544 | if test "$cross_compiling" = yes; then |
| 2545 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2546 | else |
| 2547 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2548 | #line 2549 "configure" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2549 | #include "confdefs.h" |
| 2550 | #include <stdio.h> |
| 2551 | #include <pthread.h> |
| 2552 | main() |
| 2553 | { |
| 2554 | FILE *f=fopen("conftestval", "w"); |
| 2555 | if (!f) exit(1); |
| 2556 | fprintf(f, "%d\n", sizeof(pthread_t)); |
| 2557 | exit(0); |
| 2558 | } |
| 2559 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2560 | if { (eval echo configure:2561: \"$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] | 2561 | then |
| 2562 | ac_cv_sizeof_pthread_t=`cat conftestval` |
| 2563 | else |
| 2564 | echo "configure: failed program was:" >&5 |
| 2565 | cat conftest.$ac_ext >&5 |
| 2566 | rm -fr conftest* |
| 2567 | ac_cv_sizeof_pthread_t=0 |
| 2568 | fi |
| 2569 | rm -fr conftest* |
| 2570 | fi |
| 2571 | |
| 2572 | |
| 2573 | fi |
| 2574 | |
| 2575 | echo "$ac_t""$ac_cv_sizeof_pthread_t" 1>&6 |
| 2576 | cat >> confdefs.h <<EOF |
| 2577 | #define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t |
| 2578 | EOF |
| 2579 | |
| 2580 | fi |
| 2581 | |
| 2582 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2583 | # Minor variations in building a framework between NextStep versions 4 and 5 |
| 2584 | |
| 2585 | case $ac_sys_system/$ac_sys_release in |
| 2586 | next/4*) |
| 2587 | ns_undef_sym='__environ' |
| 2588 | LIBTOOL_CRUFT="-U $ns_undef_sym" ;; |
| 2589 | next/5*) |
| 2590 | ns_undef_sym='_environ' |
| 2591 | LIBTOOL_CRUFT="-lcc_dynamic -U $ns_undef_sym" ;; |
| 2592 | esac |
| 2593 | |
| 2594 | echo $ac_n "checking for --with-next-framework""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2595 | echo "configure:2596: checking for --with-next-framework" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2596 | if test "$with_next_framework" |
| 2597 | then |
| 2598 | OPT="$OPT -fno-common" |
| 2599 | # -U __environ is needed since bundles don't have access |
| 2600 | # to crt0 when built but will always be linked against it |
| 2601 | LDFLAGS="$LDFLAGS -Wl,-U,$ns_undef_sym" |
| 2602 | cat >> confdefs.h <<\EOF |
| 2603 | #define WITH_NEXT_FRAMEWORK 1 |
| 2604 | EOF |
| 2605 | |
| 2606 | echo "$ac_t""yes" 1>&6 |
| 2607 | else |
| 2608 | echo "$ac_t""no" 1>&6 |
| 2609 | fi |
| 2610 | |
| 2611 | echo $ac_n "checking for --with-dyld""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2612 | echo "configure:2613: checking for --with-dyld" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2613 | if test "$with_next_framework" -o "$with_dyld" |
| 2614 | then |
| 2615 | if test "$with_dyld" |
| 2616 | then |
| 2617 | echo "$ac_t""yes" 1>&6 |
| 2618 | else |
| 2619 | echo "$ac_t""required for framework build" 1>&6 |
| 2620 | fi |
| 2621 | cat >> confdefs.h <<\EOF |
| 2622 | #define WITH_DYLD 1 |
| 2623 | EOF |
| 2624 | |
| 2625 | ns_dyld='set' |
| 2626 | else |
| 2627 | echo "$ac_t""no" 1>&6 |
| 2628 | fi |
| 2629 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2630 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2631 | |
| 2632 | |
| 2633 | |
| 2634 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2635 | # SO is the extension of shared libraries `(including the dot!) |
| 2636 | # -- usually .so, .sl on HP-UX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2637 | echo $ac_n "checking SO""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2638 | echo "configure:2639: checking SO" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2639 | if test -z "$SO" |
| 2640 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2641 | case $ac_sys_system in |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2642 | hp*|HP*) SO=.sl;; |
| 2643 | *) SO=.so;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2644 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2645 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2646 | echo "$ac_t""$SO" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2647 | # LDSHARED is the ld *command* used to create shared library |
| 2648 | # -- "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] | 2649 | # (Shared libraries in this instance are shared modules to be loaded into |
| 2650 | # Python, as opposed to building Python itself as a shared library.) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2651 | echo $ac_n "checking LDSHARED""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2652 | echo "configure:2653: checking LDSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2653 | if test -z "$LDSHARED" |
| 2654 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2655 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 45140f9 | 1997-08-29 18:44:06 +0000 | [diff] [blame] | 2656 | AIX*) LDSHARED="\$(srcdir)/ld_so_aix \$(CC)";; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2657 | BeOS*) LDSHARED="\$(srcdir)/../BeOS/linkmodule -L.. -lpython\$(VERSION)";; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2658 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 2659 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2660 | SunOS/4*) LDSHARED="ld";; |
Greg Ward | 57c9a663 | 2000-05-26 12:22:54 +0000 | [diff] [blame] | 2661 | SunOS/5*) |
| 2662 | if test "$GCC" = "yes" |
| 2663 | then LDSHARED='$(CC) -G' |
| 2664 | else LDSHARED="ld -G"; |
| 2665 | fi ;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2666 | hp*|HP*) LDSHARED="ld -b";; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2667 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
| 2668 | DYNIX/ptx*) LDSHARED="ld -G";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2669 | next/*) |
| 2670 | if test "$ns_dyld" |
| 2671 | then LDSHARED='$(CC) $(LDFLAGS) -bundle -prebind' |
| 2672 | else LDSHARED='$(CC) $(CFLAGS) -nostdlib -r'; |
| 2673 | fi |
| 2674 | if test "$with_next_framework" ; then |
| 2675 | LDSHARED="$LDSHARED \$(LDLIBRARY)" |
| 2676 | fi ;; |
Guido van Rossum | 81652ab | 1996-07-21 02:53:27 +0000 | [diff] [blame] | 2677 | Linux*) LDSHARED="gcc -shared";; |
Guido van Rossum | 3c4bb80 | 1997-12-18 23:55:32 +0000 | [diff] [blame] | 2678 | dgux*) LDSHARED="ld -G";; |
Guido van Rossum | 458e7fa | 1999-09-17 15:40:40 +0000 | [diff] [blame] | 2679 | BSD/OS*/4*) LDSHARED="gcc -shared";; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 2680 | OpenBSD*) LDSHARED="ld -Bshareable";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2681 | NetBSD*) |
| 2682 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 2683 | then |
| 2684 | LDSHARED="cc -shared" |
| 2685 | else |
| 2686 | LDSHARED="ld -Bshareable" |
| 2687 | fi;; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 2688 | FreeBSD*) |
Jeremy Hylton | 4bcc7c5 | 2000-08-31 17:45:35 +0000 | [diff] [blame] | 2689 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 2690 | then |
| 2691 | LDSHARED="cc -shared ${LDFLAGS}" |
| 2692 | else |
| 2693 | LDSHARED="ld -Bshareable ${LDFLAGS}" |
| 2694 | fi;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2695 | SCO_SV*) LDSHARED="cc -G -KPIC -Ki486 -belf -Wl,-Bexport";; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2696 | Monterey*) LDSHARED="cc -G -dy -Bdynamic -Bexport -L/usr/lib/ia64l64";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2697 | *) LDSHARED="ld";; |
| 2698 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2699 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2700 | echo "$ac_t""$LDSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2701 | # 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] | 2702 | # library (module) -- this is only needed for a few systems |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2703 | echo $ac_n "checking CCSHARED""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2704 | echo "configure:2705: checking CCSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2705 | if test -z "$CCSHARED" |
| 2706 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2707 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 2708 | hp*|HP*) if test "$GCC" = yes; |
| 2709 | then CCSHARED="-fpic"; |
| 2710 | else CCSHARED="+z"; |
| 2711 | fi;; |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2712 | Linux*) CCSHARED="-fpic";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2713 | BSD/OS*/4*) CCSHARED="-fpic";; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 2714 | OpenBSD*) CCSHARED="-fpic";; |
| 2715 | FreeBSD*|NetBSD*) CCSHARED="-fPIC";; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2716 | SCO_SV*) CCSHARED="-KPIC -dy -Bdynamic";; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 2717 | Monterey*) CCSHARED="-G";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2718 | IRIX*/6*) case $CC in |
| 2719 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 2720 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2721 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2722 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2723 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2724 | echo "$ac_t""$CCSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2725 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2726 | # the python executable -- this is only needed for a few systems |
| 2727 | echo $ac_n "checking LINKFORSHARED""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2728 | echo "configure:2729: checking LINKFORSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2729 | if test -z "$LINKFORSHARED" |
| 2730 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2731 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 69f6580 | 1998-03-03 21:47:00 +0000 | [diff] [blame] | 2732 | AIX*) LINKFORSHARED='-Wl,-bE:python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2733 | hp*|HP*) |
Guido van Rossum | 304dd2d | 1997-10-20 23:10:56 +0000 | [diff] [blame] | 2734 | LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 2735 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 2d9feed | 1997-11-24 17:36:21 +0000 | [diff] [blame] | 2736 | Linux*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 2737 | # -u libsys_s pulls in all symbols in libsys |
| 2738 | next/2*|next/3*) LINKFORSHARED="-u libsys_s";; |
| 2739 | # -u __dummy makes the linker aware of the objc runtime |
| 2740 | # in System.framework; otherwise, __objcInit (referenced in |
| 2741 | # crt1.o) gets erroneously defined as common, which breaks dynamic |
| 2742 | # loading of any modules which reference it in System.framework |
| 2743 | next/4*|next/5*) LINKFORSHARED="-u __dummy -framework System" ;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2744 | SCO_SV*) LINKFORSHARED="-Bdynamic -dy -Wl,-Bexport";; |
Fred Drake | 02706f5 | 2000-09-25 15:08:46 +0000 | [diff] [blame] | 2745 | ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 2746 | FreeBSD*|NetBSD*) |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 2747 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 2748 | then |
| 2749 | LINKFORSHARED="-Wl,--export-dynamic" |
| 2750 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2751 | SunOS/5*) case $CC in |
| 2752 | *gcc*) |
Guido van Rossum | ff48418 | 2000-02-03 13:50:24 +0000 | [diff] [blame] | 2753 | if $CC -Xlinker -V 2>&1 | grep BFD >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 2754 | then |
| 2755 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 2756 | fi;; |
| 2757 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2758 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2759 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2760 | echo "$ac_t""$LINKFORSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2761 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2762 | # checks for libraries |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2763 | echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2764 | echo "configure:2765: checking for dlopen in -ldl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2765 | ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2766 | 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] | 2767 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2768 | else |
| 2769 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2770 | LIBS="-ldl $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2771 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2772 | #line 2773 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2773 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2774 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2775 | /* We use char because int might match the return type of a gcc2 |
| 2776 | builtin and then its argument prototype would still apply. */ |
| 2777 | char dlopen(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2778 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2779 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2780 | dlopen() |
| 2781 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2782 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2783 | if { (eval echo configure:2784: \"$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] | 2784 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2785 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2786 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2787 | echo "configure: failed program was:" >&5 |
| 2788 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2789 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2790 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2791 | fi |
| 2792 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2793 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2794 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2795 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2796 | 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] | 2797 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2798 | ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 2799 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2800 | cat >> confdefs.h <<EOF |
| 2801 | #define $ac_tr_lib 1 |
| 2802 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2803 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2804 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2805 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2806 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2807 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2808 | fi |
| 2809 | # Dynamic linking for SunOS/Solaris and SYSV |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2810 | echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2811 | echo "configure:2812: checking for shl_load in -ldld" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2812 | ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2813 | 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] | 2814 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2815 | else |
| 2816 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2817 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2818 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2819 | #line 2820 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2820 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2821 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2822 | /* We use char because int might match the return type of a gcc2 |
| 2823 | builtin and then its argument prototype would still apply. */ |
| 2824 | char shl_load(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2825 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2826 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2827 | shl_load() |
| 2828 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2829 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2830 | if { (eval echo configure:2831: \"$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] | 2831 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2832 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2833 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2834 | echo "configure: failed program was:" >&5 |
| 2835 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2836 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2837 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2838 | fi |
| 2839 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2840 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2841 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2842 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2843 | 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] | 2844 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2845 | ac_tr_lib=HAVE_LIB`echo dld | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 2846 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2847 | cat >> confdefs.h <<EOF |
| 2848 | #define $ac_tr_lib 1 |
| 2849 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2850 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2851 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2852 | |
| 2853 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2854 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2855 | fi |
| 2856 | # Dynamic linking for HP-UX |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 2857 | |
Skip Montanaro | cb85326 | 2000-08-30 22:29:48 +0000 | [diff] [blame] | 2858 | # Check for --with-pydebug |
| 2859 | echo $ac_n "checking for --with-pydebug""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2860 | echo "configure:2861: checking for --with-pydebug" >&5 |
Skip Montanaro | cb85326 | 2000-08-30 22:29:48 +0000 | [diff] [blame] | 2861 | # Check whether --with-pydebug or --without-pydebug was given. |
| 2862 | if test "${with_pydebug+set}" = set; then |
| 2863 | withval="$with_pydebug" |
| 2864 | |
| 2865 | if test "$withval" != no |
| 2866 | then cat >> confdefs.h <<\EOF |
| 2867 | #define Py_DEBUG 1 |
| 2868 | EOF |
| 2869 | echo "$ac_t""yes" 1>&6 |
| 2870 | else echo "$ac_t""no" 1>&6 |
| 2871 | fi |
| 2872 | else |
| 2873 | echo "$ac_t""no" 1>&6 |
| 2874 | fi |
| 2875 | |
| 2876 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 2877 | # checks for system dependent C++ extensions support |
| 2878 | case "$ac_sys_system" in |
| 2879 | AIX*) echo $ac_n "checking for genuine AIX C++ extensions support""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2880 | echo "configure:2881: checking for genuine AIX C++ extensions support" >&5 |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 2881 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2882 | #line 2883 "configure" |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 2883 | #include "confdefs.h" |
| 2884 | #include "/usr/lpp/xlC/include/load.h" |
| 2885 | int main() { |
| 2886 | loadAndInit("", 0, "") |
| 2887 | ; return 0; } |
| 2888 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2889 | if { (eval echo configure:2890: \"$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] | 2890 | rm -rf conftest* |
| 2891 | cat >> confdefs.h <<\EOF |
| 2892 | #define AIX_GENUINE_CPLUSPLUS 1 |
| 2893 | EOF |
| 2894 | |
| 2895 | echo "$ac_t""yes" 1>&6 |
| 2896 | else |
| 2897 | echo "configure: failed program was:" >&5 |
| 2898 | cat conftest.$ac_ext >&5 |
| 2899 | rm -rf conftest* |
| 2900 | echo "$ac_t""no" 1>&6 |
| 2901 | fi |
| 2902 | rm -f conftest*;; |
| 2903 | *) ;; |
| 2904 | esac |
| 2905 | |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 2906 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
| 2907 | # However on SGI IRIX, these exist but are broken. |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2908 | # BeOS' sockets are stashed in libnet. |
| 2909 | case "$ac_sys_system" in |
| 2910 | IRIX*) ;; |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 2911 | *) |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2912 | echo $ac_n "checking for t_open in -lnsl""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2913 | echo "configure:2914: checking for t_open in -lnsl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2914 | ac_lib_var=`echo nsl'_'t_open | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2915 | 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] | 2916 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2917 | else |
| 2918 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2919 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2920 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2921 | #line 2922 "configure" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2922 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2923 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2924 | /* We use char because int might match the return type of a gcc2 |
| 2925 | builtin and then its argument prototype would still apply. */ |
| 2926 | char t_open(); |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2927 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2928 | int main() { |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 2929 | t_open() |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2930 | ; return 0; } |
| 2931 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2932 | if { (eval echo configure:2933: \"$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] | 2933 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2934 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2935 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2936 | echo "configure: failed program was:" >&5 |
| 2937 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2938 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2939 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2940 | fi |
| 2941 | rm -f conftest* |
| 2942 | LIBS="$ac_save_LIBS" |
| 2943 | |
| 2944 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2945 | 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] | 2946 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2947 | LIBS="-lnsl $LIBS" |
| 2948 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2949 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 2950 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 2951 | # SVR4 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2952 | echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2953 | echo "configure:2954: checking for socket in -lsocket" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2954 | ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2955 | 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] | 2956 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2957 | else |
| 2958 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2959 | LIBS="-lsocket $LIBS $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2960 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2961 | #line 2962 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2962 | #include "confdefs.h" |
| 2963 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2964 | /* We use char because int might match the return type of a gcc2 |
| 2965 | builtin and then its argument prototype would still apply. */ |
| 2966 | char socket(); |
| 2967 | |
| 2968 | int main() { |
| 2969 | socket() |
| 2970 | ; return 0; } |
| 2971 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2972 | if { (eval echo configure:2973: \"$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] | 2973 | rm -rf conftest* |
| 2974 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 2975 | else |
| 2976 | echo "configure: failed program was:" >&5 |
| 2977 | cat conftest.$ac_ext >&5 |
| 2978 | rm -rf conftest* |
| 2979 | eval "ac_cv_lib_$ac_lib_var=no" |
| 2980 | fi |
| 2981 | rm -f conftest* |
| 2982 | LIBS="$ac_save_LIBS" |
| 2983 | |
| 2984 | fi |
| 2985 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 2986 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2987 | LIBS="-lsocket $LIBS" |
| 2988 | else |
| 2989 | echo "$ac_t""no" 1>&6 |
| 2990 | fi |
| 2991 | # SVR4 sockets |
Jeremy Hylton | cb25d5e | 2000-07-27 21:23:28 +0000 | [diff] [blame] | 2992 | ;; |
| 2993 | esac |
| 2994 | case "$ac_sys_system" in |
| 2995 | BeOS*) |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2996 | echo $ac_n "checking for socket in -lnet""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2997 | echo "configure:2998: checking for socket in -lnet" >&5 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2998 | ac_lib_var=`echo net'_'socket | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 2999 | 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] | 3000 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3001 | else |
| 3002 | ac_save_LIBS="$LIBS" |
| 3003 | LIBS="-lnet $LIBS $LIBS" |
| 3004 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3005 | #line 3006 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3006 | #include "confdefs.h" |
| 3007 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3008 | /* We use char because int might match the return type of a gcc2 |
| 3009 | builtin and then its argument prototype would still apply. */ |
| 3010 | char socket(); |
| 3011 | |
| 3012 | int main() { |
| 3013 | socket() |
| 3014 | ; return 0; } |
| 3015 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3016 | if { (eval echo configure:3017: \"$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] | 3017 | rm -rf conftest* |
| 3018 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3019 | else |
| 3020 | echo "configure: failed program was:" >&5 |
| 3021 | cat conftest.$ac_ext >&5 |
| 3022 | rm -rf conftest* |
| 3023 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3024 | fi |
| 3025 | rm -f conftest* |
| 3026 | LIBS="$ac_save_LIBS" |
| 3027 | |
| 3028 | fi |
| 3029 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3030 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3031 | LIBS="-lnet $LIBS" |
| 3032 | else |
| 3033 | echo "$ac_t""no" 1>&6 |
| 3034 | fi |
| 3035 | # BeOS |
| 3036 | ;; |
| 3037 | esac |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 3038 | |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 3039 | echo $ac_n "checking for --with-libs""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3040 | echo "configure:3041: checking for --with-libs" >&5 |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 3041 | # Check whether --with-libs or --without-libs was given. |
| 3042 | if test "${with_libs+set}" = set; then |
| 3043 | withval="$with_libs" |
| 3044 | |
| 3045 | echo "$ac_t""$withval" 1>&6 |
| 3046 | LIBS="$withval $LIBS" |
| 3047 | |
| 3048 | else |
| 3049 | echo "$ac_t""no" 1>&6 |
| 3050 | fi |
| 3051 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3052 | |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 3053 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3054 | USE_THREAD_MODULE="" |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 3055 | |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3056 | echo $ac_n "checking for --with-dec-threads""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3057 | echo "configure:3058: checking for --with-dec-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3058 | |
| 3059 | # Check whether --with-dec-threads or --without-dec-threads was given. |
| 3060 | if test "${with_dec_threads+set}" = set; then |
| 3061 | withval="$with_dec_threads" |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3062 | |
| 3063 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3064 | LDLAST=-threads |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3065 | if test "${with_thread+set}" != set; then |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3066 | with_thread="$withval"; |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3067 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3068 | else |
| 3069 | echo "$ac_t""no" 1>&6 |
| 3070 | fi |
| 3071 | |
| 3072 | |
| 3073 | echo $ac_n "checking for --with-threads""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3074 | echo "configure:3075: checking for --with-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3075 | # Check whether --with-threads or --without-threads was given. |
| 3076 | if test "${with_threads+set}" = set; then |
| 3077 | withval="$with_threads" |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3078 | : |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3079 | fi |
| 3080 | |
| 3081 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3082 | # --with-thread is deprecated, but check for it anyway |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3083 | # Check whether --with-thread or --without-thread was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3084 | if test "${with_thread+set}" = set; then |
| 3085 | withval="$with_thread" |
Barry Warsaw | a0f3c5c | 2000-06-30 16:39:35 +0000 | [diff] [blame] | 3086 | |
| 3087 | with_threads=$with_thread |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3088 | fi |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3089 | |
| 3090 | |
| 3091 | if test -z "$with_threads" |
| 3092 | then with_threads="yes" |
| 3093 | fi |
| 3094 | echo "$ac_t""$with_threads" 1>&6 |
| 3095 | |
| 3096 | if test "$with_threads" = "no" |
| 3097 | then |
| 3098 | USE_THREAD_MODULE="#" |
| 3099 | else |
| 3100 | if test -d "$with_threads" |
| 3101 | then LDFLAGS="$LDFLAGS -L$with_threads" |
| 3102 | fi |
| 3103 | if test -d "$withval" |
| 3104 | then LDFLAGS="$LDFLAGS -L$withval" |
| 3105 | fi |
| 3106 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 3107 | #define _REENTRANT 1 |
| 3108 | EOF |
| 3109 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3110 | ac_safe=`echo "mach/cthreads.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3111 | echo $ac_n "checking for mach/cthreads.h""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3112 | echo "configure:3113: checking for mach/cthreads.h" >&5 |
| 3113 | 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] | 3114 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3115 | else |
| 3116 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3117 | #line 3118 "configure" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3118 | #include "confdefs.h" |
| 3119 | #include <mach/cthreads.h> |
| 3120 | EOF |
| 3121 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3122 | { (eval echo configure:3123: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3123 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3124 | if test -z "$ac_err"; then |
| 3125 | rm -rf conftest* |
| 3126 | eval "ac_cv_header_$ac_safe=yes" |
| 3127 | else |
| 3128 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3129 | echo "configure: failed program was:" >&5 |
| 3130 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3131 | rm -rf conftest* |
| 3132 | eval "ac_cv_header_$ac_safe=no" |
| 3133 | fi |
| 3134 | rm -f conftest* |
| 3135 | fi |
| 3136 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 3137 | echo "$ac_t""yes" 1>&6 |
| 3138 | cat >> confdefs.h <<\EOF |
| 3139 | #define WITH_THREAD 1 |
| 3140 | EOF |
| 3141 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3142 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3143 | #define C_THREADS 1 |
| 3144 | EOF |
| 3145 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3146 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3147 | else |
| 3148 | echo "$ac_t""no" 1>&6 |
| 3149 | |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 3150 | echo $ac_n "checking for --with-pth""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3151 | echo "configure:3152: checking for --with-pth" >&5 |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 3152 | # Check whether --with-pth or --without-pth was given. |
| 3153 | if test "${with_pth+set}" = set; then |
| 3154 | withval="$with_pth" |
| 3155 | |
| 3156 | echo "$ac_t""$withval" 1>&6 |
| 3157 | cat >> confdefs.h <<\EOF |
| 3158 | #define WITH_THREAD 1 |
| 3159 | EOF |
| 3160 | |
| 3161 | cat >> confdefs.h <<\EOF |
| 3162 | #define HAVE_PTH 1 |
| 3163 | EOF |
| 3164 | |
| 3165 | LIBS="-lpth $LIBS" |
| 3166 | LIBOBJS="$LIBOBJS thread.o" |
| 3167 | else |
| 3168 | |
| 3169 | echo "$ac_t""no" 1>&6 |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3170 | echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3171 | echo "configure:3172: checking for pthread_create in -lpthread" >&5 |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3172 | ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3173 | 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] | 3174 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3175 | else |
| 3176 | ac_save_LIBS="$LIBS" |
| 3177 | LIBS="-lpthread $LIBS" |
| 3178 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3179 | #line 3180 "configure" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3180 | #include "confdefs.h" |
| 3181 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3182 | /* We use char because int might match the return type of a gcc2 |
| 3183 | builtin and then its argument prototype would still apply. */ |
| 3184 | char pthread_create(); |
| 3185 | |
| 3186 | int main() { |
| 3187 | pthread_create() |
| 3188 | ; return 0; } |
| 3189 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3190 | if { (eval echo configure:3191: \"$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] | 3191 | rm -rf conftest* |
| 3192 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3193 | else |
| 3194 | echo "configure: failed program was:" >&5 |
| 3195 | cat conftest.$ac_ext >&5 |
| 3196 | rm -rf conftest* |
| 3197 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3198 | fi |
| 3199 | rm -f conftest* |
| 3200 | LIBS="$ac_save_LIBS" |
| 3201 | |
| 3202 | fi |
| 3203 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3204 | echo "$ac_t""yes" 1>&6 |
| 3205 | cat >> confdefs.h <<\EOF |
| 3206 | #define WITH_THREAD 1 |
| 3207 | EOF |
| 3208 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3209 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3210 | #define _POSIX_THREADS 1 |
| 3211 | EOF |
| 3212 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3213 | LIBS="-lpthread $LIBS" |
| 3214 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3215 | else |
| 3216 | echo "$ac_t""no" 1>&6 |
| 3217 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3218 | echo $ac_n "checking for pthread_detach""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3219 | echo "configure:3220: checking for pthread_detach" >&5 |
| 3220 | 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] | 3221 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3222 | else |
| 3223 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3224 | #line 3225 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3225 | #include "confdefs.h" |
| 3226 | /* System header to define __stub macros and hopefully few prototypes, |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3227 | which can conflict with char pthread_detach(); below. */ |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3228 | #include <assert.h> |
| 3229 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3230 | /* We use char because int might match the return type of a gcc2 |
| 3231 | builtin and then its argument prototype would still apply. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3232 | char pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3233 | |
| 3234 | int main() { |
| 3235 | |
| 3236 | /* The GNU C library defines this for functions which it implements |
| 3237 | to always fail with ENOSYS. Some functions are actually named |
| 3238 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3239 | #if defined (__stub_pthread_detach) || defined (__stub___pthread_detach) |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3240 | choke me |
| 3241 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3242 | pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3243 | #endif |
| 3244 | |
| 3245 | ; return 0; } |
| 3246 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3247 | if { (eval echo configure:3248: \"$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] | 3248 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3249 | eval "ac_cv_func_pthread_detach=yes" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3250 | else |
| 3251 | echo "configure: failed program was:" >&5 |
| 3252 | cat conftest.$ac_ext >&5 |
| 3253 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3254 | eval "ac_cv_func_pthread_detach=no" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3255 | fi |
| 3256 | rm -f conftest* |
| 3257 | fi |
| 3258 | |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3259 | if eval "test \"`echo '$ac_cv_func_'pthread_detach`\" = yes"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3260 | echo "$ac_t""yes" 1>&6 |
| 3261 | cat >> confdefs.h <<\EOF |
| 3262 | #define WITH_THREAD 1 |
| 3263 | EOF |
| 3264 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3265 | cat >> confdefs.h <<\EOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3266 | #define _POSIX_THREADS 1 |
| 3267 | EOF |
| 3268 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3269 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3270 | else |
| 3271 | echo "$ac_t""no" 1>&6 |
| 3272 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3273 | ac_safe=`echo "kernel/OS.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3274 | echo $ac_n "checking for kernel/OS.h""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3275 | echo "configure:3276: checking for kernel/OS.h" >&5 |
| 3276 | 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] | 3277 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3278 | else |
| 3279 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3280 | #line 3281 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3281 | #include "confdefs.h" |
| 3282 | #include <kernel/OS.h> |
| 3283 | EOF |
| 3284 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3285 | { (eval echo configure:3286: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3286 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3287 | if test -z "$ac_err"; then |
| 3288 | rm -rf conftest* |
| 3289 | eval "ac_cv_header_$ac_safe=yes" |
| 3290 | else |
| 3291 | echo "$ac_err" >&5 |
| 3292 | echo "configure: failed program was:" >&5 |
| 3293 | cat conftest.$ac_ext >&5 |
| 3294 | rm -rf conftest* |
| 3295 | eval "ac_cv_header_$ac_safe=no" |
| 3296 | fi |
| 3297 | rm -f conftest* |
| 3298 | fi |
| 3299 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 3300 | echo "$ac_t""yes" 1>&6 |
| 3301 | cat >> confdefs.h <<\EOF |
| 3302 | #define WITH_THREAD 1 |
| 3303 | EOF |
| 3304 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3305 | cat >> confdefs.h <<\EOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3306 | #define BEOS_THREADS 1 |
| 3307 | EOF |
| 3308 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3309 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3310 | else |
| 3311 | echo "$ac_t""no" 1>&6 |
| 3312 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3313 | echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3314 | echo "configure:3315: checking for pthread_create in -lpthreads" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3315 | ac_lib_var=`echo pthreads'_'pthread_create | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3316 | 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] | 3317 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3318 | else |
| 3319 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3320 | LIBS="-lpthreads $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3321 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3322 | #line 3323 "configure" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3323 | #include "confdefs.h" |
| 3324 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3325 | /* We use char because int might match the return type of a gcc2 |
| 3326 | builtin and then its argument prototype would still apply. */ |
| 3327 | char pthread_create(); |
| 3328 | |
| 3329 | int main() { |
| 3330 | pthread_create() |
| 3331 | ; return 0; } |
| 3332 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3333 | if { (eval echo configure:3334: \"$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] | 3334 | rm -rf conftest* |
| 3335 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3336 | else |
| 3337 | echo "configure: failed program was:" >&5 |
| 3338 | cat conftest.$ac_ext >&5 |
| 3339 | rm -rf conftest* |
| 3340 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3341 | fi |
| 3342 | rm -f conftest* |
| 3343 | LIBS="$ac_save_LIBS" |
| 3344 | |
| 3345 | fi |
| 3346 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3347 | echo "$ac_t""yes" 1>&6 |
| 3348 | cat >> confdefs.h <<\EOF |
| 3349 | #define WITH_THREAD 1 |
| 3350 | EOF |
| 3351 | |
| 3352 | cat >> confdefs.h <<\EOF |
| 3353 | #define _POSIX_THREADS 1 |
| 3354 | EOF |
| 3355 | |
| 3356 | LIBS="$LIBS -lpthreads" |
| 3357 | LIBOBJS="$LIBOBJS thread.o" |
| 3358 | else |
| 3359 | echo "$ac_t""no" 1>&6 |
| 3360 | |
| 3361 | echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3362 | echo "configure:3363: checking for pthread_create in -lc_r" >&5 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3363 | ac_lib_var=`echo c_r'_'pthread_create | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3364 | 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] | 3365 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3366 | else |
| 3367 | ac_save_LIBS="$LIBS" |
| 3368 | LIBS="-lc_r $LIBS" |
| 3369 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3370 | #line 3371 "configure" |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3371 | #include "confdefs.h" |
| 3372 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3373 | /* We use char because int might match the return type of a gcc2 |
| 3374 | builtin and then its argument prototype would still apply. */ |
| 3375 | char pthread_create(); |
| 3376 | |
| 3377 | int main() { |
| 3378 | pthread_create() |
| 3379 | ; return 0; } |
| 3380 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3381 | if { (eval echo configure:3382: \"$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] | 3382 | rm -rf conftest* |
| 3383 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3384 | else |
| 3385 | echo "configure: failed program was:" >&5 |
| 3386 | cat conftest.$ac_ext >&5 |
| 3387 | rm -rf conftest* |
| 3388 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3389 | fi |
| 3390 | rm -f conftest* |
| 3391 | LIBS="$ac_save_LIBS" |
| 3392 | |
| 3393 | fi |
| 3394 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3395 | echo "$ac_t""yes" 1>&6 |
| 3396 | cat >> confdefs.h <<\EOF |
| 3397 | #define WITH_THREAD 1 |
| 3398 | EOF |
| 3399 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3400 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3401 | #define _POSIX_THREADS 1 |
| 3402 | EOF |
| 3403 | |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3404 | LIBS="$LIBS -lc_r" |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3405 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3406 | else |
| 3407 | echo "$ac_t""no" 1>&6 |
| 3408 | |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3409 | echo $ac_n "checking for __d6_pthread_create in -lthread""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3410 | echo "configure:3411: checking for __d6_pthread_create in -lthread" >&5 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3411 | ac_lib_var=`echo thread'_'__d6_pthread_create | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3412 | 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] | 3413 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3414 | else |
| 3415 | ac_save_LIBS="$LIBS" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3416 | LIBS="-lthread $LIBS" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3417 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3418 | #line 3419 "configure" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3419 | #include "confdefs.h" |
| 3420 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3421 | /* We use char because int might match the return type of a gcc2 |
| 3422 | builtin and then its argument prototype would still apply. */ |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3423 | char __d6_pthread_create(); |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3424 | |
| 3425 | int main() { |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3426 | __d6_pthread_create() |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3427 | ; return 0; } |
| 3428 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3429 | if { (eval echo configure:3430: \"$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] | 3430 | rm -rf conftest* |
| 3431 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3432 | else |
| 3433 | echo "configure: failed program was:" >&5 |
| 3434 | cat conftest.$ac_ext >&5 |
| 3435 | rm -rf conftest* |
| 3436 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3437 | fi |
| 3438 | rm -f conftest* |
| 3439 | LIBS="$ac_save_LIBS" |
| 3440 | |
| 3441 | fi |
| 3442 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3443 | echo "$ac_t""yes" 1>&6 |
| 3444 | cat >> confdefs.h <<\EOF |
| 3445 | #define WITH_THREAD 1 |
| 3446 | EOF |
| 3447 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3448 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3449 | #define _POSIX_THREADS 1 |
| 3450 | EOF |
| 3451 | |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3452 | LIBS="$LIBS -lthread" |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3453 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3454 | else |
| 3455 | echo "$ac_t""no" 1>&6 |
| 3456 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3457 | echo $ac_n "checking for pthread_create in -lcma""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3458 | echo "configure:3459: checking for pthread_create in -lcma" >&5 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3459 | ac_lib_var=`echo cma'_'pthread_create | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3460 | 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] | 3461 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3462 | else |
| 3463 | ac_save_LIBS="$LIBS" |
| 3464 | LIBS="-lcma $LIBS" |
| 3465 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3466 | #line 3467 "configure" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3467 | #include "confdefs.h" |
| 3468 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3469 | /* We use char because int might match the return type of a gcc2 |
| 3470 | builtin and then its argument prototype would still apply. */ |
| 3471 | char pthread_create(); |
| 3472 | |
| 3473 | int main() { |
| 3474 | pthread_create() |
| 3475 | ; return 0; } |
| 3476 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3477 | if { (eval echo configure:3478: \"$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] | 3478 | rm -rf conftest* |
| 3479 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3480 | else |
| 3481 | echo "configure: failed program was:" >&5 |
| 3482 | cat conftest.$ac_ext >&5 |
| 3483 | rm -rf conftest* |
| 3484 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3485 | fi |
| 3486 | rm -f conftest* |
| 3487 | LIBS="$ac_save_LIBS" |
| 3488 | |
| 3489 | fi |
| 3490 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3491 | echo "$ac_t""yes" 1>&6 |
| 3492 | cat >> confdefs.h <<\EOF |
| 3493 | #define WITH_THREAD 1 |
| 3494 | EOF |
| 3495 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3496 | cat >> confdefs.h <<\EOF |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3497 | #define _POSIX_THREADS 1 |
| 3498 | EOF |
| 3499 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3500 | LIBS="$LIBS -lcma" |
| 3501 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3502 | else |
| 3503 | echo "$ac_t""no" 1>&6 |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 3504 | |
| 3505 | USE_THREAD_MODULE="#" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 3506 | fi |
| 3507 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3508 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3509 | fi |
| 3510 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3511 | fi |
| 3512 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3513 | fi |
| 3514 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3515 | fi |
| 3516 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3517 | fi |
| 3518 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3519 | fi |
| 3520 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3521 | fi |
| 3522 | |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3523 | fi |
| 3524 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 3525 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3526 | echo $ac_n "checking for usconfig in -lmpc""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3527 | echo "configure:3528: checking for usconfig in -lmpc" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3528 | ac_lib_var=`echo mpc'_'usconfig | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3529 | 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] | 3530 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3531 | else |
| 3532 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3533 | LIBS="-lmpc $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3534 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3535 | #line 3536 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3536 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3537 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3538 | /* We use char because int might match the return type of a gcc2 |
| 3539 | builtin and then its argument prototype would still apply. */ |
| 3540 | char usconfig(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3541 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3542 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3543 | usconfig() |
| 3544 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3545 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3546 | if { (eval echo configure:3547: \"$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] | 3547 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3548 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3549 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3550 | echo "configure: failed program was:" >&5 |
| 3551 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3552 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3553 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3554 | fi |
| 3555 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3556 | LIBS="$ac_save_LIBS" |
| 3557 | |
| 3558 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3559 | 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] | 3560 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3561 | cat >> confdefs.h <<\EOF |
| 3562 | #define WITH_THREAD 1 |
| 3563 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3564 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3565 | LIBS="$LIBS -lmpc" |
| 3566 | LIBOBJS="$LIBOBJS thread.o" |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 3567 | USE_THREAD_MODULE="" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3568 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3569 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3570 | fi |
| 3571 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3572 | echo $ac_n "checking for thr_create in -lthread""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3573 | echo "configure:3574: checking for thr_create in -lthread" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3574 | ac_lib_var=`echo thread'_'thr_create | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3575 | 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] | 3576 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3577 | else |
| 3578 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3579 | LIBS="-lthread $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3580 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3581 | #line 3582 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3582 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3583 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3584 | /* We use char because int might match the return type of a gcc2 |
| 3585 | builtin and then its argument prototype would still apply. */ |
| 3586 | char thr_create(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3587 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3588 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3589 | thr_create() |
| 3590 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3591 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3592 | if { (eval echo configure:3593: \"$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] | 3593 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3594 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3595 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3596 | echo "configure: failed program was:" >&5 |
| 3597 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3598 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3599 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3600 | fi |
| 3601 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3602 | LIBS="$ac_save_LIBS" |
| 3603 | |
| 3604 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3605 | 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] | 3606 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3607 | cat >> confdefs.h <<\EOF |
| 3608 | #define WITH_THREAD 1 |
| 3609 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3610 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3611 | LIBS="$LIBS -lthread" |
| 3612 | LIBOBJS="$LIBOBJS thread.o" |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 3613 | USE_THREAD_MODULE="" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3614 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3615 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3616 | fi |
| 3617 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3618 | fi |
| 3619 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 3620 | # Check for GC support |
| 3621 | |
| 3622 | USE_GC_MODULE="" |
| 3623 | echo $ac_n "checking for --with-cycle-gc""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3624 | echo "configure:3625: checking for --with-cycle-gc" >&5 |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 3625 | # Check whether --with-cycle-gc or --without-cycle-gc was given. |
| 3626 | if test "${with_cycle_gc+set}" = set; then |
| 3627 | withval="$with_cycle_gc" |
| 3628 | : |
| 3629 | fi |
| 3630 | |
| 3631 | |
| 3632 | if test -z "$with_cycle_gc" |
| 3633 | then with_cycle_gc="yes" |
| 3634 | fi |
| 3635 | if test "$with_cycle_gc" = "no" |
| 3636 | then |
| 3637 | USE_GC_MODULE="#" |
| 3638 | else |
| 3639 | cat >> confdefs.h <<\EOF |
| 3640 | #define WITH_CYCLE_GC 1 |
| 3641 | EOF |
| 3642 | |
| 3643 | fi |
| 3644 | echo "$ac_t""$with_cycle_gc" 1>&6 |
| 3645 | |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 3646 | # Check for LIBDB support |
| 3647 | # either --with-libdb or, in its absence, the presence of db.h |
| 3648 | |
| 3649 | USE_BSDDB_MODULE="" |
| 3650 | echo $ac_n "checking for --with-libdb""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3651 | echo "configure:3652: checking for --with-libdb" >&5 |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 3652 | # Check whether --with-libdb or --without-libdb was given. |
| 3653 | if test "${with_libdb+set}" = set; then |
| 3654 | withval="$with_libdb" |
| 3655 | : |
| 3656 | fi |
| 3657 | |
| 3658 | |
Skip Montanaro | b89f41e | 2000-09-04 04:06:05 +0000 | [diff] [blame] | 3659 | # enabled by default, but db.h must be found |
| 3660 | if test "$ac_cv_header_db_h" = "yes" |
| 3661 | then |
| 3662 | if test "$with_libdb" != "no" |
| 3663 | then with_libdb="yes" |
| 3664 | fi |
| 3665 | else |
| 3666 | # make sure user knows why bsddb support wasn't enabled event |
| 3667 | # though s/he requested it |
| 3668 | if test "$with_libdb" = "yes" |
| 3669 | then echo $ac_n "(requested, but db.h was not found) $ac_c" |
| 3670 | fi |
| 3671 | with_libdb="no" |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 3672 | fi |
Skip Montanaro | b89f41e | 2000-09-04 04:06:05 +0000 | [diff] [blame] | 3673 | |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 3674 | if test "$with_libdb" = "no" |
| 3675 | then |
| 3676 | USE_BSDDB_MODULE="#" |
| 3677 | else |
| 3678 | cat >> confdefs.h <<\EOF |
| 3679 | #define WITH_LIBDB 1 |
| 3680 | EOF |
| 3681 | |
| 3682 | fi |
| 3683 | echo "$ac_t""$with_libdb" 1>&6 |
| 3684 | |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 3685 | if test "$with_libdb" = "yes" |
| 3686 | then |
| 3687 | # check for libdb; BSD systems have the DB routines in libc --tg |
| 3688 | |
Martin v. Löwis | 05a65d6 | 2000-09-24 19:40:25 +0000 | [diff] [blame] | 3689 | # If dbopen is not in libc, then checking whether it is in libdb |
| 3690 | # is difficult: db_185.h may #define it as __db185_open |
Fred Drake | 02706f5 | 2000-09-25 15:08:46 +0000 | [diff] [blame] | 3691 | # Instead, we just trust it is in libdb; linking will fail if it |
| 3692 | # is not. |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 3693 | echo $ac_n "checking for dbopen""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3694 | echo "configure:3695: checking for dbopen" >&5 |
| 3695 | if eval "test \"`echo '$''{'ac_cv_func_dbopen'+set}'`\" = set"; then |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 3696 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3697 | else |
| 3698 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3699 | #line 3700 "configure" |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 3700 | #include "confdefs.h" |
| 3701 | /* System header to define __stub macros and hopefully few prototypes, |
| 3702 | which can conflict with char dbopen(); below. */ |
| 3703 | #include <assert.h> |
| 3704 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3705 | /* We use char because int might match the return type of a gcc2 |
| 3706 | builtin and then its argument prototype would still apply. */ |
| 3707 | char dbopen(); |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 3708 | |
| 3709 | int main() { |
| 3710 | |
| 3711 | /* The GNU C library defines this for functions which it implements |
| 3712 | to always fail with ENOSYS. Some functions are actually named |
| 3713 | something starting with __ and the normal name is an alias. */ |
| 3714 | #if defined (__stub_dbopen) || defined (__stub___dbopen) |
| 3715 | choke me |
| 3716 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3717 | dbopen(); |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 3718 | #endif |
| 3719 | |
| 3720 | ; return 0; } |
| 3721 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3722 | if { (eval echo configure:3723: \"$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] | 3723 | rm -rf conftest* |
| 3724 | eval "ac_cv_func_dbopen=yes" |
| 3725 | else |
| 3726 | echo "configure: failed program was:" >&5 |
| 3727 | cat conftest.$ac_ext >&5 |
| 3728 | rm -rf conftest* |
| 3729 | eval "ac_cv_func_dbopen=no" |
| 3730 | fi |
| 3731 | rm -f conftest* |
| 3732 | fi |
| 3733 | |
| 3734 | if eval "test \"`echo '$ac_cv_func_'dbopen`\" = yes"; then |
| 3735 | echo "$ac_t""yes" 1>&6 |
| 3736 | HAVE_LIBDB= |
| 3737 | else |
| 3738 | echo "$ac_t""no" 1>&6 |
Martin v. Löwis | 05a65d6 | 2000-09-24 19:40:25 +0000 | [diff] [blame] | 3739 | HAVE_LIBDB=-ldb |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 3740 | fi |
| 3741 | |
| 3742 | fi |
| 3743 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 3744 | # Check for --with-wctype-functions |
| 3745 | echo $ac_n "checking for --with-wctype-functions""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3746 | echo "configure:3747: checking for --with-wctype-functions" >&5 |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 3747 | # Check whether --with-wctype-functions or --without-wctype-functions was given. |
| 3748 | if test "${with_wctype_functions+set}" = set; then |
| 3749 | withval="$with_wctype_functions" |
| 3750 | |
| 3751 | if test "$withval" != no |
| 3752 | then cat >> confdefs.h <<\EOF |
| 3753 | #define WANT_WCTYPE_FUNCTIONS 1 |
| 3754 | EOF |
| 3755 | echo "$ac_t""yes" 1>&6 |
| 3756 | else echo "$ac_t""no" 1>&6 |
| 3757 | fi |
| 3758 | else |
| 3759 | echo "$ac_t""no" 1>&6 |
| 3760 | fi |
| 3761 | |
| 3762 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3763 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3764 | |
| 3765 | DLINCLDIR=/ |
| 3766 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3767 | echo $ac_n "checking for --with-sgi-dl""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3768 | echo "configure:3769: checking for --with-sgi-dl" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3769 | # Check whether --with-sgi-dl or --without-sgi-dl was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3770 | if test "${with_sgi_dl+set}" = set; then |
| 3771 | withval="$with_sgi_dl" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3772 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3773 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3774 | cat >> confdefs.h <<\EOF |
| 3775 | #define WITH_SGI_DL 1 |
| 3776 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3777 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3778 | DYNLOADFILE="dynload_dl.o" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3779 | dldir=$withval |
| 3780 | if test -d "$dldir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 3781 | then LDFLAGS="$LDFLAGS -L$dldir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3782 | 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] | 3783 | fi |
| 3784 | DLINCLDIR=${dldir} |
| 3785 | LIBS="$LIBS -ldl -lmld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3786 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3787 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3788 | fi |
| 3789 | |
| 3790 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3791 | echo $ac_n "checking for --with-dl-dld""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3792 | echo "configure:3793: checking for --with-dl-dld" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3793 | # Check whether --with-dl-dld or --without-dl-dld was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3794 | if test "${with_dl_dld+set}" = set; then |
| 3795 | withval="$with_dl_dld" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3796 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3797 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3798 | cat >> confdefs.h <<\EOF |
| 3799 | #define WITH_DL_DLD 1 |
| 3800 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3801 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3802 | DYNLOADFILE="dynload_dl.o" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3803 | dldir=`echo "$withval" | sed 's/,.*//'` |
| 3804 | dlddir=`echo "$withval" | sed 's/.*,//'` |
| 3805 | if test -d "$dldir" -a -d "$dlddir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 3806 | then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3807 | 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] | 3808 | fi |
| 3809 | DLINCLDIR=${dldir} |
| 3810 | LIBS="$LIBS -ldl -ldld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3811 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3812 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3813 | fi |
| 3814 | |
| 3815 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3816 | # the dlopen() function means we might want to use dynload_shlib.o. some |
| 3817 | # 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] | 3818 | for ac_func in dlopen |
| 3819 | do |
| 3820 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3821 | echo "configure:3822: checking for $ac_func" >&5 |
| 3822 | 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] | 3823 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3824 | else |
| 3825 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3826 | #line 3827 "configure" |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3827 | #include "confdefs.h" |
| 3828 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 3829 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3830 | #include <assert.h> |
| 3831 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3832 | /* We use char because int might match the return type of a gcc2 |
| 3833 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 3834 | char $ac_func(); |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3835 | |
| 3836 | int main() { |
| 3837 | |
| 3838 | /* The GNU C library defines this for functions which it implements |
| 3839 | to always fail with ENOSYS. Some functions are actually named |
| 3840 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 3841 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3842 | choke me |
| 3843 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3844 | $ac_func(); |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3845 | #endif |
| 3846 | |
| 3847 | ; return 0; } |
| 3848 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3849 | if { (eval echo configure:3850: \"$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] | 3850 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 3851 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3852 | else |
| 3853 | echo "configure: failed program was:" >&5 |
| 3854 | cat conftest.$ac_ext >&5 |
| 3855 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 3856 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3857 | fi |
| 3858 | rm -f conftest* |
| 3859 | fi |
| 3860 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 3861 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3862 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 3863 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 3864 | cat >> confdefs.h <<EOF |
| 3865 | #define $ac_tr_func 1 |
| 3866 | EOF |
| 3867 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3868 | else |
| 3869 | echo "$ac_t""no" 1>&6 |
| 3870 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 3871 | done |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3872 | |
| 3873 | |
| 3874 | # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic |
| 3875 | # loading of modules. |
| 3876 | |
| 3877 | echo $ac_n "checking DYNLOADFILE""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3878 | echo "configure:3879: checking DYNLOADFILE" >&5 |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 3879 | if test -z "$DYNLOADFILE" |
| 3880 | then |
| 3881 | case $ac_sys_system/$ac_sys_release in |
| 3882 | AIX*) DYNLOADFILE="dynload_aix.o";; |
| 3883 | BeOS*) DYNLOADFILE="dynload_beos.o";; |
| 3884 | hp*|HP*) DYNLOADFILE="dynload_hpux.o";; |
| 3885 | next/*) DYNLOADFILE="dynload_next.o";; |
| 3886 | *) |
| 3887 | # use dynload_shlib.c and dlopen() if we have it; otherwise stub |
| 3888 | # out any dynamic loading |
| 3889 | if test "$ac_cv_func_dlopen" = yes |
| 3890 | then DYNLOADFILE="dynload_shlib.o" |
| 3891 | else DYNLOADFILE="dynload_stub.o" |
| 3892 | fi |
| 3893 | ;; |
| 3894 | esac |
| 3895 | fi |
| 3896 | echo "$ac_t""$DYNLOADFILE" 1>&6 |
| 3897 | if test "$DYNLOADFILE" != "dynload_stub.o" |
| 3898 | then |
| 3899 | cat >> confdefs.h <<\EOF |
| 3900 | #define HAVE_DYNAMIC_LOADING 1 |
| 3901 | EOF |
| 3902 | |
| 3903 | fi |
| 3904 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3905 | # checks for library functions |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 3906 | for ac_func in alarm chown clock confstr ctermid ctermid_r execv \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 3907 | flock fork fsync fdatasync fpathconf ftime ftruncate \ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 3908 | getgroups getlogin getpeername getpid getpwent getwd \ |
Andrew M. Kuchling | 22c6934 | 2000-06-18 15:07:40 +0000 | [diff] [blame] | 3909 | kill link lstat mkfifo mktime mremap \ |
Andrew M. Kuchling | 5821b77 | 2000-08-25 01:14:08 +0000 | [diff] [blame] | 3910 | nice pathconf pause plock poll pthread_init \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 3911 | putenv readlink \ |
Andrew M. Kuchling | 8d2f2b2 | 2000-07-13 01:26:58 +0000 | [diff] [blame] | 3912 | select setegid seteuid setgid \ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 3913 | setlocale setregid setreuid setsid setpgid setuid setvbuf \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 3914 | sigaction siginterrupt sigrelse strftime strptime symlink sysconf \ |
Fred Drake | 89143df | 1999-12-09 22:03:25 +0000 | [diff] [blame] | 3915 | tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ |
Thomas Wouters | 70c21a1 | 2000-07-14 14:28:33 +0000 | [diff] [blame] | 3916 | truncate uname waitpid _getpty |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3917 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3918 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3919 | echo "configure:3920: checking for $ac_func" >&5 |
| 3920 | 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] | 3921 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3922 | else |
| 3923 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3924 | #line 3925 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3925 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3926 | /* System header to define __stub macros and hopefully few prototypes, |
| 3927 | which can conflict with char $ac_func(); below. */ |
| 3928 | #include <assert.h> |
| 3929 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3930 | /* We use char because int might match the return type of a gcc2 |
| 3931 | builtin and then its argument prototype would still apply. */ |
| 3932 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3933 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3934 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3935 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3936 | /* The GNU C library defines this for functions which it implements |
| 3937 | to always fail with ENOSYS. Some functions are actually named |
| 3938 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3939 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3940 | choke me |
| 3941 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3942 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3943 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3944 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3945 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3946 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3947 | if { (eval echo configure:3948: \"$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] | 3948 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3949 | eval "ac_cv_func_$ac_func=yes" |
| 3950 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3951 | echo "configure: failed program was:" >&5 |
| 3952 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3953 | rm -rf conftest* |
| 3954 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3955 | fi |
| 3956 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3957 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3958 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3959 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3960 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3961 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3962 | cat >> confdefs.h <<EOF |
| 3963 | #define $ac_tr_func 1 |
| 3964 | EOF |
| 3965 | |
| 3966 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3967 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3968 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3969 | done |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3970 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 3971 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 3972 | # check for openpty and forkpty |
| 3973 | |
| 3974 | for ac_func in openpty |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3975 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3976 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3977 | echo "configure:3978: checking for $ac_func" >&5 |
| 3978 | 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] | 3979 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3980 | else |
| 3981 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 3982 | #line 3983 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3983 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3984 | /* System header to define __stub macros and hopefully few prototypes, |
| 3985 | which can conflict with char $ac_func(); below. */ |
| 3986 | #include <assert.h> |
| 3987 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3988 | /* We use char because int might match the return type of a gcc2 |
| 3989 | builtin and then its argument prototype would still apply. */ |
| 3990 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3991 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3992 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3993 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3994 | /* The GNU C library defines this for functions which it implements |
| 3995 | to always fail with ENOSYS. Some functions are actually named |
| 3996 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3997 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3998 | choke me |
| 3999 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4000 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4001 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4002 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4003 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4004 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4005 | if { (eval echo configure:4006: \"$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] | 4006 | rm -rf conftest* |
| 4007 | eval "ac_cv_func_$ac_func=yes" |
| 4008 | else |
| 4009 | echo "configure: failed program was:" >&5 |
| 4010 | cat conftest.$ac_ext >&5 |
| 4011 | rm -rf conftest* |
| 4012 | eval "ac_cv_func_$ac_func=no" |
| 4013 | fi |
| 4014 | rm -f conftest* |
| 4015 | fi |
| 4016 | |
| 4017 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4018 | echo "$ac_t""yes" 1>&6 |
| 4019 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4020 | cat >> confdefs.h <<EOF |
| 4021 | #define $ac_tr_func 1 |
| 4022 | EOF |
| 4023 | |
| 4024 | else |
| 4025 | echo "$ac_t""no" 1>&6 |
| 4026 | echo $ac_n "checking for openpty in -lutil""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4027 | echo "configure:4028: checking for openpty in -lutil" >&5 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4028 | ac_lib_var=`echo util'_'openpty | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4029 | 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] | 4030 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4031 | else |
| 4032 | ac_save_LIBS="$LIBS" |
| 4033 | LIBS="-lutil $LIBS" |
| 4034 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4035 | #line 4036 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4036 | #include "confdefs.h" |
| 4037 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4038 | /* We use char because int might match the return type of a gcc2 |
| 4039 | builtin and then its argument prototype would still apply. */ |
| 4040 | char openpty(); |
| 4041 | |
| 4042 | int main() { |
| 4043 | openpty() |
| 4044 | ; return 0; } |
| 4045 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4046 | if { (eval echo configure:4047: \"$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] | 4047 | rm -rf conftest* |
| 4048 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 4049 | else |
| 4050 | echo "configure: failed program was:" >&5 |
| 4051 | cat conftest.$ac_ext >&5 |
| 4052 | rm -rf conftest* |
| 4053 | eval "ac_cv_lib_$ac_lib_var=no" |
| 4054 | fi |
| 4055 | rm -f conftest* |
| 4056 | LIBS="$ac_save_LIBS" |
| 4057 | |
| 4058 | fi |
| 4059 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 4060 | echo "$ac_t""yes" 1>&6 |
| 4061 | cat >> confdefs.h <<\EOF |
| 4062 | #define HAVE_OPENPTY 1 |
| 4063 | EOF |
| 4064 | LIBS="$LIBS -lutil" |
| 4065 | else |
| 4066 | echo "$ac_t""no" 1>&6 |
| 4067 | fi |
| 4068 | |
| 4069 | fi |
| 4070 | done |
| 4071 | |
| 4072 | for ac_func in forkpty |
| 4073 | do |
| 4074 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4075 | echo "configure:4076: checking for $ac_func" >&5 |
| 4076 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4077 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4078 | else |
| 4079 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4080 | #line 4081 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4081 | #include "confdefs.h" |
| 4082 | /* System header to define __stub macros and hopefully few prototypes, |
| 4083 | which can conflict with char $ac_func(); below. */ |
| 4084 | #include <assert.h> |
| 4085 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4086 | /* We use char because int might match the return type of a gcc2 |
| 4087 | builtin and then its argument prototype would still apply. */ |
| 4088 | char $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4089 | |
| 4090 | int main() { |
| 4091 | |
| 4092 | /* The GNU C library defines this for functions which it implements |
| 4093 | to always fail with ENOSYS. Some functions are actually named |
| 4094 | something starting with __ and the normal name is an alias. */ |
| 4095 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4096 | choke me |
| 4097 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4098 | $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4099 | #endif |
| 4100 | |
| 4101 | ; return 0; } |
| 4102 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4103 | if { (eval echo configure:4104: \"$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] | 4104 | rm -rf conftest* |
| 4105 | eval "ac_cv_func_$ac_func=yes" |
| 4106 | else |
| 4107 | echo "configure: failed program was:" >&5 |
| 4108 | cat conftest.$ac_ext >&5 |
| 4109 | rm -rf conftest* |
| 4110 | eval "ac_cv_func_$ac_func=no" |
| 4111 | fi |
| 4112 | rm -f conftest* |
| 4113 | fi |
| 4114 | |
| 4115 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4116 | echo "$ac_t""yes" 1>&6 |
| 4117 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4118 | cat >> confdefs.h <<EOF |
| 4119 | #define $ac_tr_func 1 |
| 4120 | EOF |
| 4121 | |
| 4122 | else |
| 4123 | echo "$ac_t""no" 1>&6 |
| 4124 | echo $ac_n "checking for forkpty in -lutil""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4125 | echo "configure:4126: checking for forkpty in -lutil" >&5 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4126 | ac_lib_var=`echo util'_'forkpty | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4127 | 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] | 4128 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4129 | else |
| 4130 | ac_save_LIBS="$LIBS" |
| 4131 | LIBS="-lutil $LIBS" |
| 4132 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4133 | #line 4134 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4134 | #include "confdefs.h" |
| 4135 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4136 | /* We use char because int might match the return type of a gcc2 |
| 4137 | builtin and then its argument prototype would still apply. */ |
| 4138 | char forkpty(); |
| 4139 | |
| 4140 | int main() { |
| 4141 | forkpty() |
| 4142 | ; return 0; } |
| 4143 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4144 | if { (eval echo configure:4145: \"$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] | 4145 | rm -rf conftest* |
| 4146 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 4147 | else |
| 4148 | echo "configure: failed program was:" >&5 |
| 4149 | cat conftest.$ac_ext >&5 |
| 4150 | rm -rf conftest* |
| 4151 | eval "ac_cv_lib_$ac_lib_var=no" |
| 4152 | fi |
| 4153 | rm -f conftest* |
| 4154 | LIBS="$ac_save_LIBS" |
| 4155 | |
| 4156 | fi |
| 4157 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 4158 | echo "$ac_t""yes" 1>&6 |
| 4159 | cat >> confdefs.h <<\EOF |
| 4160 | #define HAVE_FORKPTY 1 |
| 4161 | EOF |
| 4162 | LIBS="$LIBS -lutil" |
| 4163 | else |
| 4164 | echo "$ac_t""no" 1>&6 |
| 4165 | fi |
| 4166 | |
| 4167 | fi |
| 4168 | done |
| 4169 | |
| 4170 | |
| 4171 | # check for long file support functions |
| 4172 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
| 4173 | do |
| 4174 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4175 | echo "configure:4176: checking for $ac_func" >&5 |
| 4176 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4177 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4178 | else |
| 4179 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4180 | #line 4181 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4181 | #include "confdefs.h" |
| 4182 | /* System header to define __stub macros and hopefully few prototypes, |
| 4183 | which can conflict with char $ac_func(); below. */ |
| 4184 | #include <assert.h> |
| 4185 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4186 | /* We use char because int might match the return type of a gcc2 |
| 4187 | builtin and then its argument prototype would still apply. */ |
| 4188 | char $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4189 | |
| 4190 | int main() { |
| 4191 | |
| 4192 | /* The GNU C library defines this for functions which it implements |
| 4193 | to always fail with ENOSYS. Some functions are actually named |
| 4194 | something starting with __ and the normal name is an alias. */ |
| 4195 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4196 | choke me |
| 4197 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4198 | $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4199 | #endif |
| 4200 | |
| 4201 | ; return 0; } |
| 4202 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4203 | if { (eval echo configure:4204: \"$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] | 4204 | rm -rf conftest* |
| 4205 | eval "ac_cv_func_$ac_func=yes" |
| 4206 | else |
| 4207 | echo "configure: failed program was:" >&5 |
| 4208 | cat conftest.$ac_ext >&5 |
| 4209 | rm -rf conftest* |
| 4210 | eval "ac_cv_func_$ac_func=no" |
| 4211 | fi |
| 4212 | rm -f conftest* |
| 4213 | fi |
| 4214 | |
| 4215 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4216 | echo "$ac_t""yes" 1>&6 |
| 4217 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4218 | cat >> confdefs.h <<EOF |
| 4219 | #define $ac_tr_func 1 |
| 4220 | EOF |
| 4221 | |
| 4222 | else |
| 4223 | echo "$ac_t""no" 1>&6 |
| 4224 | fi |
| 4225 | done |
| 4226 | |
| 4227 | |
| 4228 | for ac_func in dup2 getcwd strdup strerror memmove |
| 4229 | do |
| 4230 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4231 | echo "configure:4232: checking for $ac_func" >&5 |
| 4232 | 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] | 4233 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4234 | else |
| 4235 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4236 | #line 4237 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4237 | #include "confdefs.h" |
| 4238 | /* System header to define __stub macros and hopefully few prototypes, |
| 4239 | which can conflict with char $ac_func(); below. */ |
| 4240 | #include <assert.h> |
| 4241 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4242 | /* We use char because int might match the return type of a gcc2 |
| 4243 | builtin and then its argument prototype would still apply. */ |
| 4244 | char $ac_func(); |
| 4245 | |
| 4246 | int main() { |
| 4247 | |
| 4248 | /* The GNU C library defines this for functions which it implements |
| 4249 | to always fail with ENOSYS. Some functions are actually named |
| 4250 | something starting with __ and the normal name is an alias. */ |
| 4251 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4252 | choke me |
| 4253 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4254 | $ac_func(); |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4255 | #endif |
| 4256 | |
| 4257 | ; return 0; } |
| 4258 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4259 | if { (eval echo configure:4260: \"$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] | 4260 | rm -rf conftest* |
| 4261 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4262 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4263 | echo "configure: failed program was:" >&5 |
| 4264 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4265 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4266 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4267 | fi |
| 4268 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4269 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4270 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4271 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4272 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4273 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4274 | cat >> confdefs.h <<EOF |
| 4275 | #define $ac_tr_func 1 |
| 4276 | EOF |
| 4277 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4278 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4279 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4280 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4281 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4282 | done |
| 4283 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4284 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4285 | for ac_func in getpgrp |
| 4286 | do |
| 4287 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4288 | echo "configure:4289: checking for $ac_func" >&5 |
| 4289 | 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] | 4290 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4291 | else |
| 4292 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4293 | #line 4294 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4294 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4295 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4296 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4297 | #include <assert.h> |
| 4298 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4299 | /* We use char because int might match the return type of a gcc2 |
| 4300 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4301 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4302 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4303 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4304 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4305 | /* The GNU C library defines this for functions which it implements |
| 4306 | to always fail with ENOSYS. Some functions are actually named |
| 4307 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4308 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4309 | choke me |
| 4310 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4311 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4312 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4313 | |
| 4314 | ; return 0; } |
| 4315 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4316 | if { (eval echo configure:4317: \"$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] | 4317 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4318 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4319 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4320 | echo "configure: failed program was:" >&5 |
| 4321 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4322 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4323 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4324 | fi |
| 4325 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4326 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4327 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4328 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4329 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4330 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4331 | cat >> confdefs.h <<EOF |
| 4332 | #define $ac_tr_func 1 |
| 4333 | EOF |
| 4334 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4335 | #line 4336 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4336 | #include "confdefs.h" |
| 4337 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4338 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4339 | getpgrp(0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4340 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4341 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4342 | if { (eval echo configure:4343: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4343 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4344 | cat >> confdefs.h <<\EOF |
| 4345 | #define GETPGRP_HAVE_ARG 1 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4346 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4347 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4348 | else |
| 4349 | echo "configure: failed program was:" >&5 |
| 4350 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4351 | fi |
| 4352 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4353 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4354 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4355 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4356 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4357 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4358 | for ac_func in setpgrp |
| 4359 | do |
| 4360 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4361 | echo "configure:4362: checking for $ac_func" >&5 |
| 4362 | 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] | 4363 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4364 | else |
| 4365 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4366 | #line 4367 "configure" |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4367 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4368 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4369 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4370 | #include <assert.h> |
| 4371 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4372 | /* We use char because int might match the return type of a gcc2 |
| 4373 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4374 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4375 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4376 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4377 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4378 | /* The GNU C library defines this for functions which it implements |
| 4379 | to always fail with ENOSYS. Some functions are actually named |
| 4380 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4381 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4382 | choke me |
| 4383 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4384 | $ac_func(); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4385 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4386 | |
| 4387 | ; return 0; } |
| 4388 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4389 | if { (eval echo configure:4390: \"$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] | 4390 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4391 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4392 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4393 | echo "configure: failed program was:" >&5 |
| 4394 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4395 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4396 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4397 | fi |
| 4398 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4399 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4400 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4401 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4402 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4403 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4404 | cat >> confdefs.h <<EOF |
| 4405 | #define $ac_tr_func 1 |
| 4406 | EOF |
| 4407 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4408 | #line 4409 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4409 | #include "confdefs.h" |
| 4410 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4411 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4412 | setpgrp(0,0); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4413 | ; return 0; } |
| 4414 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4415 | if { (eval echo configure:4416: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4416 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4417 | cat >> confdefs.h <<\EOF |
| 4418 | #define SETPGRP_HAVE_ARG 1 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4419 | EOF |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4420 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4421 | else |
| 4422 | echo "configure: failed program was:" >&5 |
| 4423 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4424 | fi |
| 4425 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4426 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4427 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4428 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4429 | done |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4430 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4431 | for ac_func in gettimeofday |
| 4432 | do |
| 4433 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4434 | echo "configure:4435: checking for $ac_func" >&5 |
| 4435 | 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] | 4436 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4437 | else |
| 4438 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4439 | #line 4440 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4440 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4441 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4442 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4443 | #include <assert.h> |
| 4444 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4445 | /* We use char because int might match the return type of a gcc2 |
| 4446 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4447 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4448 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4449 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4450 | |
| 4451 | /* The GNU C library defines this for functions which it implements |
| 4452 | to always fail with ENOSYS. Some functions are actually named |
| 4453 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4454 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4455 | choke me |
| 4456 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4457 | $ac_func(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4458 | #endif |
| 4459 | |
| 4460 | ; return 0; } |
| 4461 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4462 | if { (eval echo configure:4463: \"$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] | 4463 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4464 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4465 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4466 | echo "configure: failed program was:" >&5 |
| 4467 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4468 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4469 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4470 | fi |
| 4471 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4472 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4473 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4474 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4475 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4476 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4477 | cat >> confdefs.h <<EOF |
| 4478 | #define $ac_tr_func 1 |
| 4479 | EOF |
| 4480 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4481 | #line 4482 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4482 | #include "confdefs.h" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4483 | #include <sys/time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4484 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4485 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
| 4486 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4487 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4488 | if { (eval echo configure:4489: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4489 | : |
| 4490 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4491 | echo "configure: failed program was:" >&5 |
| 4492 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4493 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4494 | cat >> confdefs.h <<\EOF |
| 4495 | #define GETTIMEOFDAY_NO_TZ 1 |
| 4496 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4497 | |
| 4498 | fi |
| 4499 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4500 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4501 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4502 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4503 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4504 | |
| 4505 | |
| 4506 | # checks for structures |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4507 | echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4508 | echo "configure:4509: checking whether time.h and sys/time.h may both be included" >&5 |
| 4509 | if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4510 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4511 | else |
| 4512 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4513 | #line 4514 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4514 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4515 | #include <sys/types.h> |
| 4516 | #include <sys/time.h> |
| 4517 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4518 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4519 | struct tm *tp; |
| 4520 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4521 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4522 | if { (eval echo configure:4523: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4523 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4524 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4525 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4526 | echo "configure: failed program was:" >&5 |
| 4527 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4528 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4529 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4530 | fi |
| 4531 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4532 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4533 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4534 | echo "$ac_t""$ac_cv_header_time" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4535 | if test $ac_cv_header_time = yes; then |
| 4536 | cat >> confdefs.h <<\EOF |
| 4537 | #define TIME_WITH_SYS_TIME 1 |
| 4538 | EOF |
| 4539 | |
| 4540 | fi |
| 4541 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4542 | echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4543 | echo "configure:4544: checking whether struct tm is in sys/time.h or time.h" >&5 |
| 4544 | if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4545 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4546 | else |
| 4547 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4548 | #line 4549 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4549 | #include "confdefs.h" |
| 4550 | #include <sys/types.h> |
| 4551 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4552 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4553 | struct tm *tp; tp->tm_sec; |
| 4554 | ; return 0; } |
| 4555 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4556 | if { (eval echo configure:4557: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4557 | rm -rf conftest* |
| 4558 | ac_cv_struct_tm=time.h |
| 4559 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4560 | echo "configure: failed program was:" >&5 |
| 4561 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4562 | rm -rf conftest* |
| 4563 | ac_cv_struct_tm=sys/time.h |
| 4564 | fi |
| 4565 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4566 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4567 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4568 | echo "$ac_t""$ac_cv_struct_tm" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4569 | if test $ac_cv_struct_tm = sys/time.h; then |
| 4570 | cat >> confdefs.h <<\EOF |
| 4571 | #define TM_IN_SYS_TIME 1 |
| 4572 | EOF |
| 4573 | |
| 4574 | fi |
| 4575 | |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4576 | echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 |
| 4577 | echo "configure:4578: checking for tm_zone in struct tm" >&5 |
| 4578 | 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] | 4579 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4580 | else |
| 4581 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4582 | #line 4583 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4583 | #include "confdefs.h" |
| 4584 | #include <sys/types.h> |
| 4585 | #include <$ac_cv_struct_tm> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4586 | int main() { |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4587 | struct tm tm; tm.tm_zone; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4588 | ; return 0; } |
| 4589 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4590 | if { (eval echo configure:4591: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4591 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4592 | ac_cv_struct_tm_zone=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4593 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4594 | echo "configure: failed program was:" >&5 |
| 4595 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4596 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4597 | ac_cv_struct_tm_zone=no |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4598 | fi |
| 4599 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4600 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4601 | |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4602 | echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6 |
| 4603 | if test "$ac_cv_struct_tm_zone" = yes; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4604 | cat >> confdefs.h <<\EOF |
| 4605 | #define HAVE_TM_ZONE 1 |
| 4606 | EOF |
| 4607 | |
| 4608 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4609 | echo $ac_n "checking for tzname""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4610 | echo "configure:4611: checking for tzname" >&5 |
| 4611 | if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4612 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4613 | else |
| 4614 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4615 | #line 4616 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4616 | #include "confdefs.h" |
| 4617 | #include <time.h> |
| 4618 | #ifndef tzname /* For SGI. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4619 | extern char *tzname[]; /* RS6000 and others reject char **tzname. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4620 | #endif |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4621 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4622 | atoi(*tzname); |
| 4623 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4624 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4625 | if { (eval echo configure:4626: \"$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] | 4626 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4627 | ac_cv_var_tzname=yes |
| 4628 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4629 | echo "configure: failed program was:" >&5 |
| 4630 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4631 | rm -rf conftest* |
| 4632 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4633 | fi |
| 4634 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4635 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4636 | |
| 4637 | echo "$ac_t""$ac_cv_var_tzname" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4638 | if test $ac_cv_var_tzname = yes; then |
| 4639 | cat >> confdefs.h <<\EOF |
| 4640 | #define HAVE_TZNAME 1 |
| 4641 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4642 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4643 | fi |
| 4644 | fi |
| 4645 | |
| 4646 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4647 | echo $ac_n "checking for time.h that defines altzone""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4648 | echo "configure:4649: checking for time.h that defines altzone" >&5 |
| 4649 | 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] | 4650 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4651 | else |
| 4652 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4653 | #line 4654 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4654 | #include "confdefs.h" |
| 4655 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4656 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4657 | return altzone; |
| 4658 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4659 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4660 | if { (eval echo configure:4661: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4661 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4662 | ac_cv_header_time_altzone=yes |
| 4663 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4664 | echo "configure: failed program was:" >&5 |
| 4665 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4666 | rm -rf conftest* |
| 4667 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4668 | fi |
| 4669 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4670 | fi |
| 4671 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4672 | echo "$ac_t""$ac_cv_header_time_altzone" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4673 | if test $ac_cv_header_time_altzone = yes; then |
| 4674 | cat >> confdefs.h <<\EOF |
| 4675 | #define HAVE_ALTZONE 1 |
| 4676 | EOF |
| 4677 | |
| 4678 | fi |
| 4679 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4680 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4681 | echo $ac_n "checking whether sys/select.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4682 | echo "configure:4683: 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] | 4683 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4684 | #line 4685 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4685 | #include "confdefs.h" |
| 4686 | |
| 4687 | #include <sys/types.h> |
| 4688 | #include <sys/select.h> |
| 4689 | #include <sys/time.h> |
| 4690 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4691 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4692 | ; |
| 4693 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4694 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4695 | if { (eval echo configure:4696: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4696 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4697 | cat >> confdefs.h <<\EOF |
| 4698 | #define SYS_SELECT_WITH_SYS_TIME 1 |
| 4699 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4700 | was_it_defined=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4701 | else |
| 4702 | echo "configure: failed program was:" >&5 |
| 4703 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4704 | fi |
| 4705 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4706 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4707 | |
| 4708 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4709 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4710 | echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4711 | echo "configure:4712: checking whether char is unsigned" >&5 |
| 4712 | 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] | 4713 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4714 | else |
| 4715 | if test "$GCC" = yes; then |
| 4716 | # GCC predefines this symbol on systems where it applies. |
| 4717 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4718 | #line 4719 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4719 | #include "confdefs.h" |
| 4720 | #ifdef __CHAR_UNSIGNED__ |
| 4721 | yes |
| 4722 | #endif |
| 4723 | |
| 4724 | EOF |
| 4725 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 4726 | egrep "yes" >/dev/null 2>&1; then |
| 4727 | rm -rf conftest* |
| 4728 | ac_cv_c_char_unsigned=yes |
| 4729 | else |
| 4730 | rm -rf conftest* |
| 4731 | ac_cv_c_char_unsigned=no |
| 4732 | fi |
| 4733 | rm -f conftest* |
| 4734 | |
| 4735 | else |
| 4736 | if test "$cross_compiling" = yes; then |
| 4737 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 4738 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4739 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4740 | #line 4741 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4741 | #include "confdefs.h" |
| 4742 | /* volatile prevents gcc2 from optimizing the test away on sparcs. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4743 | #if !defined(__STDC__) || __STDC__ != 1 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4744 | #define volatile |
| 4745 | #endif |
| 4746 | main() { |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4747 | volatile char c = 255; exit(c < 0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4748 | } |
| 4749 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4750 | if { (eval echo configure:4751: \"$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] | 4751 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4752 | ac_cv_c_char_unsigned=yes |
| 4753 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4754 | echo "configure: failed program was:" >&5 |
| 4755 | cat conftest.$ac_ext >&5 |
| 4756 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4757 | ac_cv_c_char_unsigned=no |
| 4758 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4759 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4760 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4761 | |
| 4762 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4763 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4764 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4765 | echo "$ac_t""$ac_cv_c_char_unsigned" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4766 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
| 4767 | cat >> confdefs.h <<\EOF |
| 4768 | #define __CHAR_UNSIGNED__ 1 |
| 4769 | EOF |
| 4770 | |
| 4771 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4772 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4773 | echo $ac_n "checking for working const""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4774 | echo "configure:4775: checking for working const" >&5 |
| 4775 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4776 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4777 | else |
| 4778 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4779 | #line 4780 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4780 | #include "confdefs.h" |
| 4781 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4782 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4783 | |
| 4784 | /* Ultrix mips cc rejects this. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4785 | typedef int charset[2]; const charset x; |
| 4786 | /* SunOS 4.1.1 cc rejects this. */ |
| 4787 | char const *const *ccp; |
| 4788 | char **p; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4789 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 4790 | struct point {int x, y;}; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4791 | static struct point const zero = {0,0}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4792 | /* AIX XL C 1.02.0.0 rejects this. |
| 4793 | It does not let you subtract one const X* pointer from another in an arm |
| 4794 | of an if-expression whose if-part is not a constant expression */ |
| 4795 | const char *g = "string"; |
| 4796 | ccp = &g + (g ? g-g : 0); |
| 4797 | /* HPUX 7.0 cc rejects these. */ |
| 4798 | ++ccp; |
| 4799 | p = (char**) ccp; |
| 4800 | ccp = (char const *const *) p; |
| 4801 | { /* SCO 3.2v4 cc rejects this. */ |
| 4802 | char *t; |
| 4803 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
| 4804 | |
| 4805 | *t++ = 0; |
| 4806 | } |
| 4807 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4808 | int x[] = {25, 17}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4809 | const int *foo = &x[0]; |
| 4810 | ++foo; |
| 4811 | } |
| 4812 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 4813 | typedef const int *iptr; |
| 4814 | iptr p = 0; |
| 4815 | ++p; |
| 4816 | } |
| 4817 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 4818 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 4819 | struct s { int j; const int *ap[3]; }; |
| 4820 | struct s *b; b->j = 5; |
| 4821 | } |
| 4822 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 4823 | const int foo = 10; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4824 | } |
| 4825 | |
| 4826 | ; return 0; } |
| 4827 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4828 | if { (eval echo configure:4829: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4829 | rm -rf conftest* |
| 4830 | ac_cv_c_const=yes |
| 4831 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4832 | echo "configure: failed program was:" >&5 |
| 4833 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4834 | rm -rf conftest* |
| 4835 | ac_cv_c_const=no |
| 4836 | fi |
| 4837 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4838 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4839 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4840 | echo "$ac_t""$ac_cv_c_const" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4841 | if test $ac_cv_c_const = no; then |
| 4842 | cat >> confdefs.h <<\EOF |
| 4843 | #define const |
| 4844 | EOF |
| 4845 | |
| 4846 | fi |
| 4847 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4848 | echo $ac_n "checking for inline""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4849 | echo "configure:4850: checking for inline" >&5 |
| 4850 | if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4851 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4852 | else |
| 4853 | ac_cv_c_inline=no |
| 4854 | for ac_kw in inline __inline__ __inline; do |
| 4855 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4856 | #line 4857 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4857 | #include "confdefs.h" |
| 4858 | |
| 4859 | int main() { |
| 4860 | } $ac_kw foo() { |
| 4861 | ; return 0; } |
| 4862 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4863 | if { (eval echo configure:4864: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 4864 | rm -rf conftest* |
| 4865 | ac_cv_c_inline=$ac_kw; break |
| 4866 | else |
| 4867 | echo "configure: failed program was:" >&5 |
| 4868 | cat conftest.$ac_ext >&5 |
| 4869 | fi |
| 4870 | rm -f conftest* |
| 4871 | done |
| 4872 | |
| 4873 | fi |
| 4874 | |
| 4875 | echo "$ac_t""$ac_cv_c_inline" 1>&6 |
| 4876 | case "$ac_cv_c_inline" in |
| 4877 | inline | yes) ;; |
| 4878 | no) cat >> confdefs.h <<\EOF |
| 4879 | #define inline |
| 4880 | EOF |
| 4881 | ;; |
| 4882 | *) cat >> confdefs.h <<EOF |
| 4883 | #define inline $ac_cv_c_inline |
| 4884 | EOF |
| 4885 | ;; |
| 4886 | esac |
| 4887 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4888 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4889 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4890 | echo $ac_n "checking for working volatile""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4891 | echo "configure:4892: checking for working volatile" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4892 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4893 | #line 4894 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4894 | #include "confdefs.h" |
| 4895 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4896 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4897 | volatile int x; x = 0; |
| 4898 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4899 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4900 | if { (eval echo configure:4901: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4901 | rm -rf conftest* |
| 4902 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4903 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4904 | echo "configure: failed program was:" >&5 |
| 4905 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4906 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4907 | cat >> confdefs.h <<\EOF |
| 4908 | #define volatile |
| 4909 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4910 | |
| 4911 | fi |
| 4912 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4913 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4914 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4915 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4916 | echo $ac_n "checking for working signed char""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4917 | echo "configure:4918: checking for working signed char" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4918 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4919 | #line 4920 "configure" |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4920 | #include "confdefs.h" |
| 4921 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4922 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4923 | signed char c; |
| 4924 | ; return 0; } |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4925 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4926 | if { (eval echo configure:4927: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4927 | rm -rf conftest* |
| 4928 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4929 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4930 | echo "configure: failed program was:" >&5 |
| 4931 | cat conftest.$ac_ext >&5 |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 4932 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4933 | cat >> confdefs.h <<\EOF |
| 4934 | #define signed |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4935 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4936 | |
| 4937 | fi |
| 4938 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4939 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4940 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4941 | have_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4942 | echo $ac_n "checking for prototypes""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4943 | echo "configure:4944: checking for prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4944 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4945 | #line 4946 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4946 | #include "confdefs.h" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4947 | int foo(int x) { return 0; } |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4948 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4949 | return foo(10); |
| 4950 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4951 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4952 | if { (eval echo configure:4953: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4953 | rm -rf conftest* |
| 4954 | cat >> confdefs.h <<\EOF |
| 4955 | #define HAVE_PROTOTYPES 1 |
| 4956 | EOF |
| 4957 | have_prototypes=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4958 | else |
| 4959 | echo "configure: failed program was:" >&5 |
| 4960 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4961 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4962 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4963 | echo "$ac_t""$have_prototypes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4964 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4965 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4966 | echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4967 | echo "configure:4968: checking for variable length prototypes and stdarg.h" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4968 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4969 | #line 4970 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4970 | #include "confdefs.h" |
| 4971 | |
| 4972 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 4973 | int foo(int x, ...) { |
| 4974 | va_list va; |
| 4975 | va_start(va, x); |
| 4976 | va_arg(va, int); |
| 4977 | va_arg(va, char *); |
| 4978 | va_arg(va, double); |
| 4979 | return 0; |
| 4980 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4981 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4982 | int main() { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 4983 | return foo(10, "", 3.14); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4984 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4985 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 4986 | if { (eval echo configure:4987: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4987 | rm -rf conftest* |
| 4988 | cat >> confdefs.h <<\EOF |
| 4989 | #define HAVE_STDARG_PROTOTYPES 1 |
| 4990 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4991 | works=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4992 | else |
| 4993 | echo "configure: failed program was:" >&5 |
| 4994 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4995 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4996 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4997 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4998 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4999 | if test "$have_prototypes" = yes; then |
| 5000 | bad_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5001 | echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5002 | echo "configure:5003: checking for bad exec* prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5003 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5004 | #line 5005 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5005 | #include "confdefs.h" |
| 5006 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5007 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5008 | char **t;execve("@",t,t); |
| 5009 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5010 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5011 | if { (eval echo configure:5012: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5012 | : |
| 5013 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5014 | echo "configure: failed program was:" >&5 |
| 5015 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5016 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5017 | cat >> confdefs.h <<\EOF |
| 5018 | #define BAD_EXEC_PROTOTYPES 1 |
| 5019 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5020 | bad_prototypes=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5021 | fi |
| 5022 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5023 | echo "$ac_t""$bad_prototypes" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5024 | fi |
| 5025 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5026 | bad_forward=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5027 | echo $ac_n "checking for bad static forward""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5028 | echo "configure:5029: checking for bad static forward" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5029 | if test "$cross_compiling" = yes; then |
| 5030 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5031 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5032 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5033 | #line 5034 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5034 | #include "confdefs.h" |
| 5035 | |
| 5036 | struct s { int a; int b; }; |
| 5037 | static struct s foo; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5038 | int foobar() { |
| 5039 | static int random; |
| 5040 | random = (int) &foo; |
| 5041 | return random; |
| 5042 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5043 | static struct s foo = { 1, 2 }; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5044 | main() { |
| 5045 | exit(!((int)&foo == foobar())); |
| 5046 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5047 | |
| 5048 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5049 | if { (eval echo configure:5050: \"$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] | 5050 | then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5051 | : |
| 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 |
| 5055 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5056 | cat >> confdefs.h <<\EOF |
| 5057 | #define BAD_STATIC_FORWARD 1 |
| 5058 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5059 | bad_forward=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5060 | fi |
| 5061 | rm -fr conftest* |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5062 | fi |
| 5063 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5064 | echo "$ac_t""$bad_forward" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5065 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5066 | va_list_is_array=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5067 | echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5068 | echo "configure:5069: checking whether va_list is an array" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5069 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5070 | #line 5071 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5071 | #include "confdefs.h" |
| 5072 | |
| 5073 | #ifdef HAVE_STDARG_PROTOTYPES |
| 5074 | #include <stdarg.h> |
| 5075 | #else |
| 5076 | #include <varargs.h> |
| 5077 | #endif |
| 5078 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5079 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5080 | va_list list1, list2; list1 = list2; |
| 5081 | ; return 0; } |
| 5082 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5083 | if { (eval echo configure:5084: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5084 | : |
| 5085 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5086 | echo "configure: failed program was:" >&5 |
| 5087 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5088 | rm -rf conftest* |
| 5089 | cat >> confdefs.h <<\EOF |
| 5090 | #define VA_LIST_IS_ARRAY 1 |
| 5091 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5092 | va_list_is_array=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5093 | fi |
| 5094 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5095 | echo "$ac_t""$va_list_is_array" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5096 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5097 | # sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-( |
| 5098 | echo $ac_n "checking for gethostbyname_r""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5099 | echo "configure:5100: checking for gethostbyname_r" >&5 |
| 5100 | 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] | 5101 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5102 | else |
| 5103 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5104 | #line 5105 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5105 | #include "confdefs.h" |
| 5106 | /* System header to define __stub macros and hopefully few prototypes, |
| 5107 | which can conflict with char gethostbyname_r(); below. */ |
| 5108 | #include <assert.h> |
| 5109 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5110 | /* We use char because int might match the return type of a gcc2 |
| 5111 | builtin and then its argument prototype would still apply. */ |
| 5112 | char gethostbyname_r(); |
| 5113 | |
| 5114 | int main() { |
| 5115 | |
| 5116 | /* The GNU C library defines this for functions which it implements |
| 5117 | to always fail with ENOSYS. Some functions are actually named |
| 5118 | something starting with __ and the normal name is an alias. */ |
| 5119 | #if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r) |
| 5120 | choke me |
| 5121 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5122 | gethostbyname_r(); |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5123 | #endif |
| 5124 | |
| 5125 | ; return 0; } |
| 5126 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5127 | if { (eval echo configure:5128: \"$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] | 5128 | rm -rf conftest* |
| 5129 | eval "ac_cv_func_gethostbyname_r=yes" |
| 5130 | else |
| 5131 | echo "configure: failed program was:" >&5 |
| 5132 | cat conftest.$ac_ext >&5 |
| 5133 | rm -rf conftest* |
| 5134 | eval "ac_cv_func_gethostbyname_r=no" |
| 5135 | fi |
| 5136 | rm -f conftest* |
| 5137 | fi |
| 5138 | |
| 5139 | if eval "test \"`echo '$ac_cv_func_'gethostbyname_r`\" = yes"; then |
| 5140 | echo "$ac_t""yes" 1>&6 |
| 5141 | |
| 5142 | cat >> confdefs.h <<\EOF |
| 5143 | #define HAVE_GETHOSTBYNAME_R 1 |
| 5144 | EOF |
| 5145 | |
| 5146 | echo $ac_n "checking gethostbyname_r with 6 args""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5147 | echo "configure:5148: checking gethostbyname_r with 6 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5148 | OLD_CFLAGS=$CFLAGS |
| 5149 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
| 5150 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5151 | #line 5152 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5152 | #include "confdefs.h" |
| 5153 | |
| 5154 | # include <netdb.h> |
| 5155 | |
| 5156 | int main() { |
| 5157 | |
| 5158 | char *name; |
| 5159 | struct hostent *he, *res; |
| 5160 | char buffer[2048]; |
| 5161 | int buflen = 2048; |
| 5162 | int h_errnop; |
| 5163 | |
| 5164 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
| 5165 | |
| 5166 | ; return 0; } |
| 5167 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5168 | if { (eval echo configure:5169: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5169 | rm -rf conftest* |
| 5170 | |
| 5171 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 5172 | #define HAVE_GETHOSTBYNAME_R 1 |
| 5173 | EOF |
| 5174 | |
| 5175 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5176 | #define HAVE_GETHOSTBYNAME_R_6_ARG 1 |
| 5177 | EOF |
| 5178 | |
| 5179 | echo "$ac_t""yes" 1>&6 |
| 5180 | |
| 5181 | else |
| 5182 | echo "configure: failed program was:" >&5 |
| 5183 | cat conftest.$ac_ext >&5 |
| 5184 | rm -rf conftest* |
| 5185 | |
| 5186 | echo "$ac_t""no" 1>&6 |
| 5187 | echo $ac_n "checking gethostbyname_r with 5 args""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5188 | echo "configure:5189: checking gethostbyname_r with 5 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5189 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5190 | #line 5191 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5191 | #include "confdefs.h" |
| 5192 | |
| 5193 | # include <netdb.h> |
| 5194 | |
| 5195 | int main() { |
| 5196 | |
| 5197 | char *name; |
| 5198 | struct hostent *he; |
| 5199 | char buffer[2048]; |
| 5200 | int buflen = 2048; |
| 5201 | int h_errnop; |
| 5202 | |
| 5203 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
| 5204 | |
| 5205 | ; return 0; } |
| 5206 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5207 | if { (eval echo configure:5208: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5208 | rm -rf conftest* |
| 5209 | |
| 5210 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 5211 | #define HAVE_GETHOSTBYNAME_R 1 |
| 5212 | EOF |
| 5213 | |
| 5214 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5215 | #define HAVE_GETHOSTBYNAME_R_5_ARG 1 |
| 5216 | EOF |
| 5217 | |
| 5218 | echo "$ac_t""yes" 1>&6 |
| 5219 | |
| 5220 | else |
| 5221 | echo "configure: failed program was:" >&5 |
| 5222 | cat conftest.$ac_ext >&5 |
| 5223 | rm -rf conftest* |
| 5224 | |
| 5225 | echo "$ac_t""no" 1>&6 |
| 5226 | echo $ac_n "checking gethostbyname_r with 3 args""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5227 | echo "configure:5228: checking gethostbyname_r with 3 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5228 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5229 | #line 5230 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5230 | #include "confdefs.h" |
| 5231 | |
| 5232 | # include <netdb.h> |
| 5233 | |
| 5234 | int main() { |
| 5235 | |
| 5236 | char *name; |
| 5237 | struct hostent *he; |
| 5238 | struct hostent_data data; |
| 5239 | |
| 5240 | (void) gethostbyname_r(name, he, &data); |
| 5241 | |
| 5242 | ; return 0; } |
| 5243 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5244 | if { (eval echo configure:5245: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5245 | rm -rf conftest* |
| 5246 | |
| 5247 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 5248 | #define HAVE_GETHOSTBYNAME_R 1 |
| 5249 | EOF |
| 5250 | |
| 5251 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5252 | #define HAVE_GETHOSTBYNAME_R_3_ARG 1 |
| 5253 | EOF |
| 5254 | |
| 5255 | echo "$ac_t""yes" 1>&6 |
| 5256 | |
| 5257 | else |
| 5258 | echo "configure: failed program was:" >&5 |
| 5259 | cat conftest.$ac_ext >&5 |
| 5260 | rm -rf conftest* |
| 5261 | |
| 5262 | echo "$ac_t""no" 1>&6 |
| 5263 | |
| 5264 | fi |
| 5265 | rm -f conftest* |
| 5266 | |
| 5267 | fi |
| 5268 | rm -f conftest* |
| 5269 | |
| 5270 | fi |
| 5271 | rm -f conftest* |
| 5272 | CFLAGS=$OLD_CFLAGS |
| 5273 | |
| 5274 | else |
| 5275 | echo "$ac_t""no" 1>&6 |
| 5276 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5277 | for ac_func in gethostbyname |
| 5278 | do |
| 5279 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5280 | echo "configure:5281: checking for $ac_func" >&5 |
| 5281 | 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] | 5282 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5283 | else |
| 5284 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5285 | #line 5286 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5286 | #include "confdefs.h" |
| 5287 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5288 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5289 | #include <assert.h> |
| 5290 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5291 | /* We use char because int might match the return type of a gcc2 |
| 5292 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5293 | char $ac_func(); |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5294 | |
| 5295 | int main() { |
| 5296 | |
| 5297 | /* The GNU C library defines this for functions which it implements |
| 5298 | to always fail with ENOSYS. Some functions are actually named |
| 5299 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5300 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5301 | choke me |
| 5302 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5303 | $ac_func(); |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5304 | #endif |
| 5305 | |
| 5306 | ; return 0; } |
| 5307 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5308 | if { (eval echo configure:5309: \"$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] | 5309 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5310 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5311 | else |
| 5312 | echo "configure: failed program was:" >&5 |
| 5313 | cat conftest.$ac_ext >&5 |
| 5314 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5315 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5316 | fi |
| 5317 | rm -f conftest* |
| 5318 | fi |
| 5319 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5320 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5321 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5322 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 5323 | cat >> confdefs.h <<EOF |
| 5324 | #define $ac_tr_func 1 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5325 | EOF |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5326 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5327 | else |
| 5328 | echo "$ac_t""no" 1>&6 |
| 5329 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5330 | done |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5331 | |
| 5332 | |
| 5333 | fi |
| 5334 | |
| 5335 | |
| 5336 | |
| 5337 | |
| 5338 | |
| 5339 | |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 5340 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5341 | # checks for system services |
| 5342 | # (none yet) |
| 5343 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5344 | # Linux requires this for correct f.p. operations |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 5345 | echo $ac_n "checking for __fpu_control""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5346 | echo "configure:5347: checking for __fpu_control" >&5 |
| 5347 | if eval "test \"`echo '$''{'ac_cv_func___fpu_control'+set}'`\" = set"; then |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 5348 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5349 | else |
| 5350 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5351 | #line 5352 "configure" |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 5352 | #include "confdefs.h" |
| 5353 | /* System header to define __stub macros and hopefully few prototypes, |
| 5354 | which can conflict with char __fpu_control(); below. */ |
| 5355 | #include <assert.h> |
| 5356 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5357 | /* We use char because int might match the return type of a gcc2 |
| 5358 | builtin and then its argument prototype would still apply. */ |
| 5359 | char __fpu_control(); |
| 5360 | |
| 5361 | int main() { |
| 5362 | |
| 5363 | /* The GNU C library defines this for functions which it implements |
| 5364 | to always fail with ENOSYS. Some functions are actually named |
| 5365 | something starting with __ and the normal name is an alias. */ |
| 5366 | #if defined (__stub___fpu_control) || defined (__stub_____fpu_control) |
| 5367 | choke me |
| 5368 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5369 | __fpu_control(); |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 5370 | #endif |
| 5371 | |
| 5372 | ; return 0; } |
| 5373 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5374 | if { (eval echo configure:5375: \"$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] | 5375 | rm -rf conftest* |
| 5376 | eval "ac_cv_func___fpu_control=yes" |
| 5377 | else |
| 5378 | echo "configure: failed program was:" >&5 |
| 5379 | cat conftest.$ac_ext >&5 |
| 5380 | rm -rf conftest* |
| 5381 | eval "ac_cv_func___fpu_control=no" |
| 5382 | fi |
| 5383 | rm -f conftest* |
| 5384 | fi |
| 5385 | |
| 5386 | if eval "test \"`echo '$ac_cv_func_'__fpu_control`\" = yes"; then |
| 5387 | echo "$ac_t""yes" 1>&6 |
| 5388 | : |
| 5389 | else |
| 5390 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5391 | echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5392 | echo "configure:5393: checking for __fpu_control in -lieee" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5393 | ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'` |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5394 | 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] | 5395 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5396 | else |
| 5397 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5398 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5399 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5400 | #line 5401 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5401 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5402 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5403 | /* We use char because int might match the return type of a gcc2 |
| 5404 | builtin and then its argument prototype would still apply. */ |
| 5405 | char __fpu_control(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5406 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5407 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5408 | __fpu_control() |
| 5409 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5410 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5411 | if { (eval echo configure:5412: \"$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] | 5412 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5413 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5414 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5415 | echo "configure: failed program was:" >&5 |
| 5416 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5417 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5418 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5419 | fi |
| 5420 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5421 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5422 | |
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 | 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] | 5425 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5426 | ac_tr_lib=HAVE_LIB`echo ieee | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 5427 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5428 | cat >> confdefs.h <<EOF |
| 5429 | #define $ac_tr_lib 1 |
| 5430 | EOF |
| 5431 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5432 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5433 | |
| 5434 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5435 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5436 | fi |
| 5437 | |
| 5438 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 5439 | fi |
| 5440 | |
| 5441 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5442 | # Check for --with-fpectl |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5443 | echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5444 | echo "configure:5445: checking for --with-fpectl" >&5 |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5445 | # Check whether --with-fpectl or --without-fpectl was given. |
| 5446 | if test "${with_fpectl+set}" = set; then |
| 5447 | withval="$with_fpectl" |
| 5448 | |
| 5449 | if test "$withval" != no |
| 5450 | then cat >> confdefs.h <<\EOF |
| 5451 | #define WANT_SIGFPE_HANDLER 1 |
| 5452 | EOF |
| 5453 | echo "$ac_t""yes" 1>&6 |
| 5454 | else echo "$ac_t""no" 1>&6 |
| 5455 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5456 | else |
| 5457 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5458 | fi |
| 5459 | |
| 5460 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5461 | # check for --with-libm=... |
| 5462 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 5463 | case $ac_sys_system in |
| 5464 | next) ;; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 5465 | BeOS) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 5466 | *) LIBM=-lm |
| 5467 | esac |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5468 | echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5469 | echo "configure:5470: checking for --with-libm=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5470 | # Check whether --with-libm or --without-libm was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5471 | if test "${with_libm+set}" = set; then |
| 5472 | withval="$with_libm" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5473 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5474 | if test "$withval" = no |
| 5475 | then LIBM= |
| 5476 | echo "$ac_t""force LIBM empty" 1>&6 |
| 5477 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5478 | then LIBM=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5479 | echo "$ac_t""set LIBM=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5480 | 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] | 5481 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5482 | else |
| 5483 | echo "$ac_t""default LIBM=\"$LIBM\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5484 | fi |
| 5485 | |
| 5486 | |
| 5487 | # check for --with-libc=... |
| 5488 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5489 | echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5490 | echo "configure:5491: checking for --with-libc=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5491 | # Check whether --with-libc or --without-libc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5492 | if test "${with_libc+set}" = set; then |
| 5493 | withval="$with_libc" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5494 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5495 | if test "$withval" = no |
| 5496 | then LIBC= |
| 5497 | echo "$ac_t""force LIBC empty" 1>&6 |
| 5498 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5499 | then LIBC=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5500 | echo "$ac_t""set LIBC=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5501 | 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] | 5502 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 5503 | else |
| 5504 | echo "$ac_t""default LIBC=\"$LIBC\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5505 | fi |
| 5506 | |
| 5507 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 5508 | # check for hypot() in math library |
| 5509 | LIBS_SAVE=$LIBS |
| 5510 | LIBS="$LIBS $LIBM" |
| 5511 | for ac_func in hypot |
| 5512 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5513 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5514 | echo "configure:5515: checking for $ac_func" >&5 |
| 5515 | 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] | 5516 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 5517 | else |
| 5518 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5519 | #line 5520 "configure" |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 5520 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5521 | /* System header to define __stub macros and hopefully few prototypes, |
| 5522 | which can conflict with char $ac_func(); below. */ |
| 5523 | #include <assert.h> |
| 5524 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5525 | /* We use char because int might match the return type of a gcc2 |
| 5526 | builtin and then its argument prototype would still apply. */ |
| 5527 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5528 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5529 | int main() { |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 5530 | |
| 5531 | /* The GNU C library defines this for functions which it implements |
| 5532 | to always fail with ENOSYS. Some functions are actually named |
| 5533 | something starting with __ and the normal name is an alias. */ |
| 5534 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 5535 | choke me |
| 5536 | #else |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5537 | $ac_func(); |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 5538 | #endif |
| 5539 | |
| 5540 | ; return 0; } |
| 5541 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5542 | if { (eval echo configure:5543: \"$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] | 5543 | rm -rf conftest* |
| 5544 | eval "ac_cv_func_$ac_func=yes" |
| 5545 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5546 | echo "configure: failed program was:" >&5 |
| 5547 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 5548 | rm -rf conftest* |
| 5549 | eval "ac_cv_func_$ac_func=no" |
| 5550 | fi |
| 5551 | rm -f conftest* |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 5552 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5553 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 5554 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 5555 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5556 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 5557 | cat >> confdefs.h <<EOF |
| 5558 | #define $ac_tr_func 1 |
| 5559 | EOF |
| 5560 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 5561 | else |
| 5562 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 5563 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 5564 | fi |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 5565 | done |
| 5566 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5567 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 5568 | LIBS=$LIBS_SAVE |
| 5569 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5570 | # check for getopt |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5571 | echo $ac_n "checking for genuine getopt""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5572 | echo "configure:5573: checking for genuine getopt" >&5 |
| 5573 | if eval "test \"`echo '$''{'ac_cv_func_getopt'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5574 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5575 | else |
| 5576 | if test "$cross_compiling" = yes; then |
| 5577 | ac_cv_func_getopt=no |
| 5578 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5579 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5580 | #line 5581 "configure" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5581 | #include "confdefs.h" |
| 5582 | #include <stdio.h> |
| 5583 | extern int optind, opterr, getopt(); |
| 5584 | extern char* optarg; |
| 5585 | int main() { |
| 5586 | char* av[] = { "testprog", "parameter", "-fFlag", NULL }; |
| 5587 | opterr = 0; |
| 5588 | if (getopt(3, av, "f:") == 'f') { exit(1); } |
| 5589 | exit(0); |
| 5590 | } |
| 5591 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5592 | if { (eval echo configure:5593: \"$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] | 5593 | then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5594 | ac_cv_func_getopt=yes |
| 5595 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5596 | echo "configure: failed program was:" >&5 |
| 5597 | cat conftest.$ac_ext >&5 |
| 5598 | rm -fr conftest* |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5599 | ac_cv_func_getopt=no |
| 5600 | fi |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5601 | rm -fr conftest* |
| 5602 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5603 | |
| 5604 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5605 | echo "$ac_t""$ac_cv_func_getopt" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5606 | test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o" |
| 5607 | |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 5608 | # check whether malloc(0) returns NULL or not |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 5609 | echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5610 | echo "configure:5611: checking what malloc(0) returns" >&5 |
| 5611 | if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 5612 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5613 | else |
| 5614 | if test "$cross_compiling" = yes; then |
| 5615 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5616 | else |
| 5617 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5618 | #line 5619 "configure" |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 5619 | #include "confdefs.h" |
| 5620 | #include <stdio.h> |
| 5621 | #ifdef HAVE_STDLIB |
| 5622 | #include <stdlib.h> |
| 5623 | #else |
| 5624 | char *malloc(), *realloc(); |
| 5625 | int *free(); |
| 5626 | #endif |
| 5627 | main() { |
| 5628 | char *p; |
| 5629 | p = malloc(0); |
| 5630 | if (p == NULL) exit(1); |
| 5631 | p = realloc(p, 0); |
| 5632 | if (p == NULL) exit(1); |
| 5633 | free(p); |
| 5634 | exit(0); |
| 5635 | } |
| 5636 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5637 | if { (eval echo configure:5638: \"$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] | 5638 | then |
| 5639 | ac_cv_malloc_zero=nonnull |
| 5640 | else |
| 5641 | echo "configure: failed program was:" >&5 |
| 5642 | cat conftest.$ac_ext >&5 |
| 5643 | rm -fr conftest* |
| 5644 | ac_cv_malloc_zero=null |
| 5645 | fi |
| 5646 | rm -fr conftest* |
| 5647 | fi |
| 5648 | |
| 5649 | fi |
| 5650 | |
| 5651 | echo "$ac_t""$ac_cv_malloc_zero" 1>&6 |
| 5652 | if test "$ac_cv_malloc_zero" = null |
| 5653 | then |
| 5654 | cat >> confdefs.h <<\EOF |
| 5655 | #define MALLOC_ZERO_RETURNS_NULL 1 |
| 5656 | EOF |
| 5657 | |
| 5658 | fi |
| 5659 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5660 | # check for wchar.h |
| 5661 | ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'` |
| 5662 | echo $ac_n "checking for wchar.h""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5663 | echo "configure:5664: checking for wchar.h" >&5 |
| 5664 | 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] | 5665 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5666 | else |
| 5667 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5668 | #line 5669 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5669 | #include "confdefs.h" |
| 5670 | #include <wchar.h> |
| 5671 | EOF |
| 5672 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5673 | { (eval echo configure:5674: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5674 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 5675 | if test -z "$ac_err"; then |
| 5676 | rm -rf conftest* |
| 5677 | eval "ac_cv_header_$ac_safe=yes" |
| 5678 | else |
| 5679 | echo "$ac_err" >&5 |
| 5680 | echo "configure: failed program was:" >&5 |
| 5681 | cat conftest.$ac_ext >&5 |
| 5682 | rm -rf conftest* |
| 5683 | eval "ac_cv_header_$ac_safe=no" |
| 5684 | fi |
| 5685 | rm -f conftest* |
| 5686 | fi |
| 5687 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 5688 | echo "$ac_t""yes" 1>&6 |
| 5689 | cat >> confdefs.h <<\EOF |
| 5690 | #define HAVE_WCHAR_H 1 |
| 5691 | EOF |
| 5692 | wchar_h="yes" |
| 5693 | else |
| 5694 | echo "$ac_t""no" 1>&6 |
| 5695 | wchar_h="no" |
| 5696 | |
| 5697 | fi |
| 5698 | |
| 5699 | |
| 5700 | # check for usable wchar_t |
| 5701 | usable_wchar_t="unkown" |
| 5702 | echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5703 | echo "configure:5704: checking for usable wchar_t" >&5 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5704 | if test "$cross_compiling" = yes; then |
| 5705 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5706 | else |
| 5707 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5708 | #line 5709 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5709 | #include "confdefs.h" |
| 5710 | |
| 5711 | #include "wchar.h" |
| 5712 | #include "wctype.h" |
| 5713 | main() { |
| 5714 | wchar_t s; |
| 5715 | if (sizeof(s) == 2) |
| 5716 | exit(0); |
| 5717 | else |
| 5718 | exit(1); |
| 5719 | } |
| 5720 | |
| 5721 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5722 | if { (eval echo configure:5723: \"$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] | 5723 | then |
| 5724 | cat >> confdefs.h <<\EOF |
| 5725 | #define HAVE_USABLE_WCHAR_T 1 |
| 5726 | EOF |
| 5727 | usable_wchar_t="yes" |
| 5728 | else |
| 5729 | echo "configure: failed program was:" >&5 |
| 5730 | cat conftest.$ac_ext >&5 |
| 5731 | rm -fr conftest* |
| 5732 | usable_wchar_t="no" |
| 5733 | fi |
| 5734 | rm -fr conftest* |
| 5735 | fi |
| 5736 | |
| 5737 | echo "$ac_t""$usable_wchar_t" 1>&6 |
| 5738 | |
| 5739 | # check for endianness |
| 5740 | echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5741 | echo "configure:5742: checking whether byte ordering is bigendian" >&5 |
| 5742 | if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5743 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5744 | else |
| 5745 | ac_cv_c_bigendian=unknown |
| 5746 | # See if sys/param.h defines the BYTE_ORDER macro. |
| 5747 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5748 | #line 5749 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5749 | #include "confdefs.h" |
| 5750 | #include <sys/types.h> |
| 5751 | #include <sys/param.h> |
| 5752 | int main() { |
| 5753 | |
| 5754 | #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN |
| 5755 | bogus endian macros |
| 5756 | #endif |
| 5757 | ; return 0; } |
| 5758 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5759 | if { (eval echo configure:5760: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5760 | rm -rf conftest* |
| 5761 | # It does; now see whether it defined to BIG_ENDIAN or not. |
| 5762 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5763 | #line 5764 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5764 | #include "confdefs.h" |
| 5765 | #include <sys/types.h> |
| 5766 | #include <sys/param.h> |
| 5767 | int main() { |
| 5768 | |
| 5769 | #if BYTE_ORDER != BIG_ENDIAN |
| 5770 | not big endian |
| 5771 | #endif |
| 5772 | ; return 0; } |
| 5773 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5774 | if { (eval echo configure:5775: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5775 | rm -rf conftest* |
| 5776 | ac_cv_c_bigendian=yes |
| 5777 | else |
| 5778 | echo "configure: failed program was:" >&5 |
| 5779 | cat conftest.$ac_ext >&5 |
| 5780 | rm -rf conftest* |
| 5781 | ac_cv_c_bigendian=no |
| 5782 | fi |
| 5783 | rm -f conftest* |
| 5784 | else |
| 5785 | echo "configure: failed program was:" >&5 |
| 5786 | cat conftest.$ac_ext >&5 |
| 5787 | fi |
| 5788 | rm -f conftest* |
| 5789 | if test $ac_cv_c_bigendian = unknown; then |
| 5790 | if test "$cross_compiling" = yes; then |
| 5791 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5792 | else |
| 5793 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5794 | #line 5795 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 5795 | #include "confdefs.h" |
| 5796 | main () { |
| 5797 | /* Are we little or big endian? From Harbison&Steele. */ |
| 5798 | union |
| 5799 | { |
| 5800 | long l; |
| 5801 | char c[sizeof (long)]; |
| 5802 | } u; |
| 5803 | u.l = 1; |
| 5804 | exit (u.c[sizeof (long) - 1] == 1); |
| 5805 | } |
| 5806 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5807 | if { (eval echo configure:5808: \"$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] | 5808 | then |
| 5809 | ac_cv_c_bigendian=no |
| 5810 | else |
| 5811 | echo "configure: failed program was:" >&5 |
| 5812 | cat conftest.$ac_ext >&5 |
| 5813 | rm -fr conftest* |
| 5814 | ac_cv_c_bigendian=yes |
| 5815 | fi |
| 5816 | rm -fr conftest* |
| 5817 | fi |
| 5818 | |
| 5819 | fi |
| 5820 | fi |
| 5821 | |
| 5822 | echo "$ac_t""$ac_cv_c_bigendian" 1>&6 |
| 5823 | if test $ac_cv_c_bigendian = yes; then |
| 5824 | cat >> confdefs.h <<\EOF |
| 5825 | #define WORDS_BIGENDIAN 1 |
| 5826 | EOF |
| 5827 | |
| 5828 | fi |
| 5829 | |
| 5830 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 5831 | # Check whether right shifting a negative integer extends the sign bit |
| 5832 | # or fills with zeros (like the Cray J90, according to Tim Peters). |
| 5833 | echo $ac_n "checking whether right shift extends the sign bit""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5834 | echo "configure:5835: checking whether right shift extends the sign bit" >&5 |
| 5835 | if eval "test \"`echo '$''{'ac_cv_rshift_extends_sign'+set}'`\" = set"; then |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 5836 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5837 | else |
| 5838 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 5839 | if test "$cross_compiling" = yes; then |
| 5840 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5841 | else |
| 5842 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5843 | #line 5844 "configure" |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 5844 | #include "confdefs.h" |
| 5845 | |
| 5846 | int main() |
| 5847 | { |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 5848 | exit(((-1)>>3 == -1) ? 0 : 1); |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 5849 | } |
| 5850 | |
| 5851 | EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5852 | if { (eval echo configure:5853: \"$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] | 5853 | then |
| 5854 | ac_cv_rshift_extends_sign=yes |
| 5855 | else |
| 5856 | echo "configure: failed program was:" >&5 |
| 5857 | cat conftest.$ac_ext >&5 |
| 5858 | rm -fr conftest* |
| 5859 | ac_cv_rshift_extends_sign=no |
| 5860 | fi |
| 5861 | rm -fr conftest* |
| 5862 | fi |
| 5863 | |
| 5864 | fi |
| 5865 | |
| 5866 | echo "$ac_t""$ac_cv_rshift_extends_sign" 1>&6 |
| 5867 | if test "$ac_cv_rshift_extends_sign" = no |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 5868 | then |
| 5869 | cat >> confdefs.h <<\EOF |
| 5870 | #define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1 |
| 5871 | EOF |
| 5872 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 5873 | fi |
| 5874 | |
| 5875 | |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 5876 | # THIS MUST BE LAST, IT CAN BREAK OTHER TESTS! |
| 5877 | # Add sys/socket.h to confdefs.h |
| 5878 | cat >> confdefs.h <<\EOF |
| 5879 | #ifdef HAVE_SYS_SOCKET_H |
| 5880 | #include <sys/socket.h> |
| 5881 | #endif |
| 5882 | EOF |
| 5883 | echo $ac_n "checking for socklen_t""... $ac_c" 1>&6 |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5884 | echo "configure:5885: checking for socklen_t" >&5 |
| 5885 | 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] | 5886 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5887 | else |
| 5888 | cat > conftest.$ac_ext <<EOF |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5889 | #line 5890 "configure" |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 5890 | #include "confdefs.h" |
| 5891 | #include <sys/types.h> |
| 5892 | #if STDC_HEADERS |
| 5893 | #include <stdlib.h> |
| 5894 | #include <stddef.h> |
| 5895 | #endif |
| 5896 | EOF |
| 5897 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 5898 | egrep "(^|[^a-zA-Z_0-9])socklen_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
| 5899 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5900 | ac_cv_type_socklen_t=yes |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 5901 | else |
| 5902 | rm -rf conftest* |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5903 | ac_cv_type_socklen_t=no |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 5904 | fi |
| 5905 | rm -f conftest* |
| 5906 | |
| 5907 | fi |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 5908 | echo "$ac_t""$ac_cv_type_socklen_t" 1>&6 |
| 5909 | if test $ac_cv_type_socklen_t = no; then |
| 5910 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 5911 | #define socklen_t int |
| 5912 | EOF |
| 5913 | |
| 5914 | fi |
| 5915 | |
| 5916 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5917 | # generate output files |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5918 | trap '' 1 2 15 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5919 | cat > confcache <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5920 | # This file is a shell script that caches the results of configure |
| 5921 | # tests run on this system so they can be shared between configure |
| 5922 | # scripts and configure runs. It is not useful on other systems. |
| 5923 | # If it contains results you don't want to keep, you may remove or edit it. |
| 5924 | # |
| 5925 | # By default, configure uses ./config.cache as the cache file, |
| 5926 | # creating it if it does not exist already. You can give configure |
| 5927 | # the --cache-file=FILE option to use a different cache file; that is |
| 5928 | # what configure does when it calls configure scripts in |
| 5929 | # subdirectories, so they share the cache. |
| 5930 | # Giving --cache-file=/dev/null disables caching, for debugging configure. |
| 5931 | # config.status only pays attention to the cache file if you give it the |
| 5932 | # --recheck option to rerun configure. |
| 5933 | # |
| 5934 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5935 | # The following way of writing the cache mishandles newlines in values, |
| 5936 | # but we know of no workaround that is simple, portable, and efficient. |
| 5937 | # So, don't put newlines in cache variables' values. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5938 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 5939 | # 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] | 5940 | (set) 2>&1 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 5941 | case `(ac_space=' '; set | grep ac_space) 2>&1` in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5942 | *ac_space=\ *) |
| 5943 | # `set' does not quote correctly, so add quotes (double-quote substitution |
| 5944 | # turns \\\\ into \\, and sed turns \\ into \). |
| 5945 | sed -n \ |
| 5946 | -e "s/'/'\\\\''/g" \ |
| 5947 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" |
| 5948 | ;; |
| 5949 | *) |
| 5950 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
| 5951 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' |
| 5952 | ;; |
| 5953 | esac >> confcache |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5954 | if cmp -s $cache_file confcache; then |
| 5955 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5956 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5957 | if test -w $cache_file; then |
| 5958 | echo "updating cache $cache_file" |
| 5959 | cat confcache > $cache_file |
| 5960 | else |
| 5961 | echo "not updating unwritable cache $cache_file" |
| 5962 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5963 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5964 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 5965 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5966 | 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] | 5967 | |
| 5968 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 5969 | # Let make expand exec_prefix. |
| 5970 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 5971 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5972 | # Any assignment to VPATH causes Sun make to only execute |
| 5973 | # the first set of double-colon rules, so remove it if not needed. |
| 5974 | # If there is a colon in the path, we need to keep it. |
| 5975 | if test "x$srcdir" = x.; then |
| 5976 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
| 5977 | fi |
| 5978 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5979 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5980 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5981 | DEFS=-DHAVE_CONFIG_H |
| 5982 | |
| 5983 | # Without the "./", some shells look in PATH for config.status. |
| 5984 | : ${CONFIG_STATUS=./config.status} |
| 5985 | |
| 5986 | echo creating $CONFIG_STATUS |
| 5987 | rm -f $CONFIG_STATUS |
| 5988 | cat > $CONFIG_STATUS <<EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5989 | #! /bin/sh |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5990 | # Generated automatically by configure. |
| 5991 | # Run this file to recreate the current configuration. |
| 5992 | # This directory was configured as follows, |
| 5993 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
| 5994 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5995 | # $0 $ac_configure_args |
| 5996 | # |
| 5997 | # Compiler output produced by configure, useful for debugging |
| 5998 | # configure, is in ./config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5999 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6000 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6001 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6002 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6003 | case "\$ac_option" in |
| 6004 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6005 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
| 6006 | 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] | 6007 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 6008 | echo "$CONFIG_STATUS generated by autoconf version 2.13" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6009 | exit 0 ;; |
| 6010 | -help | --help | --hel | --he | --h) |
| 6011 | echo "\$ac_cs_usage"; exit 0 ;; |
| 6012 | *) echo "\$ac_cs_usage"; exit 1 ;; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6013 | esac |
| 6014 | done |
| 6015 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6016 | ac_given_srcdir=$srcdir |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6017 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 6018 | trap 'rm -fr `echo "Makefile \ |
| 6019 | Objects/Makefile \ |
| 6020 | Parser/Makefile \ |
Sjoerd Mullender | a179503 | 2000-08-17 11:41:06 +0000 | [diff] [blame] | 6021 | Grammar/Makefile \ |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 6022 | Python/Makefile \ |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 6023 | Modules/Makefile.pre \ |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 6024 | 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] | 6025 | EOF |
| 6026 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6027 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6028 | # Protect against being on the right side of a sed subst in config.status. |
| 6029 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; |
| 6030 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6031 | $ac_vpsub |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6032 | $extrasub |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 6033 | s%@SHELL@%$SHELL%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6034 | s%@CFLAGS@%$CFLAGS%g |
| 6035 | s%@CPPFLAGS@%$CPPFLAGS%g |
| 6036 | s%@CXXFLAGS@%$CXXFLAGS%g |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 6037 | s%@FFLAGS@%$FFLAGS%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6038 | s%@DEFS@%$DEFS%g |
| 6039 | s%@LDFLAGS@%$LDFLAGS%g |
| 6040 | s%@LIBS@%$LIBS%g |
| 6041 | s%@exec_prefix@%$exec_prefix%g |
| 6042 | s%@prefix@%$prefix%g |
| 6043 | s%@program_transform_name@%$program_transform_name%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6044 | s%@bindir@%$bindir%g |
| 6045 | s%@sbindir@%$sbindir%g |
| 6046 | s%@libexecdir@%$libexecdir%g |
| 6047 | s%@datadir@%$datadir%g |
| 6048 | s%@sysconfdir@%$sysconfdir%g |
| 6049 | s%@sharedstatedir@%$sharedstatedir%g |
| 6050 | s%@localstatedir@%$localstatedir%g |
| 6051 | s%@libdir@%$libdir%g |
| 6052 | s%@includedir@%$includedir%g |
| 6053 | s%@oldincludedir@%$oldincludedir%g |
| 6054 | s%@infodir@%$infodir%g |
| 6055 | s%@mandir@%$mandir%g |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 6056 | s%@VERSION@%$VERSION%g |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 6057 | s%@MACHDEP@%$MACHDEP%g |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 6058 | s%@SGI_ABI@%$SGI_ABI%g |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 6059 | s%@SET_CXX@%$SET_CXX%g |
| 6060 | s%@MAINOBJ@%$MAINOBJ%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6061 | s%@CC@%$CC%g |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 6062 | s%@EXE@%$EXE%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 6063 | s%@MAKE_LDLIBRARY@%$MAKE_LDLIBRARY%g |
| 6064 | s%@LDLIBRARY@%$LDLIBRARY%g |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 6065 | s%@LINKCC@%$LINKCC%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6066 | s%@RANLIB@%$RANLIB%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6067 | s%@AR@%$AR%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 6068 | s%@INSTALL@%$INSTALL%g |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6069 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
| 6070 | s%@INSTALL_DATA@%$INSTALL_DATA%g |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6071 | s%@LN@%$LN%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 6072 | s%@OPT@%$OPT%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6073 | s%@CPP@%$CPP%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 6074 | s%@LIBTOOL_CRUFT@%$LIBTOOL_CRUFT%g |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 6075 | s%@SO@%$SO%g |
| 6076 | s%@LDSHARED@%$LDSHARED%g |
| 6077 | s%@CCSHARED@%$CCSHARED%g |
| 6078 | s%@LINKFORSHARED@%$LINKFORSHARED%g |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 6079 | s%@USE_THREAD_MODULE@%$USE_THREAD_MODULE%g |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 6080 | s%@LDLAST@%$LDLAST%g |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 6081 | s%@USE_GC_MODULE@%$USE_GC_MODULE%g |
Fred Drake | a50d6ec | 2000-08-31 16:13:20 +0000 | [diff] [blame] | 6082 | s%@USE_BSDDB_MODULE@%$USE_BSDDB_MODULE%g |
Skip Montanaro | ed33c9a | 2000-09-08 02:17:15 +0000 | [diff] [blame] | 6083 | s%@HAVE_LIBDB@%$HAVE_LIBDB%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6084 | s%@DLINCLDIR@%$DLINCLDIR%g |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 6085 | s%@DYNLOADFILE@%$DYNLOADFILE%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6086 | s%@LIBOBJS@%$LIBOBJS%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6087 | s%@HAVE_GETHOSTBYNAME_R_6_ARG@%$HAVE_GETHOSTBYNAME_R_6_ARG%g |
| 6088 | s%@HAVE_GETHOSTBYNAME_R_5_ARG@%$HAVE_GETHOSTBYNAME_R_5_ARG%g |
| 6089 | 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] | 6090 | s%@HAVE_GETHOSTBYNAME_R@%$HAVE_GETHOSTBYNAME_R%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6091 | s%@HAVE_GETHOSTBYNAME@%$HAVE_GETHOSTBYNAME%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6092 | s%@LIBM@%$LIBM%g |
| 6093 | s%@LIBC@%$LIBC%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6094 | |
| 6095 | CEOF |
| 6096 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6097 | |
| 6098 | cat >> $CONFIG_STATUS <<\EOF |
| 6099 | |
| 6100 | # Split the substitutions into bite-sized pieces for seds with |
| 6101 | # small command number limits, like on Digital OSF/1 and HP-UX. |
| 6102 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. |
| 6103 | ac_file=1 # Number of current file. |
| 6104 | ac_beg=1 # First line for current file. |
| 6105 | ac_end=$ac_max_sed_cmds # Line after last line for current file. |
| 6106 | ac_more_lines=: |
| 6107 | ac_sed_cmds="" |
| 6108 | while $ac_more_lines; do |
| 6109 | if test $ac_beg -gt 1; then |
| 6110 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file |
| 6111 | else |
| 6112 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file |
| 6113 | fi |
| 6114 | if test ! -s conftest.s$ac_file; then |
| 6115 | ac_more_lines=false |
| 6116 | rm -f conftest.s$ac_file |
| 6117 | else |
| 6118 | if test -z "$ac_sed_cmds"; then |
| 6119 | ac_sed_cmds="sed -f conftest.s$ac_file" |
| 6120 | else |
| 6121 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" |
| 6122 | fi |
| 6123 | ac_file=`expr $ac_file + 1` |
| 6124 | ac_beg=$ac_end |
| 6125 | ac_end=`expr $ac_end + $ac_max_sed_cmds` |
| 6126 | fi |
| 6127 | done |
| 6128 | if test -z "$ac_sed_cmds"; then |
| 6129 | ac_sed_cmds=cat |
| 6130 | fi |
| 6131 | EOF |
| 6132 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6133 | cat >> $CONFIG_STATUS <<EOF |
| 6134 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 6135 | CONFIG_FILES=\${CONFIG_FILES-"Makefile \ |
| 6136 | Objects/Makefile \ |
| 6137 | Parser/Makefile \ |
Sjoerd Mullender | a179503 | 2000-08-17 11:41:06 +0000 | [diff] [blame] | 6138 | Grammar/Makefile \ |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 6139 | Python/Makefile \ |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 6140 | Modules/Makefile.pre \ |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 6141 | Modules/Setup.config"} |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6142 | EOF |
| 6143 | cat >> $CONFIG_STATUS <<\EOF |
| 6144 | 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] | 6145 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6146 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6147 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6148 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 6149 | *) ac_file_in="${ac_file}.in" ;; |
| 6150 | esac |
| 6151 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6152 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6153 | |
| 6154 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 6155 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 6156 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 6157 | # The file is in a subdirectory. |
| 6158 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6159 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6160 | # A "../" for each directory in $ac_dir_suffix. |
| 6161 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
| 6162 | else |
| 6163 | ac_dir_suffix= ac_dots= |
| 6164 | fi |
| 6165 | |
| 6166 | case "$ac_given_srcdir" in |
| 6167 | .) srcdir=. |
| 6168 | if test -z "$ac_dots"; then top_srcdir=. |
| 6169 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; |
| 6170 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; |
| 6171 | *) # Relative path. |
| 6172 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
| 6173 | top_srcdir="$ac_dots$ac_given_srcdir" ;; |
| 6174 | esac |
| 6175 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6176 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6177 | echo creating "$ac_file" |
| 6178 | rm -f "$ac_file" |
| 6179 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." |
| 6180 | case "$ac_file" in |
| 6181 | *Makefile*) ac_comsub="1i\\ |
| 6182 | # $configure_input" ;; |
| 6183 | *) ac_comsub= ;; |
| 6184 | esac |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6185 | |
| 6186 | 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] | 6187 | sed -e "$ac_comsub |
| 6188 | s%@configure_input@%$configure_input%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6189 | s%@srcdir@%$srcdir%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6190 | s%@top_srcdir@%$top_srcdir%g |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6191 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6192 | fi; done |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6193 | rm -f conftest.s* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6194 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6195 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
| 6196 | # 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] | 6197 | # |
| 6198 | # ac_d sets the value in "#define NAME VALUE" lines. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6199 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
| 6200 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6201 | ac_dC='\3' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6202 | ac_dD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6203 | # 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] | 6204 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 6205 | ac_uB='\([ ]\)%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6206 | ac_uC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6207 | ac_uD='\4%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6208 | # 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] | 6209 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 6210 | ac_eB='$%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6211 | ac_eC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6212 | ac_eD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6213 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6214 | if test "${CONFIG_HEADERS+set}" != set; then |
| 6215 | EOF |
| 6216 | cat >> $CONFIG_STATUS <<EOF |
| 6217 | CONFIG_HEADERS="config.h" |
| 6218 | EOF |
| 6219 | cat >> $CONFIG_STATUS <<\EOF |
| 6220 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6221 | 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] | 6222 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6223 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6224 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6225 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 6226 | *) ac_file_in="${ac_file}.in" ;; |
| 6227 | esac |
| 6228 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6229 | echo creating $ac_file |
| 6230 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6231 | rm -f conftest.frag conftest.in conftest.out |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6232 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
| 6233 | cat $ac_file_inputs > conftest.in |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6234 | |
| 6235 | EOF |
| 6236 | |
| 6237 | # Transform confdefs.h into a sed script conftest.vals that substitutes |
| 6238 | # 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] | 6239 | # 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] | 6240 | # Protect against being in an unquoted here document in config.status. |
| 6241 | rm -f conftest.vals |
| 6242 | cat > conftest.hdr <<\EOF |
| 6243 | s/[\\&%]/\\&/g |
| 6244 | s%[\\$`]%\\&%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6245 | 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] | 6246 | s%ac_d%ac_u%gp |
| 6247 | s%ac_u%ac_e%gp |
| 6248 | EOF |
| 6249 | sed -n -f conftest.hdr confdefs.h > conftest.vals |
| 6250 | rm -f conftest.hdr |
| 6251 | |
| 6252 | # This sed command replaces #undef with comments. This is necessary, for |
| 6253 | # example, in the case of _POSIX_SOURCE, which is predefined and required |
| 6254 | # on some systems where configure will not decide to define it. |
| 6255 | cat >> conftest.vals <<\EOF |
| 6256 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% |
| 6257 | EOF |
| 6258 | |
| 6259 | # Break up conftest.vals because some shells have a limit on |
| 6260 | # 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] | 6261 | |
| 6262 | rm -f conftest.tail |
| 6263 | while : |
| 6264 | do |
| 6265 | ac_lines=`grep -c . conftest.vals` |
| 6266 | # grep -c gives empty output for an empty file on some AIX systems. |
| 6267 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi |
| 6268 | # Write a limited-size here document to conftest.frag. |
| 6269 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS |
| 6270 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS |
| 6271 | echo 'CEOF |
| 6272 | sed -f conftest.frag conftest.in > conftest.out |
| 6273 | rm -f conftest.in |
| 6274 | mv conftest.out conftest.in |
| 6275 | ' >> $CONFIG_STATUS |
| 6276 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
| 6277 | rm -f conftest.vals |
| 6278 | mv conftest.tail conftest.vals |
| 6279 | done |
| 6280 | rm -f conftest.vals |
| 6281 | |
| 6282 | cat >> $CONFIG_STATUS <<\EOF |
| 6283 | rm -f conftest.frag conftest.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6284 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6285 | cat conftest.in >> conftest.h |
| 6286 | rm -f conftest.in |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6287 | if cmp -s $ac_file conftest.h 2>/dev/null; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6288 | echo "$ac_file is unchanged" |
| 6289 | rm -f conftest.h |
| 6290 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6291 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 6292 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 6293 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 6294 | # The file is in a subdirectory. |
| 6295 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
| 6296 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6297 | rm -f $ac_file |
| 6298 | mv conftest.h $ac_file |
| 6299 | fi |
| 6300 | fi; done |
| 6301 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6302 | EOF |
| 6303 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6304 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6305 | EOF |
| 6306 | cat >> $CONFIG_STATUS <<\EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6307 | |
| 6308 | exit 0 |
| 6309 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6310 | chmod +x $CONFIG_STATUS |
| 6311 | rm -fr confdefs* $ac_clean_files |
Jeremy Hylton | 1bac645 | 2000-09-26 16:57:37 +0000 | [diff] [blame] | 6312 | 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] | 6313 | |