blob: a79ce5bc5a51063531e9814363b25d43d0e970b0 [file] [log] [blame]
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001#! /bin/sh
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002
Guido van Rossum2efa34b1997-10-23 17:43:11 +00003# From configure.in Revision: 1.70
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004
Guido van Rossum627b2d71993-12-24 10:39:16 +00005# Guess values for system-dependent variables and create Makefiles.
Guido van Rossumf78abae1997-01-21 22:02:36 +00006# Generated automatically using autoconf version 2.12
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00007# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00008#
9# This configure script is free software; the Free Software Foundation
10# gives unlimited permission to copy, distribute and modify it.
Guido van Rossum627b2d71993-12-24 10:39:16 +000011
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012# Defaults:
13ac_help=
14ac_default_prefix=/usr/local
15# Any additions from configure.in:
16ac_help="$ac_help
Guido van Rossum7b3853f1996-07-30 18:09:35 +000017--with-next-archs='arch1 arch2 ..' build MAB binary"
18ac_help="$ac_help
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019--without-gcc never use gcc"
20ac_help="$ac_help
Guido van Rossuma68acba1996-07-31 17:36:39 +000021--with-libs='lib1 ...' link against additional libs"
22ac_help="$ac_help
Guido van Rossumb06df271997-08-05 21:50:20 +000023--with(out)-readline obsolete, edit Modules/Setup instead"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000024ac_help="$ac_help
Guido van Rossumec2f0731997-01-22 20:54:01 +000025--with-dec-threads use DEC Alpha/OSF1 thread-safe libraries"
26ac_help="$ac_help
27--with-threads alias for --with-thread"
28ac_help="$ac_help
Guido van Rossum76be6ed1995-01-02 18:33:54 +000029--with-thread[=DIRECTORY] make interpreter thread-safe"
30ac_help="$ac_help
31--with-sgi-dl=DIRECTORY IRIX 4 dynamic linking"
32ac_help="$ac_help
33--with-dl-dld=DL_DIR,DLD_DIR GNU dynamic linking"
34ac_help="$ac_help
Guido van Rossum7f253911997-05-09 02:42:48 +000035--with-fpectl enable SIGFPE catching"
36ac_help="$ac_help
Guido van Rossum76be6ed1995-01-02 18:33:54 +000037--with-libm=STRING math library"
38ac_help="$ac_help
39--with-libc=STRING C library"
Guido van Rossum627b2d71993-12-24 10:39:16 +000040
Guido van Rossum7f43da71994-08-01 12:15:30 +000041# Initialize some variables set by options.
42# The variables have the same names as the options, with
43# dashes changed to underlines.
44build=NONE
Guido van Rossum76be6ed1995-01-02 18:33:54 +000045cache_file=./config.cache
46exec_prefix=NONE
Guido van Rossum7f43da71994-08-01 12:15:30 +000047host=NONE
48no_create=
49nonopt=NONE
Guido van Rossum76be6ed1995-01-02 18:33:54 +000050no_recursion=
51prefix=NONE
52program_prefix=NONE
53program_suffix=NONE
54program_transform_name=s,x,x,
Guido van Rossum7f43da71994-08-01 12:15:30 +000055silent=
Guido van Rossum76be6ed1995-01-02 18:33:54 +000056site=
Guido van Rossum7f43da71994-08-01 12:15:30 +000057srcdir=
58target=NONE
59verbose=
Guido van Rossum76be6ed1995-01-02 18:33:54 +000060x_includes=NONE
61x_libraries=NONE
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000062bindir='${exec_prefix}/bin'
63sbindir='${exec_prefix}/sbin'
64libexecdir='${exec_prefix}/libexec'
65datadir='${prefix}/share'
66sysconfdir='${prefix}/etc'
67sharedstatedir='${prefix}/com'
68localstatedir='${prefix}/var'
69libdir='${exec_prefix}/lib'
70includedir='${prefix}/include'
71oldincludedir='/usr/include'
72infodir='${prefix}/info'
73mandir='${prefix}/man'
Guido van Rossum76be6ed1995-01-02 18:33:54 +000074
75# Initialize some other variables.
76subdirs=
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000077MFLAGS= MAKEFLAGS=
Guido van Rossumf78abae1997-01-21 22:02:36 +000078# Maximum number of lines to put in a shell here document.
79ac_max_here_lines=12
Guido van Rossum7f43da71994-08-01 12:15:30 +000080
81ac_prev=
82for ac_option
Guido van Rossum627b2d71993-12-24 10:39:16 +000083do
Guido van Rossum627b2d71993-12-24 10:39:16 +000084
Guido van Rossum7f43da71994-08-01 12:15:30 +000085 # If the previous option needs an argument, assign it.
86 if test -n "$ac_prev"; then
87 eval "$ac_prev=\$ac_option"
88 ac_prev=
89 continue
Guido van Rossum627b2d71993-12-24 10:39:16 +000090 fi
Guido van Rossum7f43da71994-08-01 12:15:30 +000091
Guido van Rossum7f43da71994-08-01 12:15:30 +000092 case "$ac_option" in
93 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
94 *) ac_optarg= ;;
95 esac
96
Guido van Rossum76be6ed1995-01-02 18:33:54 +000097 # Accept the important Cygnus configure options, so we can diagnose typos.
98
Guido van Rossum7f43da71994-08-01 12:15:30 +000099 case "$ac_option" in
100
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000101 -bindir | --bindir | --bindi | --bind | --bin | --bi)
102 ac_prev=bindir ;;
103 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
104 bindir="$ac_optarg" ;;
105
106 -build | --build | --buil | --bui | --bu)
Guido van Rossum7f43da71994-08-01 12:15:30 +0000107 ac_prev=build ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000108 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
Guido van Rossum7f43da71994-08-01 12:15:30 +0000109 build="$ac_optarg" ;;
110
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000111 -cache-file | --cache-file | --cache-fil | --cache-fi \
112 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
113 ac_prev=cache_file ;;
114 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
115 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
116 cache_file="$ac_optarg" ;;
117
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000118 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
119 ac_prev=datadir ;;
120 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
121 | --da=*)
122 datadir="$ac_optarg" ;;
123
Guido van Rossum7f43da71994-08-01 12:15:30 +0000124 -disable-* | --disable-*)
125 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000126 # Reject names that are not valid shell variable names.
Guido van Rossum7f43da71994-08-01 12:15:30 +0000127 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000128 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000129 fi
130 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
131 eval "enable_${ac_feature}=no" ;;
132
133 -enable-* | --enable-*)
134 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000135 # Reject names that are not valid shell variable names.
Guido van Rossum7f43da71994-08-01 12:15:30 +0000136 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000137 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000138 fi
139 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
140 case "$ac_option" in
141 *=*) ;;
142 *) ac_optarg=yes ;;
143 esac
144 eval "enable_${ac_feature}='$ac_optarg'" ;;
145
Guido van Rossum7f43da71994-08-01 12:15:30 +0000146 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
147 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
148 | --exec | --exe | --ex)
149 ac_prev=exec_prefix ;;
150 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
151 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
152 | --exec=* | --exe=* | --ex=*)
153 exec_prefix="$ac_optarg" ;;
154
155 -gas | --gas | --ga | --g)
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000156 # Obsolete; use --with-gas.
157 with_gas=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000158
159 -help | --help | --hel | --he)
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000160 # Omit some internal or obsolete options to make the list less imposing.
161 # This message is too long to be a string in the A/UX 3.1 sh.
Guido van Rossum7f43da71994-08-01 12:15:30 +0000162 cat << EOF
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000163Usage: configure [options] [host]
164Options: [defaults in brackets after descriptions]
165Configuration:
166 --cache-file=FILE cache test results in FILE
167 --help print this message
168 --no-create do not create output files
169 --quiet, --silent do not print \`checking...' messages
170 --version print the version of autoconf that created configure
171Directory and file names:
172 --prefix=PREFIX install architecture-independent files in PREFIX
173 [$ac_default_prefix]
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000174 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000175 [same as prefix]
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000176 --bindir=DIR user executables in DIR [EPREFIX/bin]
177 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
178 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
179 --datadir=DIR read-only architecture-independent data in DIR
180 [PREFIX/share]
181 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
182 --sharedstatedir=DIR modifiable architecture-independent data in DIR
183 [PREFIX/com]
184 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
185 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
186 --includedir=DIR C header files in DIR [PREFIX/include]
187 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
188 --infodir=DIR info documentation in DIR [PREFIX/info]
189 --mandir=DIR man documentation in DIR [PREFIX/man]
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000190 --srcdir=DIR find the sources in DIR [configure dir or ..]
191 --program-prefix=PREFIX prepend PREFIX to installed program names
192 --program-suffix=SUFFIX append SUFFIX to installed program names
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000193 --program-transform-name=PROGRAM
194 run sed PROGRAM on installed program names
195EOF
196 cat << EOF
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000197Host type:
198 --build=BUILD configure for building on BUILD [BUILD=HOST]
199 --host=HOST configure for HOST [guessed]
200 --target=TARGET configure for TARGET [TARGET=HOST]
201Features and packages:
202 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
203 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
204 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
205 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
206 --x-includes=DIR X include files are in DIR
207 --x-libraries=DIR X library files are in DIR
Guido van Rossum7f43da71994-08-01 12:15:30 +0000208EOF
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000209 if test -n "$ac_help"; then
210 echo "--enable and --with options recognized:$ac_help"
211 fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000212 exit 0 ;;
213
214 -host | --host | --hos | --ho)
215 ac_prev=host ;;
216 -host=* | --host=* | --hos=* | --ho=*)
217 host="$ac_optarg" ;;
218
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000219 -includedir | --includedir | --includedi | --included | --include \
220 | --includ | --inclu | --incl | --inc)
221 ac_prev=includedir ;;
222 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
223 | --includ=* | --inclu=* | --incl=* | --inc=*)
224 includedir="$ac_optarg" ;;
225
226 -infodir | --infodir | --infodi | --infod | --info | --inf)
227 ac_prev=infodir ;;
228 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
229 infodir="$ac_optarg" ;;
230
231 -libdir | --libdir | --libdi | --libd)
232 ac_prev=libdir ;;
233 -libdir=* | --libdir=* | --libdi=* | --libd=*)
234 libdir="$ac_optarg" ;;
235
236 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
237 | --libexe | --libex | --libe)
238 ac_prev=libexecdir ;;
239 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
240 | --libexe=* | --libex=* | --libe=*)
241 libexecdir="$ac_optarg" ;;
242
243 -localstatedir | --localstatedir | --localstatedi | --localstated \
244 | --localstate | --localstat | --localsta | --localst \
245 | --locals | --local | --loca | --loc | --lo)
246 ac_prev=localstatedir ;;
247 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
248 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
249 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
250 localstatedir="$ac_optarg" ;;
251
252 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
253 ac_prev=mandir ;;
254 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
255 mandir="$ac_optarg" ;;
256
Guido van Rossum7f43da71994-08-01 12:15:30 +0000257 -nfp | --nfp | --nf)
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000258 # Obsolete; use --without-fp.
259 with_fp=no ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000260
261 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
262 | --no-cr | --no-c)
263 no_create=yes ;;
264
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000265 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
266 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
267 no_recursion=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000268
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000269 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
270 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
271 | --oldin | --oldi | --old | --ol | --o)
272 ac_prev=oldincludedir ;;
273 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
274 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
275 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
276 oldincludedir="$ac_optarg" ;;
277
Guido van Rossum7f43da71994-08-01 12:15:30 +0000278 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
279 ac_prev=prefix ;;
280 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
281 prefix="$ac_optarg" ;;
282
283 -program-prefix | --program-prefix | --program-prefi | --program-pref \
284 | --program-pre | --program-pr | --program-p)
285 ac_prev=program_prefix ;;
286 -program-prefix=* | --program-prefix=* | --program-prefi=* \
287 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
288 program_prefix="$ac_optarg" ;;
289
290 -program-suffix | --program-suffix | --program-suffi | --program-suff \
291 | --program-suf | --program-su | --program-s)
292 ac_prev=program_suffix ;;
293 -program-suffix=* | --program-suffix=* | --program-suffi=* \
294 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
295 program_suffix="$ac_optarg" ;;
296
297 -program-transform-name | --program-transform-name \
298 | --program-transform-nam | --program-transform-na \
299 | --program-transform-n | --program-transform- \
300 | --program-transform | --program-transfor \
301 | --program-transfo | --program-transf \
302 | --program-trans | --program-tran \
303 | --progr-tra | --program-tr | --program-t)
304 ac_prev=program_transform_name ;;
305 -program-transform-name=* | --program-transform-name=* \
306 | --program-transform-nam=* | --program-transform-na=* \
307 | --program-transform-n=* | --program-transform-=* \
308 | --program-transform=* | --program-transfor=* \
309 | --program-transfo=* | --program-transf=* \
310 | --program-trans=* | --program-tran=* \
311 | --progr-tra=* | --program-tr=* | --program-t=*)
312 program_transform_name="$ac_optarg" ;;
313
314 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
315 | -silent | --silent | --silen | --sile | --sil)
316 silent=yes ;;
317
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000318 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
319 ac_prev=sbindir ;;
320 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
321 | --sbi=* | --sb=*)
322 sbindir="$ac_optarg" ;;
323
324 -sharedstatedir | --sharedstatedir | --sharedstatedi \
325 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
326 | --sharedst | --shareds | --shared | --share | --shar \
327 | --sha | --sh)
328 ac_prev=sharedstatedir ;;
329 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
330 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
331 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
332 | --sha=* | --sh=*)
333 sharedstatedir="$ac_optarg" ;;
334
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000335 -site | --site | --sit)
336 ac_prev=site ;;
337 -site=* | --site=* | --sit=*)
338 site="$ac_optarg" ;;
339
Guido van Rossum7f43da71994-08-01 12:15:30 +0000340 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
341 ac_prev=srcdir ;;
342 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
343 srcdir="$ac_optarg" ;;
344
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000345 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
346 | --syscon | --sysco | --sysc | --sys | --sy)
347 ac_prev=sysconfdir ;;
348 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
349 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
350 sysconfdir="$ac_optarg" ;;
351
Guido van Rossum7f43da71994-08-01 12:15:30 +0000352 -target | --target | --targe | --targ | --tar | --ta | --t)
353 ac_prev=target ;;
354 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
355 target="$ac_optarg" ;;
356
357 -v | -verbose | --verbose | --verbos | --verbo | --verb)
358 verbose=yes ;;
359
360 -version | --version | --versio | --versi | --vers)
Guido van Rossumf78abae1997-01-21 22:02:36 +0000361 echo "configure generated by autoconf version 2.12"
Guido van Rossum7f43da71994-08-01 12:15:30 +0000362 exit 0 ;;
363
364 -with-* | --with-*)
365 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000366 # Reject names that are not valid shell variable names.
Guido van Rossum7f43da71994-08-01 12:15:30 +0000367 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000368 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000369 fi
370 ac_package=`echo $ac_package| sed 's/-/_/g'`
371 case "$ac_option" in
372 *=*) ;;
373 *) ac_optarg=yes ;;
374 esac
375 eval "with_${ac_package}='$ac_optarg'" ;;
376
377 -without-* | --without-*)
378 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000379 # Reject names that are not valid shell variable names.
Guido van Rossum7f43da71994-08-01 12:15:30 +0000380 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000381 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000382 fi
383 ac_package=`echo $ac_package| sed 's/-/_/g'`
384 eval "with_${ac_package}=no" ;;
385
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000386 --x)
387 # Obsolete; use --with-x.
388 with_x=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000389
390 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
391 | --x-incl | --x-inc | --x-in | --x-i)
392 ac_prev=x_includes ;;
393 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
394 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
395 x_includes="$ac_optarg" ;;
396
397 -x-libraries | --x-libraries | --x-librarie | --x-librari \
398 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
399 ac_prev=x_libraries ;;
400 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
401 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
402 x_libraries="$ac_optarg" ;;
403
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000404 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000405 ;;
406
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000407 *)
Guido van Rossum0a516c91994-09-12 10:58:40 +0000408 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000409 echo "configure: warning: $ac_option: invalid host type" 1>&2
Guido van Rossum7f43da71994-08-01 12:15:30 +0000410 fi
Guido van Rossum0a516c91994-09-12 10:58:40 +0000411 if test "x$nonopt" != xNONE; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000412 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000413 fi
414 nonopt="$ac_option"
415 ;;
416
417 esac
Guido van Rossum627b2d71993-12-24 10:39:16 +0000418done
419
Guido van Rossum7f43da71994-08-01 12:15:30 +0000420if test -n "$ac_prev"; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000421 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000422fi
423
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000424trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
Guido van Rossum7f43da71994-08-01 12:15:30 +0000425
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000426# File descriptor usage:
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000427# 0 standard input
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000428# 1 file creation
429# 2 errors and warnings
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000430# 3 some systems may open it to /dev/tty
431# 4 used on the Kubota Titan
432# 6 checking for... messages and results
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000433# 5 compiler messages saved in config.log
434if test "$silent" = yes; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000435 exec 6>/dev/null
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000436else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000437 exec 6>&1
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000438fi
439exec 5>./config.log
440
441echo "\
442This file contains any messages produced by compilers while
443running configure, to aid debugging if configure makes a mistake.
444" 1>&5
445
446# Strip out --no-create and --no-recursion so they do not pile up.
447# Also quote any args containing shell metacharacters.
448ac_configure_args=
449for ac_arg
450do
Guido van Rossum7f43da71994-08-01 12:15:30 +0000451 case "$ac_arg" in
452 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
453 | --no-cr | --no-c) ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000454 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
455 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
456 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
457 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
458 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000459 esac
460done
Guido van Rossum627b2d71993-12-24 10:39:16 +0000461
462# NLS nuisances.
Guido van Rossumf78abae1997-01-21 22:02:36 +0000463# Only set these to C if already set. These must not be set unconditionally
464# because not all systems understand e.g. LANG=C (notably SCO).
465# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
466# Non-C LC_CTYPE values break the ctype check.
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000467if test "${LANG+set}" = set; then LANG=C; export LANG; fi
Guido van Rossumf78abae1997-01-21 22:02:36 +0000468if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
469if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
470if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000471
Guido van Rossum7f43da71994-08-01 12:15:30 +0000472# confdefs.h avoids OS command line length limits that DEFS can exceed.
473rm -rf conftest* confdefs.h
Guido van Rossum627b2d71993-12-24 10:39:16 +0000474# AIX cpp loses on an empty file, so make sure it contains at least a newline.
475echo > confdefs.h
Guido van Rossum627b2d71993-12-24 10:39:16 +0000476
477# A filename unique to this package, relative to the directory that
478# configure is in, which we can look for to find out if srcdir is correct.
Guido van Rossum7f43da71994-08-01 12:15:30 +0000479ac_unique_file=Include/object.h
Guido van Rossum627b2d71993-12-24 10:39:16 +0000480
481# Find the source files, if location was not specified.
482if test -z "$srcdir"; then
Guido van Rossum7f43da71994-08-01 12:15:30 +0000483 ac_srcdir_defaulted=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000484 # Try the directory containing this script, then its parent.
Guido van Rossum7f43da71994-08-01 12:15:30 +0000485 ac_prog=$0
486 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
487 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
488 srcdir=$ac_confdir
489 if test ! -r $srcdir/$ac_unique_file; then
Guido van Rossum627b2d71993-12-24 10:39:16 +0000490 srcdir=..
491 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000492else
493 ac_srcdir_defaulted=no
Guido van Rossum627b2d71993-12-24 10:39:16 +0000494fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000495if test ! -r $srcdir/$ac_unique_file; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000496 if test "$ac_srcdir_defaulted" = yes; then
497 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
Guido van Rossum627b2d71993-12-24 10:39:16 +0000498 else
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000499 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
Guido van Rossum627b2d71993-12-24 10:39:16 +0000500 fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000501fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000502srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
503
504# Prefer explicitly selected file to automatically selected ones.
505if test -z "$CONFIG_SITE"; then
506 if test "x$prefix" != xNONE; then
507 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
508 else
509 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
510 fi
511fi
512for ac_site_file in $CONFIG_SITE; do
513 if test -r "$ac_site_file"; then
514 echo "loading site script $ac_site_file"
515 . "$ac_site_file"
516 fi
517done
518
519if test -r "$cache_file"; then
520 echo "loading cache $cache_file"
521 . $cache_file
522else
523 echo "creating cache $cache_file"
524 > $cache_file
525fi
526
Guido van Rossum7f43da71994-08-01 12:15:30 +0000527ac_ext=c
Guido van Rossum0a516c91994-09-12 10:58:40 +0000528# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000529ac_cpp='$CPP $CPPFLAGS'
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000530ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
531ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
Guido van Rossumf78abae1997-01-21 22:02:36 +0000532cross_compiling=$ac_cv_prog_cc_cross
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000533
534if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
535 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
536 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
537 ac_n= ac_c='
538' ac_t=' '
539 else
540 ac_n=-n ac_c= ac_t=
541 fi
542else
543 ac_n= ac_c='\c' ac_t=
544fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000545
Guido van Rossum0a516c91994-09-12 10:58:40 +0000546
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000547
Guido van Rossum627b2d71993-12-24 10:39:16 +0000548
Guido van Rossum1fd74a71997-07-19 19:36:02 +0000549# Set VERSION so we only need to edit in one place (i.e., here)
550
551VERSION=1.5
552
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000553# NEXTSTEP stuff
Guido van Rossum563e7081996-09-10 18:20:48 +0000554if test -f /usr/lib/NextStep/software_version; then
555
556 echo $ac_n "checking for --with-next-archs""... $ac_c" 1>&6
Guido van Rossumb06df271997-08-05 21:50:20 +0000557echo "configure:558: checking for --with-next-archs" >&5
Guido van Rossum563e7081996-09-10 18:20:48 +0000558 # Check whether --with-next-archs or --without-next-archs was given.
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000559if test "${with_next_archs+set}" = set; then
560 withval="$with_next_archs"
561
Guido van Rossum563e7081996-09-10 18:20:48 +0000562 if test -n "$withval"; then
563 ac_arch_flags=`/usr/lib/arch_tool -archify_list $withval`
564 # GCC does not currently support multi archs on the NeXT
565 with_gcc=no
566 fi
567 echo "$ac_t""$with_next_archs" 1>&6
568
569else
570 echo "$ac_t""none: using `arch`" 1>&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000571fi
572
Guido van Rossum563e7081996-09-10 18:20:48 +0000573
574 if test -z "$MACHDEP"
575 then
576 set X `hostinfo | grep 'NeXT Mach.*:' | \
577 sed -e 's/://' -e 's/\./_/'` && \
578 ac_sys_system=next && ac_sys_release=$4
579
Guido van Rossumb97ef171997-09-28 05:44:03 +0000580 MACHDEP="$ac_sys_system$ac_sys_release"
Guido van Rossum563e7081996-09-10 18:20:48 +0000581 fi
582fi
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000583
Guido van Rossum91922671997-10-09 20:24:13 +0000584
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000585# Set name for machine-dependent library files
586
587echo $ac_n "checking MACHDEP""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000588echo "configure:589: checking MACHDEP" >&5
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000589if test -z "$MACHDEP"
590then
Guido van Rossum563e7081996-09-10 18:20:48 +0000591 ac_sys_system=`uname -s`
592 if test "$ac_sys_system" = "AIX" ; then
593 ac_sys_release=`uname -v`
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000594 else
Guido van Rossum563e7081996-09-10 18:20:48 +0000595 ac_sys_release=`uname -r`
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000596 fi
Guido van Rossum563e7081996-09-10 18:20:48 +0000597 ac_md_system=`echo $ac_sys_system |
598 tr -d '/ ' | tr '[A-Z]' '[a-z]'`
599 ac_md_release=`echo $ac_sys_release |
600 tr -d '/ ' | sed 's/\..*//'`
Guido van Rossumb97ef171997-09-28 05:44:03 +0000601 MACHDEP="$ac_md_system$ac_md_release"
Guido van Rossum563e7081996-09-10 18:20:48 +0000602
Guido van Rossum07397971997-04-29 21:49:50 +0000603 case $MACHDEP in
Guido van Rossumb97ef171997-09-28 05:44:03 +0000604 '') MACHDEP="unknown";;
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000605 esac
606fi
Guido van Rossum91922671997-10-09 20:24:13 +0000607
608#
609# SGI compilers allow the specification of the both the ABI and the
610# ISA on the command line. Depending on the values of these switches,
611# different and often incompatable code will be generated.
612#
613# The SGI_ABI variable can be used to modify the CC and LDFLAGS and
614# thus supply support for various ABI/ISA combinations. The MACHDEP
615# variable is also adjusted.
616#
617
618if test ! -z "$SGI_ABI"
619then
620 CC="cc $SGI_ABI"
621 LDFLAGS="$SGI_ABI $LDFLAGS"
622 MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'`
623fi
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000624echo "$ac_t""$MACHDEP" 1>&6
625
Guido van Rossum91922671997-10-09 20:24:13 +0000626#
627# CCC is the command that compiles C++ programs
628#
629# Not all make programs have this predefined.
630#
631
632echo $ac_n "checking CCC""... $ac_c" 1>&6
633echo "configure:634: checking CCC" >&5
634if test -z "$CCC"
635then
636 case $ac_sys_system in
637 IRIX*) SET_CCC="CCC= CC ${SGI_ABI}";;
638 *) SET_CCC=""
639 esac
640else
641 SET_CCC="CCC= ${CCC}"
642fi
643echo "$ac_t""$SET_CCC" 1>&6
644
645
Guido van Rossum627b2d71993-12-24 10:39:16 +0000646# checks for alternative programs
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000647echo $ac_n "checking for --without-gcc""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000648echo "configure:649: checking for --without-gcc" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000649# Check whether --with-gcc or --without-gcc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000650if test "${with_gcc+set}" = set; then
651 withval="$with_gcc"
Guido van Rossum7f43da71994-08-01 12:15:30 +0000652
653 case $withval in
Guido van Rossumda88dad1995-01-26 00:46:29 +0000654 no) CC=cc
655 without_gcc=yes;;
656 yes) CC=gcc
657 without_gcc=no;;
658 *) CC=$withval
659 without_gcc=$withval;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000660 esac
Guido van Rossumda88dad1995-01-26 00:46:29 +0000661else
Guido van Rossume77438c1995-09-13 18:59:59 +0000662
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000663 case $ac_sys_system in
Guido van Rossume77438c1995-09-13 18:59:59 +0000664 OSF1) CC=cc
665 without_gcc=;;
666 *) without_gcc=no;;
667 esac
Guido van Rossum7f43da71994-08-01 12:15:30 +0000668fi
669
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000670echo "$ac_t""$without_gcc" 1>&6
Guido van Rossumda88dad1995-01-26 00:46:29 +0000671
Guido van Rossum8b131c51995-03-09 14:10:13 +0000672# If the user switches compilers, we can't believe the cache
673if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC"
674then
675 { echo "configure: error: cached CC is different -- throw away $cache_file
676(it is also a good idea to do 'make clean' before compiling)" 1>&2; exit 1; }
677fi
678
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000679# Extract the first word of "gcc", so it can be a program name with args.
680set dummy gcc; ac_word=$2
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000681echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000682echo "configure:683: checking for $ac_word" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000683if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
684 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000685else
686 if test -n "$CC"; then
687 ac_cv_prog_CC="$CC" # Let the user override the test.
688else
Guido van Rossum7f43da71994-08-01 12:15:30 +0000689 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
690 for ac_dir in $PATH; do
691 test -z "$ac_dir" && ac_dir=.
692 if test -f $ac_dir/$ac_word; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000693 ac_cv_prog_CC="gcc"
Guido van Rossum627b2d71993-12-24 10:39:16 +0000694 break
695 fi
696 done
Guido van Rossum7f43da71994-08-01 12:15:30 +0000697 IFS="$ac_save_ifs"
Guido van Rossum627b2d71993-12-24 10:39:16 +0000698fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000699fi
700CC="$ac_cv_prog_CC"
701if test -n "$CC"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000702 echo "$ac_t""$CC" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000703else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000704 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000705fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000706
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000707if test -z "$CC"; then
708 # Extract the first word of "cc", so it can be a program name with args.
709set dummy cc; ac_word=$2
710echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000711echo "configure:712: checking for $ac_word" >&5
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000712if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
713 echo $ac_n "(cached) $ac_c" 1>&6
714else
715 if test -n "$CC"; then
716 ac_cv_prog_CC="$CC" # Let the user override the test.
717else
718 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
719 ac_prog_rejected=no
720 for ac_dir in $PATH; do
721 test -z "$ac_dir" && ac_dir=.
722 if test -f $ac_dir/$ac_word; then
723 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
724 ac_prog_rejected=yes
725 continue
726 fi
727 ac_cv_prog_CC="cc"
728 break
729 fi
730 done
731 IFS="$ac_save_ifs"
732if test $ac_prog_rejected = yes; then
733 # We found a bogon in the path, so make sure we never use it.
734 set dummy $ac_cv_prog_CC
735 shift
736 if test $# -gt 0; then
737 # We chose a different compiler from the bogus one.
738 # However, it has the same basename, so the bogon will be chosen
739 # first if we set CC to just the basename; use the full file name.
740 shift
741 set dummy "$ac_dir/$ac_word" "$@"
742 shift
743 ac_cv_prog_CC="$@"
744 fi
745fi
746fi
747fi
748CC="$ac_cv_prog_CC"
749if test -n "$CC"; then
750 echo "$ac_t""$CC" 1>&6
751else
752 echo "$ac_t""no" 1>&6
753fi
754
755 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
756fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000757
Guido van Rossumf78abae1997-01-21 22:02:36 +0000758echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000759echo "configure:760: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +0000760
761ac_ext=c
762# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
763ac_cpp='$CPP $CPPFLAGS'
764ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
765ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
766cross_compiling=$ac_cv_prog_cc_cross
767
768cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +0000769#line 770 "configure"
Guido van Rossumf78abae1997-01-21 22:02:36 +0000770#include "confdefs.h"
771main(){return(0);}
772EOF
Guido van Rossum91922671997-10-09 20:24:13 +0000773if { (eval echo configure:774: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossumf78abae1997-01-21 22:02:36 +0000774 ac_cv_prog_cc_works=yes
775 # If we can't run a trivial program, we are probably using a cross compiler.
776 if (./conftest; exit) 2>/dev/null; then
777 ac_cv_prog_cc_cross=no
778 else
779 ac_cv_prog_cc_cross=yes
780 fi
781else
782 echo "configure: failed program was:" >&5
783 cat conftest.$ac_ext >&5
784 ac_cv_prog_cc_works=no
785fi
786rm -fr conftest*
787
788echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
789if test $ac_cv_prog_cc_works = no; then
790 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
791fi
792echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000793echo "configure:794: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +0000794echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
795cross_compiling=$ac_cv_prog_cc_cross
796
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000797echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000798echo "configure:799: checking whether we are using GNU C" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000799if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
800 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000801else
802 cat > conftest.c <<EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +0000803#ifdef __GNUC__
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000804 yes;
Guido van Rossum627b2d71993-12-24 10:39:16 +0000805#endif
806EOF
Guido van Rossum91922671997-10-09 20:24:13 +0000807if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:808: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000808 ac_cv_prog_gcc=yes
809else
810 ac_cv_prog_gcc=no
811fi
812fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000813
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000814echo "$ac_t""$ac_cv_prog_gcc" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +0000815
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000816if test $ac_cv_prog_gcc = yes; then
817 GCC=yes
Guido van Rossumf78abae1997-01-21 22:02:36 +0000818 ac_test_CFLAGS="${CFLAGS+set}"
819 ac_save_CFLAGS="$CFLAGS"
820 CFLAGS=
821 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000822echo "configure:823: checking whether ${CC-cc} accepts -g" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +0000823if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000824 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000825else
826 echo 'void f(){}' > conftest.c
827if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
Guido van Rossumf78abae1997-01-21 22:02:36 +0000828 ac_cv_prog_cc_g=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000829else
Guido van Rossumf78abae1997-01-21 22:02:36 +0000830 ac_cv_prog_cc_g=no
Guido van Rossum627b2d71993-12-24 10:39:16 +0000831fi
832rm -f conftest*
833
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000834fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000835
Guido van Rossumf78abae1997-01-21 22:02:36 +0000836echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
837 if test "$ac_test_CFLAGS" = set; then
838 CFLAGS="$ac_save_CFLAGS"
839 elif test $ac_cv_prog_cc_g = yes; then
840 CFLAGS="-g -O2"
841 else
842 CFLAGS="-O2"
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000843 fi
844else
845 GCC=
846 test "${CFLAGS+set}" = set || CFLAGS="-g"
847fi
848
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000849
Guido van Rossum24b1e751997-08-21 02:29:16 +0000850case $ac_sys_system in
851hp*|HP*)
852 case $CC in
853 cc|*/cc) CC="$CC -Aa -D_HPUX_SOURCE";;
854 esac;;
855esac
856
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000857# LINKCC is the command that links the python executable -- default is $(CC).
858# This is altered for AIX in order to build the export list before linking.
859
860echo $ac_n "checking LINKCC""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000861echo "configure:862: checking LINKCC" >&5
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000862if test -z "$LINKCC"
863then
864 case $ac_sys_system in
865 AIX*)
Guido van Rossum45140f91997-08-29 18:44:06 +0000866 LINKCC="\$(srcdir)/makexp_aix python.exp \"\" \$(LIBRARY); \$(PURIFY) \$(CC)";;
Guido van Rossum25f93031997-08-18 16:00:04 +0000867 *) LINKCC="\$(PURIFY) \$(CC)";;
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000868 esac
869fi
870echo "$ac_t""$LINKCC" 1>&6
871
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000872# Extract the first word of "ranlib", so it can be a program name with args.
873set dummy ranlib; ac_word=$2
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000874echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000875echo "configure:876: checking for $ac_word" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000876if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
877 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000878else
879 if test -n "$RANLIB"; then
880 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
881else
Guido van Rossum7f43da71994-08-01 12:15:30 +0000882 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
883 for ac_dir in $PATH; do
884 test -z "$ac_dir" && ac_dir=.
885 if test -f $ac_dir/$ac_word; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000886 ac_cv_prog_RANLIB="ranlib"
Guido van Rossum627b2d71993-12-24 10:39:16 +0000887 break
888 fi
889 done
Guido van Rossum7f43da71994-08-01 12:15:30 +0000890 IFS="$ac_save_ifs"
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000891 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
Guido van Rossum627b2d71993-12-24 10:39:16 +0000892fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000893fi
894RANLIB="$ac_cv_prog_RANLIB"
895if test -n "$RANLIB"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000896 echo "$ac_t""$RANLIB" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000897else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000898 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000899fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000900
901
Guido van Rossum7f43da71994-08-01 12:15:30 +0000902for ac_prog in ar aal
903do
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000904# Extract the first word of "$ac_prog", so it can be a program name with args.
905set dummy $ac_prog; ac_word=$2
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000906echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000907echo "configure:908: checking for $ac_word" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000908if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
909 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000910else
911 if test -n "$AR"; then
912 ac_cv_prog_AR="$AR" # Let the user override the test.
913else
Guido van Rossum7f43da71994-08-01 12:15:30 +0000914 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
915 for ac_dir in $PATH; do
916 test -z "$ac_dir" && ac_dir=.
917 if test -f $ac_dir/$ac_word; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000918 ac_cv_prog_AR="$ac_prog"
Guido van Rossum7f43da71994-08-01 12:15:30 +0000919 break
920 fi
921 done
922 IFS="$ac_save_ifs"
923fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000924fi
925AR="$ac_cv_prog_AR"
926if test -n "$AR"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000927 echo "$ac_t""$AR" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000928else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000929 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000930fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000931
932test -n "$AR" && break
933done
934test -n "$AR" || AR="ar"
935
936
Guido van Rossumda88dad1995-01-26 00:46:29 +0000937
938
Guido van Rossumb1ba03f1994-08-19 15:34:50 +0000939# Install just never works :-(
940if test -z "$INSTALL"
Guido van Rossumda88dad1995-01-26 00:46:29 +0000941then
942 INSTALL=cp
943 INSTALL_PROGRAM=cp
944 INSTALL_DATA=cp
945else
946 INSTALL_PROGRAM="$INSTALL"
947 INSTALL_DATA="$INSTALL -m 644"
Guido van Rossumb1ba03f1994-08-19 15:34:50 +0000948fi
949
950# Optimizer/debugger flags passed between Makefiles
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000951
Guido van Rossumb1ba03f1994-08-19 15:34:50 +0000952if test -z "$OPT"
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000953then
Guido van Rossumedca74a1997-07-18 23:29:40 +0000954 case $GCC in
955 yes)
956 case $ac_cv_prog_cc_g in
957 yes) OPT="-g -O2";;
958 *) OPT="-O2";;
959 esac
960 ;;
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000961 *) OPT="-O";;
962 esac
Guido van Rossumb1ba03f1994-08-19 15:34:50 +0000963fi
964
Guido van Rossum563e7081996-09-10 18:20:48 +0000965if test "$ac_arch_flags"
Guido van Rossuma68acba1996-07-31 17:36:39 +0000966then
967 OPT="$OPT $ac_arch_flags"
968fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000969# checks for UNIX variants that set C preprocessor variables
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000970echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +0000971echo "configure:972: checking how to run the C preprocessor" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000972# On Suns, sometimes $CPP names a directory.
973if test -n "$CPP" && test -d "$CPP"; then
974 CPP=
975fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000976if test -z "$CPP"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000977if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
978 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000979else
980 # This must be in double quotes, not single quotes, because CPP may get
981 # substituted into the Makefile and "${CC-cc}" will confuse make.
Guido van Rossum627b2d71993-12-24 10:39:16 +0000982 CPP="${CC-cc} -E"
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000983 # On the NeXT, cc -E runs the code through the compiler's parser,
984 # not just through cpp.
985 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +0000986#line 987 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +0000987#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000988#include <assert.h>
Guido van Rossum627b2d71993-12-24 10:39:16 +0000989Syntax Error
990EOF
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000991ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum91922671997-10-09 20:24:13 +0000992{ (eval echo configure:993: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000993ac_err=`grep -v '^ *+' conftest.out`
Guido van Rossum7f43da71994-08-01 12:15:30 +0000994if test -z "$ac_err"; then
995 :
996else
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000997 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +0000998 echo "configure: failed program was:" >&5
999 cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +00001000 rm -rf conftest*
1001 CPP="${CC-cc} -E -traditional-cpp"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001002 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001003#line 1004 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001004#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001005#include <assert.h>
Guido van Rossum7f43da71994-08-01 12:15:30 +00001006Syntax Error
1007EOF
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001008ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum91922671997-10-09 20:24:13 +00001009{ (eval echo configure:1010: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001010ac_err=`grep -v '^ *+' conftest.out`
Guido van Rossum7f43da71994-08-01 12:15:30 +00001011if test -z "$ac_err"; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001012 :
1013else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001014 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001015 echo "configure: failed program was:" >&5
1016 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00001017 rm -rf conftest*
1018 CPP=/lib/cpp
1019fi
1020rm -f conftest*
1021fi
Guido van Rossum7f43da71994-08-01 12:15:30 +00001022rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001023 ac_cv_prog_CPP="$CPP"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001024fi
Guido van Rossume77438c1995-09-13 18:59:59 +00001025 CPP="$ac_cv_prog_CPP"
1026else
1027 ac_cv_prog_CPP="$CPP"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001028fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001029echo "$ac_t""$CPP" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00001030
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001031echo $ac_n "checking for AIX""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001032echo "configure:1033: checking for AIX" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001033cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001034#line 1035 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001035#include "confdefs.h"
1036#ifdef _AIX
1037 yes
1038#endif
1039
1040EOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001041if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1042 egrep "yes" >/dev/null 2>&1; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001043 rm -rf conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001044 echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001045#define _ALL_SOURCE 1
1046EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001047
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001048else
1049 rm -rf conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001050 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00001051fi
1052rm -f conftest*
1053
1054
Guido van Rossumf78abae1997-01-21 22:02:36 +00001055ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'`
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001056echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001057echo "configure:1058: checking for minix/config.h" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001058if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1059 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001060else
1061 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001062#line 1063 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001063#include "confdefs.h"
1064#include <minix/config.h>
1065EOF
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001066ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum91922671997-10-09 20:24:13 +00001067{ (eval echo configure:1068: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001068ac_err=`grep -v '^ *+' conftest.out`
Guido van Rossum7f43da71994-08-01 12:15:30 +00001069if test -z "$ac_err"; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001070 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001071 eval "ac_cv_header_$ac_safe=yes"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001072else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001073 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001074 echo "configure: failed program was:" >&5
1075 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001076 rm -rf conftest*
1077 eval "ac_cv_header_$ac_safe=no"
1078fi
1079rm -f conftest*
1080fi
1081if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001082 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001083 MINIX=yes
1084else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001085 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001086MINIX=
Guido van Rossum627b2d71993-12-24 10:39:16 +00001087fi
1088
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001089if test "$MINIX" = yes; then
1090 cat >> confdefs.h <<\EOF
1091#define _POSIX_SOURCE 1
1092EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001093
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001094 cat >> confdefs.h <<\EOF
1095#define _POSIX_1_SOURCE 2
1096EOF
1097
1098 cat >> confdefs.h <<\EOF
1099#define _MINIX 1
1100EOF
1101
1102fi
1103
Guido van Rossumda88dad1995-01-26 00:46:29 +00001104
Guido van Rossum201afe51997-05-14 21:14:44 +00001105echo $ac_n "checking whether $CC accepts -Olimit 1500""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001106echo "configure:1107: checking whether $CC accepts -Olimit 1500" >&5
Guido van Rossum201afe51997-05-14 21:14:44 +00001107if eval "test \"`echo '$''{'ac_cv_olimit_ok'+set}'`\" = set"; then
1108 echo $ac_n "(cached) $ac_c" 1>&6
1109else
1110 ac_save_cc="$CC"
1111CC="$CC -Olimit 1500"
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001112if test "$cross_compiling" = yes; then
1113 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1114else
1115 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001116#line 1117 "configure"
Guido van Rossum201afe51997-05-14 21:14:44 +00001117#include "confdefs.h"
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001118int main() { return 0; }
Guido van Rossum201afe51997-05-14 21:14:44 +00001119EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001120if { (eval echo configure:1121: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001121then
Guido van Rossum201afe51997-05-14 21:14:44 +00001122 ac_cv_olimit_ok=yes
1123else
1124 echo "configure: failed program was:" >&5
1125 cat conftest.$ac_ext >&5
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001126 rm -fr conftest*
Guido van Rossum201afe51997-05-14 21:14:44 +00001127 ac_cv_olimit_ok=no
1128fi
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001129rm -fr conftest*
1130fi
1131
Guido van Rossum201afe51997-05-14 21:14:44 +00001132CC="$ac_save_cc"
1133fi
1134
1135echo "$ac_t""$ac_cv_olimit_ok" 1>&6
1136if test $ac_cv_olimit_ok = yes; then
Guido van Rossum304dd2d1997-10-20 23:10:56 +00001137 OPT="$OPT -Olimit 1500"
Guido van Rossum91922671997-10-09 20:24:13 +00001138fi
1139
1140echo $ac_n "checking whether $CC accepts -OPT:Olimit=0""... $ac_c" 1>&6
1141echo "configure:1142: checking whether $CC accepts -OPT:Olimit=0" >&5
1142if eval "test \"`echo '$''{'ac_cv_opt_olimit_ok'+set}'`\" = set"; then
1143 echo $ac_n "(cached) $ac_c" 1>&6
1144else
1145 ac_save_cc="$CC"
1146CC="$CC -OPT:Olimit=0"
1147if test "$cross_compiling" = yes; then
1148 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1149else
1150 cat > conftest.$ac_ext <<EOF
1151#line 1152 "configure"
1152#include "confdefs.h"
1153int main() { return 0; }
1154EOF
1155if { (eval echo configure:1156: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
1156then
1157 ac_cv_opt_olimit_ok=yes
1158else
1159 echo "configure: failed program was:" >&5
1160 cat conftest.$ac_ext >&5
1161 rm -fr conftest*
1162 ac_cv_opt_olimit_ok=no
1163fi
1164rm -fr conftest*
1165fi
1166
1167CC="$ac_save_cc"
1168fi
1169
1170echo "$ac_t""$ac_cv_opt_olimit_ok" 1>&6
Guido van Rossum2efa34b1997-10-23 17:43:11 +00001171if test $ac_cv_opt_olimit_ok = yes; then
Guido van Rossum304dd2d1997-10-20 23:10:56 +00001172 OPT="$OPT -OPT:Olimit=0"
Guido van Rossum201afe51997-05-14 21:14:44 +00001173fi
1174
Guido van Rossum84e7b241996-08-19 21:59:00 +00001175# check for ANSI or K&R ("traditional") preprocessor
1176echo $ac_n "checking for C preprocessor type""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001177echo "configure:1178: checking for C preprocessor type" >&5
Guido van Rossum84e7b241996-08-19 21:59:00 +00001178cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001179#line 1180 "configure"
Guido van Rossum84e7b241996-08-19 21:59:00 +00001180#include "confdefs.h"
1181
1182#define spam(name, doc) {#name, &name, #name "() -- " doc}
1183int foo;
1184struct {char *name; int *addr; char *doc;} desc = spam(foo, "something");
1185
Guido van Rossumf78abae1997-01-21 22:02:36 +00001186int main() {
Guido van Rossum84e7b241996-08-19 21:59:00 +00001187;
1188; return 0; }
1189EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001190if { (eval echo configure:1191: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum84e7b241996-08-19 21:59:00 +00001191 rm -rf conftest*
1192 cpp_type=ansi
1193else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001194 echo "configure: failed program was:" >&5
1195 cat conftest.$ac_ext >&5
Guido van Rossum84e7b241996-08-19 21:59:00 +00001196 rm -rf conftest*
1197 cat >> confdefs.h <<\EOF
1198#define HAVE_OLD_CPP 1
1199EOF
1200 cpp_type=traditional
1201fi
1202rm -f conftest*
Guido van Rossum84e7b241996-08-19 21:59:00 +00001203echo "$ac_t""$cpp_type" 1>&6
1204
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001205# checks for header files
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001206echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001207echo "configure:1208: checking for ANSI C header files" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001208if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1209 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001210else
1211 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001212#line 1213 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001213#include "confdefs.h"
1214#include <stdlib.h>
1215#include <stdarg.h>
1216#include <string.h>
1217#include <float.h>
1218EOF
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001219ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum91922671997-10-09 20:24:13 +00001220{ (eval echo configure:1221: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001221ac_err=`grep -v '^ *+' conftest.out`
Guido van Rossum7f43da71994-08-01 12:15:30 +00001222if test -z "$ac_err"; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001223 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001224 ac_cv_header_stdc=yes
1225else
1226 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001227 echo "configure: failed program was:" >&5
1228 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00001229 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001230 ac_cv_header_stdc=no
1231fi
1232rm -f conftest*
1233
1234if test $ac_cv_header_stdc = yes; then
1235 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1236cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001237#line 1238 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001238#include "confdefs.h"
1239#include <string.h>
1240EOF
1241if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1242 egrep "memchr" >/dev/null 2>&1; then
1243 :
1244else
1245 rm -rf conftest*
1246 ac_cv_header_stdc=no
1247fi
1248rm -f conftest*
1249
1250fi
1251
1252if test $ac_cv_header_stdc = yes; then
1253 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1254cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001255#line 1256 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001256#include "confdefs.h"
1257#include <stdlib.h>
1258EOF
1259if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1260 egrep "free" >/dev/null 2>&1; then
1261 :
1262else
1263 rm -rf conftest*
1264 ac_cv_header_stdc=no
1265fi
1266rm -f conftest*
1267
1268fi
1269
1270if test $ac_cv_header_stdc = yes; then
1271 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1272if test "$cross_compiling" = yes; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001273 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001274else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001275 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001276#line 1277 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001277#include "confdefs.h"
1278#include <ctype.h>
1279#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1280#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001281#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
Guido van Rossum627b2d71993-12-24 10:39:16 +00001282int main () { int i; for (i = 0; i < 256; i++)
1283if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1284exit (0); }
1285
1286EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001287if { (eval echo configure:1288: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Guido van Rossumf78abae1997-01-21 22:02:36 +00001288then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001289 :
1290else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001291 echo "configure: failed program was:" >&5
1292 cat conftest.$ac_ext >&5
1293 rm -fr conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001294 ac_cv_header_stdc=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001295fi
1296rm -fr conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001297fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00001298
1299fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001300fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001301
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001302echo "$ac_t""$ac_cv_header_stdc" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001303if test $ac_cv_header_stdc = yes; then
1304 cat >> confdefs.h <<\EOF
1305#define STDC_HEADERS 1
1306EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001307
1308fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00001309
Guido van Rossum96013151997-10-08 22:47:52 +00001310for ac_hdr in dlfcn.h fcntl.h limits.h locale.h ncurses.h pthread.h \
Guido van Rossum2d38f911996-06-26 19:47:01 +00001311signal.h stdarg.h stddef.h stdlib.h thread.h unistd.h utime.h \
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001312sys/audioio.h sys/file.h sys/lock.h \
1313sys/param.h sys/select.h sys/time.h sys/times.h \
Guido van Rossum2d38f911996-06-26 19:47:01 +00001314sys/un.h sys/utsname.h sys/wait.h
Guido van Rossum627b2d71993-12-24 10:39:16 +00001315do
Guido van Rossumf78abae1997-01-21 22:02:36 +00001316ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001317echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001318echo "configure:1319: checking for $ac_hdr" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001319if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1320 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001321else
1322 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001323#line 1324 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001324#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001325#include <$ac_hdr>
Guido van Rossum627b2d71993-12-24 10:39:16 +00001326EOF
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001327ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum91922671997-10-09 20:24:13 +00001328{ (eval echo configure:1329: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001329ac_err=`grep -v '^ *+' conftest.out`
Guido van Rossum7f43da71994-08-01 12:15:30 +00001330if test -z "$ac_err"; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001331 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001332 eval "ac_cv_header_$ac_safe=yes"
1333else
1334 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001335 echo "configure: failed program was:" >&5
1336 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001337 rm -rf conftest*
1338 eval "ac_cv_header_$ac_safe=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001339fi
1340rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001341fi
1342if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001343 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00001344 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001345 cat >> confdefs.h <<EOF
1346#define $ac_tr_hdr 1
1347EOF
1348
1349else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001350 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001351fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00001352done
1353
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001354ac_header_dirent=no
1355for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
1356do
Guido van Rossumf78abae1997-01-21 22:02:36 +00001357ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001358echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001359echo "configure:1360: checking for $ac_hdr that defines DIR" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001360if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
1361 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00001362else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001363 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001364#line 1365 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001365#include "confdefs.h"
1366#include <sys/types.h>
1367#include <$ac_hdr>
Guido van Rossumf78abae1997-01-21 22:02:36 +00001368int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001369DIR *dirp = 0;
1370; return 0; }
1371EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001372if { (eval echo configure:1373: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001373 rm -rf conftest*
1374 eval "ac_cv_header_dirent_$ac_safe=yes"
1375else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001376 echo "configure: failed program was:" >&5
1377 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001378 rm -rf conftest*
1379 eval "ac_cv_header_dirent_$ac_safe=no"
1380fi
1381rm -f conftest*
Guido van Rossum627b2d71993-12-24 10:39:16 +00001382fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001383if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001384 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00001385 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001386 cat >> confdefs.h <<EOF
1387#define $ac_tr_hdr 1
1388EOF
1389 ac_header_dirent=$ac_hdr; break
1390else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001391 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001392fi
1393done
1394# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
1395if test $ac_header_dirent = dirent.h; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00001396echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001397echo "configure:1398: checking for opendir in -ldir" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001398ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001399if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001400 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001401else
1402 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001403LIBS="-ldir $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001404cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001405#line 1406 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001406#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001407/* Override any gcc2 internal prototype to avoid an error. */
1408/* We use char because int might match the return type of a gcc2
1409 builtin and then its argument prototype would still apply. */
1410char opendir();
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001411
Guido van Rossumf78abae1997-01-21 22:02:36 +00001412int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001413opendir()
1414; return 0; }
1415EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001416if { (eval echo configure:1417: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001417 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001418 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001419else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001420 echo "configure: failed program was:" >&5
1421 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001422 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001423 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001424fi
1425rm -f conftest*
1426LIBS="$ac_save_LIBS"
1427
1428fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001429if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001430 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001431 LIBS="$LIBS -ldir"
1432else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001433 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001434fi
1435
1436else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001437echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001438echo "configure:1439: checking for opendir in -lx" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001439ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001440if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001441 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001442else
1443 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001444LIBS="-lx $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001445cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001446#line 1447 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001447#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001448/* Override any gcc2 internal prototype to avoid an error. */
1449/* We use char because int might match the return type of a gcc2
1450 builtin and then its argument prototype would still apply. */
1451char opendir();
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001452
Guido van Rossumf78abae1997-01-21 22:02:36 +00001453int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001454opendir()
1455; return 0; }
1456EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001457if { (eval echo configure:1458: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001458 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001459 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001460else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001461 echo "configure: failed program was:" >&5
1462 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001463 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001464 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001465fi
1466rm -f conftest*
1467LIBS="$ac_save_LIBS"
1468
1469fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001470if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001471 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001472 LIBS="$LIBS -lx"
1473else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001474 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001475fi
1476
1477fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00001478
1479
1480# checks for typedefs
Guido van Rossumda88dad1995-01-26 00:46:29 +00001481was_it_defined=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001482echo $ac_n "checking for clock_t in time.h""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001483echo "configure:1484: checking for clock_t in time.h" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001484cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001485#line 1486 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001486#include "confdefs.h"
1487#include <time.h>
1488EOF
1489if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1490 egrep "clock_t" >/dev/null 2>&1; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00001491 rm -rf conftest*
1492 was_it_defined=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00001493else
1494 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001495 cat >> confdefs.h <<\EOF
1496#define clock_t long
1497EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001498
1499fi
1500rm -f conftest*
1501
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001502echo "$ac_t""$was_it_defined" 1>&6
Guido van Rossumda88dad1995-01-26 00:46:29 +00001503
Guido van Rossum84e7b241996-08-19 21:59:00 +00001504# Add some code to confdefs.h so that the test for off_t works on SCO
1505cat >> confdefs.h <<\EOF
1506#if defined(SCO_DS)
1507#undef _OFF_T
1508#endif
1509EOF
1510
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001511echo $ac_n "checking for mode_t""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001512echo "configure:1513: checking for mode_t" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001513if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
1514 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001515else
1516 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001517#line 1518 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001518#include "confdefs.h"
1519#include <sys/types.h>
1520#if STDC_HEADERS
1521#include <stdlib.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00001522#include <stddef.h>
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001523#endif
1524EOF
1525if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Guido van Rossumf78abae1997-01-21 22:02:36 +00001526 egrep "mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001527 rm -rf conftest*
1528 ac_cv_type_mode_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00001529else
1530 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001531 ac_cv_type_mode_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001532fi
1533rm -f conftest*
1534
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001535fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001536echo "$ac_t""$ac_cv_type_mode_t" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001537if test $ac_cv_type_mode_t = no; then
1538 cat >> confdefs.h <<\EOF
1539#define mode_t int
1540EOF
1541
1542fi
1543
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001544echo $ac_n "checking for off_t""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001545echo "configure:1546: checking for off_t" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001546if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
1547 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001548else
1549 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001550#line 1551 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001551#include "confdefs.h"
1552#include <sys/types.h>
1553#if STDC_HEADERS
1554#include <stdlib.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00001555#include <stddef.h>
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001556#endif
1557EOF
1558if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Guido van Rossumf78abae1997-01-21 22:02:36 +00001559 egrep "off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001560 rm -rf conftest*
1561 ac_cv_type_off_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00001562else
1563 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001564 ac_cv_type_off_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001565fi
1566rm -f conftest*
1567
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001568fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001569echo "$ac_t""$ac_cv_type_off_t" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001570if test $ac_cv_type_off_t = no; then
1571 cat >> confdefs.h <<\EOF
1572#define off_t long
1573EOF
1574
1575fi
1576
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001577echo $ac_n "checking for pid_t""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001578echo "configure:1579: checking for pid_t" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001579if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
1580 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001581else
1582 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001583#line 1584 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001584#include "confdefs.h"
1585#include <sys/types.h>
1586#if STDC_HEADERS
1587#include <stdlib.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00001588#include <stddef.h>
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001589#endif
1590EOF
1591if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Guido van Rossumf78abae1997-01-21 22:02:36 +00001592 egrep "pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001593 rm -rf conftest*
1594 ac_cv_type_pid_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00001595else
1596 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001597 ac_cv_type_pid_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001598fi
1599rm -f conftest*
1600
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001601fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001602echo "$ac_t""$ac_cv_type_pid_t" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001603if test $ac_cv_type_pid_t = no; then
1604 cat >> confdefs.h <<\EOF
1605#define pid_t int
1606EOF
1607
1608fi
1609
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001610echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001611echo "configure:1612: checking return type of signal handlers" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001612if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
1613 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001614else
1615 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001616#line 1617 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001617#include "confdefs.h"
1618#include <sys/types.h>
1619#include <signal.h>
1620#ifdef signal
1621#undef signal
1622#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001623#ifdef __cplusplus
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001624extern "C" void (*signal (int, void (*)(int)))(int);
1625#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001626void (*signal ()) ();
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001627#endif
1628
Guido van Rossumf78abae1997-01-21 22:02:36 +00001629int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001630int i;
1631; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00001632EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001633if { (eval echo configure:1634: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001634 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001635 ac_cv_type_signal=void
Guido van Rossum627b2d71993-12-24 10:39:16 +00001636else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001637 echo "configure: failed program was:" >&5
1638 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00001639 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001640 ac_cv_type_signal=int
Guido van Rossum627b2d71993-12-24 10:39:16 +00001641fi
1642rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001643fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001644
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001645echo "$ac_t""$ac_cv_type_signal" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001646cat >> confdefs.h <<EOF
1647#define RETSIGTYPE $ac_cv_type_signal
1648EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001649
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001650
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001651echo $ac_n "checking for size_t""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001652echo "configure:1653: checking for size_t" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001653if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
1654 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001655else
1656 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001657#line 1658 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001658#include "confdefs.h"
1659#include <sys/types.h>
1660#if STDC_HEADERS
1661#include <stdlib.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00001662#include <stddef.h>
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001663#endif
1664EOF
1665if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Guido van Rossumf78abae1997-01-21 22:02:36 +00001666 egrep "size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001667 rm -rf conftest*
1668 ac_cv_type_size_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00001669else
1670 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001671 ac_cv_type_size_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001672fi
1673rm -f conftest*
1674
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001675fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001676echo "$ac_t""$ac_cv_type_size_t" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001677if test $ac_cv_type_size_t = no; then
1678 cat >> confdefs.h <<\EOF
1679#define size_t unsigned
1680EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001681
1682fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001683
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001684echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001685echo "configure:1686: checking for uid_t in sys/types.h" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001686if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
1687 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001688else
1689 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001690#line 1691 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001691#include "confdefs.h"
1692#include <sys/types.h>
1693EOF
1694if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1695 egrep "uid_t" >/dev/null 2>&1; then
1696 rm -rf conftest*
1697 ac_cv_type_uid_t=yes
1698else
1699 rm -rf conftest*
1700 ac_cv_type_uid_t=no
1701fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00001702rm -f conftest*
1703
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001704fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001705
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001706echo "$ac_t""$ac_cv_type_uid_t" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001707if test $ac_cv_type_uid_t = no; then
1708 cat >> confdefs.h <<\EOF
1709#define uid_t int
1710EOF
1711
1712 cat >> confdefs.h <<\EOF
1713#define gid_t int
1714EOF
1715
1716fi
1717
Guido van Rossum627b2d71993-12-24 10:39:16 +00001718
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001719echo $ac_n "checking size of int""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001720echo "configure:1721: checking size of int" >&5
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001721if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
1722 echo $ac_n "(cached) $ac_c" 1>&6
1723else
1724 if test "$cross_compiling" = yes; then
1725 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1726else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001727 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001728#line 1729 "configure"
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001729#include "confdefs.h"
1730#include <stdio.h>
1731main()
1732{
1733 FILE *f=fopen("conftestval", "w");
1734 if (!f) exit(1);
1735 fprintf(f, "%d\n", sizeof(int));
1736 exit(0);
1737}
1738EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001739if { (eval echo configure:1740: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Guido van Rossumf78abae1997-01-21 22:02:36 +00001740then
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001741 ac_cv_sizeof_int=`cat conftestval`
1742else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001743 echo "configure: failed program was:" >&5
1744 cat conftest.$ac_ext >&5
1745 rm -fr conftest*
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001746 ac_cv_sizeof_int=0
1747fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001748rm -fr conftest*
1749fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00001750
1751fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001752echo "$ac_t""$ac_cv_sizeof_int" 1>&6
1753cat >> confdefs.h <<EOF
1754#define SIZEOF_INT $ac_cv_sizeof_int
1755EOF
1756
1757
1758echo $ac_n "checking size of long""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001759echo "configure:1760: checking size of long" >&5
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001760if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
1761 echo $ac_n "(cached) $ac_c" 1>&6
1762else
1763 if test "$cross_compiling" = yes; then
1764 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1765else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001766 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001767#line 1768 "configure"
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001768#include "confdefs.h"
1769#include <stdio.h>
1770main()
1771{
1772 FILE *f=fopen("conftestval", "w");
1773 if (!f) exit(1);
1774 fprintf(f, "%d\n", sizeof(long));
1775 exit(0);
1776}
1777EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001778if { (eval echo configure:1779: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Guido van Rossumf78abae1997-01-21 22:02:36 +00001779then
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001780 ac_cv_sizeof_long=`cat conftestval`
1781else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001782 echo "configure: failed program was:" >&5
1783 cat conftest.$ac_ext >&5
1784 rm -fr conftest*
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001785 ac_cv_sizeof_long=0
1786fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001787rm -fr conftest*
1788fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00001789
1790fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001791echo "$ac_t""$ac_cv_sizeof_long" 1>&6
1792cat >> confdefs.h <<EOF
1793#define SIZEOF_LONG $ac_cv_sizeof_long
1794EOF
1795
1796
Guido van Rossum0a516c91994-09-12 10:58:40 +00001797
1798# Set info about shared libraries.
Guido van Rossum0a516c91994-09-12 10:58:40 +00001799
1800
1801
1802
Guido van Rossum0a516c91994-09-12 10:58:40 +00001803# SO is the extension of shared libraries `(including the dot!)
1804# -- usually .so, .sl on HP-UX
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001805echo $ac_n "checking SO""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001806echo "configure:1807: checking SO" >&5
Guido van Rossum0a516c91994-09-12 10:58:40 +00001807if test -z "$SO"
1808then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001809 case $ac_sys_system in
Guido van Rossum563e7081996-09-10 18:20:48 +00001810 hp*|HP*) SO=.sl;;
1811 *) SO=.so;;
Guido van Rossum0a516c91994-09-12 10:58:40 +00001812 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00001813fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001814echo "$ac_t""$SO" 1>&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00001815# LDSHARED is the ld *command* used to create shared library
1816# -- "ld" on SunOS 4.x.x, "ld -G" on SunOS 5.x, "ld -shared" on IRIX 5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001817echo $ac_n "checking LDSHARED""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001818echo "configure:1819: checking LDSHARED" >&5
Guido van Rossum0a516c91994-09-12 10:58:40 +00001819if test -z "$LDSHARED"
1820then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001821 case $ac_sys_system/$ac_sys_release in
Guido van Rossum45140f91997-08-29 18:44:06 +00001822 AIX*) LDSHARED="\$(srcdir)/ld_so_aix \$(CC)";;
Guido van Rossum07397971997-04-29 21:49:50 +00001823 IRIX/5*) LDSHARED="ld -shared";;
Guido van Rossum91922671997-10-09 20:24:13 +00001824 IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00001825 SunOS/4*) LDSHARED="ld";;
1826 SunOS/5*) LDSHARED="ld -G";;
1827 hp*|HP*) LDSHARED="ld -b";;
Guido van Rossumda88dad1995-01-26 00:46:29 +00001828 OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";;
1829 DYNIX/ptx*) LDSHARED="ld -G";;
Guido van Rossum563e7081996-09-10 18:20:48 +00001830 next/*) LDSHARED='$(CC) $(CFLAGS) -nostdlib -r';;
Guido van Rossum81652ab1996-07-21 02:53:27 +00001831 Linux*) LDSHARED="gcc -shared";;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001832 FreeBSD*) LDSHARED="ld -Bshareable";;
Guido van Rossum84e7b241996-08-19 21:59:00 +00001833 SCO_SV*) LDSHARED="cc -G -KPIC -Ki486 -belf -Wl,-Bexport";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00001834 *) LDSHARED="ld";;
1835 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00001836fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001837echo "$ac_t""$LDSHARED" 1>&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00001838# CCSHARED are the C *flags* used to create objects to go into a shared
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001839# library -- this is only needed for a few systems
1840echo $ac_n "checking CCSHARED""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001841echo "configure:1842: checking CCSHARED" >&5
Guido van Rossum0a516c91994-09-12 10:58:40 +00001842if test -z "$CCSHARED"
1843then
Guido van Rossum07397971997-04-29 21:49:50 +00001844 case $ac_sys_system/$ac_sys_release in
Guido van Rossumaf07a441995-02-13 19:45:27 +00001845 hp*|HP*) if test "$GCC" = yes;
1846 then CCSHARED="-fpic";
1847 else CCSHARED="+z";
1848 fi;;
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001849 Linux*) CCSHARED="-fpic";;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001850 FreeBSD*) CCSHARED="-fpic";;
Guido van Rossum84e7b241996-08-19 21:59:00 +00001851 SCO_SV*) CCSHARED="-KPIC -dy -Bdynamic";;
Guido van Rossum91922671997-10-09 20:24:13 +00001852 IRIX*/6*) CCSHARED="-all";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00001853 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00001854fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001855echo "$ac_t""$CCSHARED" 1>&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00001856# LINKFORSHARED are the flags passed to the $(CC) command that links
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001857# the python executable -- this is only needed for a few systems
1858echo $ac_n "checking LINKFORSHARED""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001859echo "configure:1860: checking LINKFORSHARED" >&5
Guido van Rossum0a516c91994-09-12 10:58:40 +00001860if test -z "$LINKFORSHARED"
1861then
Guido van Rossum07397971997-04-29 21:49:50 +00001862 case $ac_sys_system/$ac_sys_release in
Guido van Rossume4766f61997-05-13 21:04:26 +00001863 AIX*) LINKFORSHARED='-Wl,-bE:$(srcdir)/python.exp -lld';;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001864 hp*|HP*)
Guido van Rossum304dd2d1997-10-20 23:10:56 +00001865 LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001866 Linux*) LINKFORSHARED="-rdynamic";;
Guido van Rossum749af7c1997-08-16 14:35:52 +00001867 next/*) LINKFORSHARED="-u libsys_s";;
Guido van Rossum84e7b241996-08-19 21:59:00 +00001868 SCO_SV*) LINKFORSHARED="-Bdynamic -dy -Wl,-Bexport";;
Guido van Rossum91922671997-10-09 20:24:13 +00001869 IRIX*/6*) LINKFORSHARED="-all";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00001870 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00001871fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001872echo "$ac_t""$LINKFORSHARED" 1>&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00001873
Guido van Rossum627b2d71993-12-24 10:39:16 +00001874# checks for libraries
Guido van Rossumf78abae1997-01-21 22:02:36 +00001875echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001876echo "configure:1877: checking for dlopen in -ldl" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001877ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001878if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001879 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001880else
1881 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001882LIBS="-ldl $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001883cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001884#line 1885 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001885#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001886/* Override any gcc2 internal prototype to avoid an error. */
1887/* We use char because int might match the return type of a gcc2
1888 builtin and then its argument prototype would still apply. */
1889char dlopen();
Guido van Rossum627b2d71993-12-24 10:39:16 +00001890
Guido van Rossumf78abae1997-01-21 22:02:36 +00001891int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001892dlopen()
1893; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00001894EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001895if { (eval echo configure:1896: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001896 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001897 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001898else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001899 echo "configure: failed program was:" >&5
1900 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001901 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001902 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001903fi
1904rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001905LIBS="$ac_save_LIBS"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001906
Guido van Rossum627b2d71993-12-24 10:39:16 +00001907fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001908if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001909 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00001910 ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1911 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001912 cat >> confdefs.h <<EOF
1913#define $ac_tr_lib 1
1914EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001915
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001916 LIBS="-ldl $LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001917
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001918else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001919 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001920fi
1921 # Dynamic linking for SunOS/Solaris and SYSV
Guido van Rossumf78abae1997-01-21 22:02:36 +00001922echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001923echo "configure:1924: checking for shl_load in -ldld" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001924ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001925if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001926 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001927else
1928 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001929LIBS="-ldld $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001930cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001931#line 1932 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001932#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001933/* Override any gcc2 internal prototype to avoid an error. */
1934/* We use char because int might match the return type of a gcc2
1935 builtin and then its argument prototype would still apply. */
1936char shl_load();
Guido van Rossum627b2d71993-12-24 10:39:16 +00001937
Guido van Rossumf78abae1997-01-21 22:02:36 +00001938int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001939shl_load()
1940; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00001941EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001942if { (eval echo configure:1943: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001943 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001944 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001945else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001946 echo "configure: failed program was:" >&5
1947 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001948 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001949 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001950fi
1951rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001952LIBS="$ac_save_LIBS"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001953
Guido van Rossum627b2d71993-12-24 10:39:16 +00001954fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001955if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001956 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00001957 ac_tr_lib=HAVE_LIB`echo dld | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1958 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001959 cat >> confdefs.h <<EOF
1960#define $ac_tr_lib 1
1961EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001962
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001963 LIBS="-ldld $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001964
1965else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001966 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001967fi
1968 # Dynamic linking for HP-UX
Guido van Rossumf78abae1997-01-21 22:02:36 +00001969echo $ac_n "checking for getpwnam in -lsun""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00001970echo "configure:1971: checking for getpwnam in -lsun" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001971ac_lib_var=`echo sun'_'getpwnam | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001972if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001973 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001974else
1975 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001976LIBS="-lsun $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001977cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001978#line 1979 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001979#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001980/* Override any gcc2 internal prototype to avoid an error. */
1981/* We use char because int might match the return type of a gcc2
1982 builtin and then its argument prototype would still apply. */
1983char getpwnam();
Guido van Rossum7f43da71994-08-01 12:15:30 +00001984
Guido van Rossumf78abae1997-01-21 22:02:36 +00001985int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001986getpwnam()
1987; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00001988EOF
Guido van Rossum91922671997-10-09 20:24:13 +00001989if { (eval echo configure:1990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00001990 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001991 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001992else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001993 echo "configure: failed program was:" >&5
1994 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001995 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001996 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001997fi
1998rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001999LIBS="$ac_save_LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002000
Guido van Rossum7f43da71994-08-01 12:15:30 +00002001fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002002if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002003 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00002004 ac_tr_lib=HAVE_LIB`echo sun | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2005 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002006 cat >> confdefs.h <<EOF
2007#define $ac_tr_lib 1
2008EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00002009
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002010 LIBS="-lsun $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002011
2012else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002013 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002014fi
2015 # NIS (== YP) interface for IRIX 4
Guido van Rossumda88dad1995-01-26 00:46:29 +00002016# The following three (nsl,inet,socket) are needed on Sequent;
2017# the order of checking must be this. Most SVR4 platforms will
2018# need -lsocket and -lnsl. However on SGI IRIX 5, these exist but
2019# broken. I see no elegant solution (probably CHECK_LIB should be
2020# fixed to only add the library if the given entry point is not
2021# satisfied without it).
Guido van Rossum2b3ac691996-08-30 15:18:41 +00002022if test "$ac_sys_system" != IRIX
Guido van Rossumda88dad1995-01-26 00:46:29 +00002023then
Guido van Rossumf78abae1997-01-21 22:02:36 +00002024echo $ac_n "checking for t_open in -lnsl""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002025echo "configure:2026: checking for t_open in -lnsl" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002026ac_lib_var=`echo nsl'_'t_open | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002027if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002028 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002029else
2030 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002031LIBS="-lnsl $LIBS"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002032cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002033#line 2034 "configure"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002034#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002035/* Override any gcc2 internal prototype to avoid an error. */
2036/* We use char because int might match the return type of a gcc2
2037 builtin and then its argument prototype would still apply. */
2038char t_open();
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002039
Guido van Rossumf78abae1997-01-21 22:02:36 +00002040int main() {
Guido van Rossum0ddb0281995-01-17 16:46:14 +00002041t_open()
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002042; return 0; }
2043EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002044if { (eval echo configure:2045: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002045 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002046 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002047else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002048 echo "configure: failed program was:" >&5
2049 cat conftest.$ac_ext >&5
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002050 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002051 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002052fi
2053rm -f conftest*
2054LIBS="$ac_save_LIBS"
2055
2056fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002057if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002058 echo "$ac_t""yes" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002059 LIBS="-lnsl $LIBS"
2060else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002061 echo "$ac_t""no" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002062fi
Guido van Rossum0ddb0281995-01-17 16:46:14 +00002063 # SVR4
Guido van Rossumf78abae1997-01-21 22:02:36 +00002064echo $ac_n "checking for gethostbyname in -linet""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002065echo "configure:2066: checking for gethostbyname in -linet" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002066ac_lib_var=`echo inet'_'gethostbyname | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002067if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002068 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002069else
2070 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002071LIBS="-linet -lnsl $LIBS"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002072cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002073#line 2074 "configure"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002074#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002075/* Override any gcc2 internal prototype to avoid an error. */
2076/* We use char because int might match the return type of a gcc2
2077 builtin and then its argument prototype would still apply. */
2078char gethostbyname();
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002079
Guido van Rossumf78abae1997-01-21 22:02:36 +00002080int main() {
Guido van Rossum0ddb0281995-01-17 16:46:14 +00002081gethostbyname()
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002082; return 0; }
2083EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002084if { (eval echo configure:2085: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002085 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002086 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002087else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002088 echo "configure: failed program was:" >&5
2089 cat conftest.$ac_ext >&5
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002090 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002091 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002092fi
2093rm -f conftest*
2094LIBS="$ac_save_LIBS"
2095
2096fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002097if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002098 echo "$ac_t""yes" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002099 LIBS="-linet $LIBS"
2100else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002101 echo "$ac_t""no" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002102fi
Guido van Rossum0ddb0281995-01-17 16:46:14 +00002103 # Sequent
Guido van Rossumf78abae1997-01-21 22:02:36 +00002104echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002105echo "configure:2106: checking for socket in -lsocket" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002106ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002107if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002108 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002109else
2110 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002111LIBS="-lsocket $LIBS $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002112cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002113#line 2114 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002114#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002115/* Override any gcc2 internal prototype to avoid an error. */
2116/* We use char because int might match the return type of a gcc2
2117 builtin and then its argument prototype would still apply. */
2118char socket();
Guido van Rossum7f43da71994-08-01 12:15:30 +00002119
Guido van Rossumf78abae1997-01-21 22:02:36 +00002120int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002121socket()
2122; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00002123EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002124if { (eval echo configure:2125: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00002125 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002126 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002127else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002128 echo "configure: failed program was:" >&5
2129 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002130 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002131 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002132fi
2133rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002134LIBS="$ac_save_LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002135
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002136fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002137if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002138 echo "$ac_t""yes" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002139 LIBS="-lsocket $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002140else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002141 echo "$ac_t""no" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00002142fi
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002143 # SVR4 sockets
Guido van Rossumda88dad1995-01-26 00:46:29 +00002144fi
Guido van Rossuma68acba1996-07-31 17:36:39 +00002145echo $ac_n "checking for --with-libs""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002146echo "configure:2147: checking for --with-libs" >&5
Guido van Rossuma68acba1996-07-31 17:36:39 +00002147# Check whether --with-libs or --without-libs was given.
2148if test "${with_libs+set}" = set; then
2149 withval="$with_libs"
2150
2151echo "$ac_t""$withval" 1>&6
2152LIBS="$withval $LIBS"
2153
2154else
2155 echo "$ac_t""no" 1>&6
2156fi
2157
Guido van Rossum7f43da71994-08-01 12:15:30 +00002158
Guido van Rossum3c83bb41996-12-31 22:35:16 +00002159echo $ac_n "checking for --with(out)-readline""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002160echo "configure:2161: checking for --with(out)-readline" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002161# Check whether --with-readline or --without-readline was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002162if test "${with_readline+set}" = set; then
2163 withval="$with_readline"
Guido van Rossumb06df271997-08-05 21:50:20 +00002164 echo "$ac_t""$withval" 1>&6
2165{ echo "configure: error: --with(out)-readline is obsolete" 1>&2; exit 1; }
Guido van Rossum3c83bb41996-12-31 22:35:16 +00002166else
Guido van Rossumb06df271997-08-05 21:50:20 +00002167 echo "$ac_t""not specified." 1>&6
Guido van Rossum3c83bb41996-12-31 22:35:16 +00002168fi
2169
Guido van Rossum7f43da71994-08-01 12:15:30 +00002170
Guido van Rossumec2f0731997-01-22 20:54:01 +00002171echo $ac_n "checking for --with-dec-threads""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002172echo "configure:2173: checking for --with-dec-threads" >&5
Guido van Rossumec2f0731997-01-22 20:54:01 +00002173
2174# Check whether --with-dec-threads or --without-dec-threads was given.
2175if test "${with_dec_threads+set}" = set; then
2176 withval="$with_dec_threads"
2177 echo "$ac_t""$withval" 1>&6
2178LDLAST=-threads
Guido van Rossumf78abae1997-01-21 22:02:36 +00002179if test "${with_thread+set}" != set; then
Guido van Rossumec2f0731997-01-22 20:54:01 +00002180 with_thread="$withval";
Guido van Rossumf78abae1997-01-21 22:02:36 +00002181fi
Guido van Rossumec2f0731997-01-22 20:54:01 +00002182else
2183 echo "$ac_t""no" 1>&6
2184fi
2185
2186
2187echo $ac_n "checking for --with-threads""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002188echo "configure:2189: checking for --with-threads" >&5
Guido van Rossumec2f0731997-01-22 20:54:01 +00002189# Check whether --with-threads or --without-threads was given.
2190if test "${with_threads+set}" = set; then
2191 withval="$with_threads"
2192 echo "$ac_t""$withval" 1>&6
2193if test "${with_thread+set}" != set; then
2194 with_thread="$withval";
2195fi
2196else
2197 echo "$ac_t""no" 1>&6
2198fi
2199
2200
2201echo $ac_n "checking for --with-thread""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002202echo "configure:2203: checking for --with-thread" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002203# Check whether --with-thread or --without-thread was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002204if test "${with_thread+set}" = set; then
2205 withval="$with_thread"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002206
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002207echo "$ac_t""$withval" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00002208if test -d "$withval"
Guido van Rossum84e7b241996-08-19 21:59:00 +00002209then LDFLAGS="$LDFLAGS -L$withval"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002210fi
Guido van Rossum9caf77a1996-08-01 00:52:26 +00002211cat >> confdefs.h <<\EOF
2212#define _REENTRANT 1
2213EOF
2214
Guido van Rossumf78abae1997-01-21 22:02:36 +00002215ac_safe=`echo "mach/cthreads.h" | sed 'y%./+-%__p_%'`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002216echo $ac_n "checking for mach/cthreads.h""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002217echo "configure:2218: checking for mach/cthreads.h" >&5
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002218if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2219 echo $ac_n "(cached) $ac_c" 1>&6
2220else
2221 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002222#line 2223 "configure"
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002223#include "confdefs.h"
2224#include <mach/cthreads.h>
2225EOF
2226ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum91922671997-10-09 20:24:13 +00002227{ (eval echo configure:2228: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002228ac_err=`grep -v '^ *+' conftest.out`
2229if test -z "$ac_err"; then
2230 rm -rf conftest*
2231 eval "ac_cv_header_$ac_safe=yes"
2232else
2233 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002234 echo "configure: failed program was:" >&5
2235 cat conftest.$ac_ext >&5
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002236 rm -rf conftest*
2237 eval "ac_cv_header_$ac_safe=no"
2238fi
2239rm -f conftest*
2240fi
2241if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2242 echo "$ac_t""yes" 1>&6
2243 cat >> confdefs.h <<\EOF
2244#define WITH_THREAD 1
2245EOF
2246
2247cat >> confdefs.h <<\EOF
2248#define C_THREADS 1
2249EOF
2250
2251LIBOBJS="$LIBOBJS thread.o"
2252else
2253 echo "$ac_t""no" 1>&6
2254
Guido van Rossumf78abae1997-01-21 22:02:36 +00002255echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002256echo "configure:2257: checking for pthread_create in -lpthreads" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002257ac_lib_var=`echo pthreads'_'pthread_create | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002258if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002259 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002260else
2261 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002262LIBS="-lpthreads $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002263cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002264#line 2265 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002265#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002266/* Override any gcc2 internal prototype to avoid an error. */
2267/* We use char because int might match the return type of a gcc2
2268 builtin and then its argument prototype would still apply. */
2269char pthread_create();
Guido van Rossum7f43da71994-08-01 12:15:30 +00002270
Guido van Rossumf78abae1997-01-21 22:02:36 +00002271int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002272pthread_create()
2273; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00002274EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002275if { (eval echo configure:2276: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00002276 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002277 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002278else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002279 echo "configure: failed program was:" >&5
2280 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002281 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002282 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002283fi
2284rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002285LIBS="$ac_save_LIBS"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002286
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002287fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002288if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002289 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002290 cat >> confdefs.h <<\EOF
2291#define WITH_THREAD 1
2292EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00002293
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002294cat >> confdefs.h <<\EOF
2295#define _POSIX_THREADS 1
2296EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00002297
2298LIBS="$LIBS -lpthreads"
2299LIBOBJS="$LIBOBJS thread.o"
2300else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002301 echo "$ac_t""no" 1>&6
Guido van Rossum2d38f911996-06-26 19:47:01 +00002302
Guido van Rossumf78abae1997-01-21 22:02:36 +00002303echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002304echo "configure:2305: checking for pthread_create in -lpthread" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002305ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'`
Guido van Rossum2d38f911996-06-26 19:47:01 +00002306if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2307 echo $ac_n "(cached) $ac_c" 1>&6
2308else
2309 ac_save_LIBS="$LIBS"
2310LIBS="-lpthread $LIBS"
2311cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002312#line 2313 "configure"
Guido van Rossum2d38f911996-06-26 19:47:01 +00002313#include "confdefs.h"
2314/* Override any gcc2 internal prototype to avoid an error. */
2315/* We use char because int might match the return type of a gcc2
2316 builtin and then its argument prototype would still apply. */
2317char pthread_create();
2318
Guido van Rossumf78abae1997-01-21 22:02:36 +00002319int main() {
Guido van Rossum2d38f911996-06-26 19:47:01 +00002320pthread_create()
2321; return 0; }
2322EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002323if { (eval echo configure:2324: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum2d38f911996-06-26 19:47:01 +00002324 rm -rf conftest*
2325 eval "ac_cv_lib_$ac_lib_var=yes"
2326else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002327 echo "configure: failed program was:" >&5
2328 cat conftest.$ac_ext >&5
Guido van Rossum2d38f911996-06-26 19:47:01 +00002329 rm -rf conftest*
2330 eval "ac_cv_lib_$ac_lib_var=no"
2331fi
2332rm -f conftest*
2333LIBS="$ac_save_LIBS"
2334
2335fi
2336if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2337 echo "$ac_t""yes" 1>&6
2338 cat >> confdefs.h <<\EOF
2339#define WITH_THREAD 1
2340EOF
2341
2342cat >> confdefs.h <<\EOF
2343#define _POSIX_THREADS 1
2344EOF
2345
2346LIBS="$LIBS -lpthread"
2347LIBOBJS="$LIBOBJS thread.o"
2348else
2349 echo "$ac_t""no" 1>&6
Guido van Rossum0be3e491997-05-22 20:33:33 +00002350
2351echo $ac_n "checking for __d6_pthread_create in -lthread""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002352echo "configure:2353: checking for __d6_pthread_create in -lthread" >&5
Guido van Rossum0be3e491997-05-22 20:33:33 +00002353ac_lib_var=`echo thread'_'__d6_pthread_create | sed 'y%./+-%__p_%'`
2354if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2355 echo $ac_n "(cached) $ac_c" 1>&6
2356else
2357 ac_save_LIBS="$LIBS"
2358LIBS="-lthread $LIBS"
2359cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002360#line 2361 "configure"
Guido van Rossum0be3e491997-05-22 20:33:33 +00002361#include "confdefs.h"
2362/* Override any gcc2 internal prototype to avoid an error. */
2363/* We use char because int might match the return type of a gcc2
2364 builtin and then its argument prototype would still apply. */
2365char __d6_pthread_create();
2366
2367int main() {
2368__d6_pthread_create()
2369; return 0; }
2370EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002371if { (eval echo configure:2372: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum0be3e491997-05-22 20:33:33 +00002372 rm -rf conftest*
2373 eval "ac_cv_lib_$ac_lib_var=yes"
2374else
2375 echo "configure: failed program was:" >&5
2376 cat conftest.$ac_ext >&5
2377 rm -rf conftest*
2378 eval "ac_cv_lib_$ac_lib_var=no"
2379fi
2380rm -f conftest*
2381LIBS="$ac_save_LIBS"
2382
2383fi
2384if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2385 echo "$ac_t""yes" 1>&6
2386 cat >> confdefs.h <<\EOF
2387#define WITH_THREAD 1
2388EOF
2389
2390cat >> confdefs.h <<\EOF
2391#define _POSIX_THREADS 1
2392EOF
2393
2394LIBS="$LIBS -lthread"
2395LIBOBJS="$LIBOBJS thread.o"
2396else
2397 echo "$ac_t""no" 1>&6
Guido van Rossum2d38f911996-06-26 19:47:01 +00002398fi
2399
2400
Guido van Rossum627b2d71993-12-24 10:39:16 +00002401fi
2402
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002403fi
2404
Guido van Rossum0be3e491997-05-22 20:33:33 +00002405fi
2406
2407
Guido van Rossumf78abae1997-01-21 22:02:36 +00002408echo $ac_n "checking for usconfig in -lmpc""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002409echo "configure:2410: checking for usconfig in -lmpc" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002410ac_lib_var=`echo mpc'_'usconfig | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002411if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002412 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002413else
2414 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002415LIBS="-lmpc $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002416cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002417#line 2418 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002418#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002419/* Override any gcc2 internal prototype to avoid an error. */
2420/* We use char because int might match the return type of a gcc2
2421 builtin and then its argument prototype would still apply. */
2422char usconfig();
Guido van Rossum627b2d71993-12-24 10:39:16 +00002423
Guido van Rossumf78abae1997-01-21 22:02:36 +00002424int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002425usconfig()
2426; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002427EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002428if { (eval echo configure:2429: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002429 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002430 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002431else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002432 echo "configure: failed program was:" >&5
2433 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002434 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002435 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002436fi
2437rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002438LIBS="$ac_save_LIBS"
2439
2440fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002441if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002442 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002443 cat >> confdefs.h <<\EOF
2444#define WITH_THREAD 1
2445EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00002446
Guido van Rossum7f43da71994-08-01 12:15:30 +00002447LIBS="$LIBS -lmpc"
2448LIBOBJS="$LIBOBJS thread.o"
2449else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002450 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00002451fi
2452
Guido van Rossumf78abae1997-01-21 22:02:36 +00002453echo $ac_n "checking for thr_create in -lthread""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002454echo "configure:2455: checking for thr_create in -lthread" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002455ac_lib_var=`echo thread'_'thr_create | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002456if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002457 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002458else
2459 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002460LIBS="-lthread $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002461cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002462#line 2463 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002463#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002464/* Override any gcc2 internal prototype to avoid an error. */
2465/* We use char because int might match the return type of a gcc2
2466 builtin and then its argument prototype would still apply. */
2467char thr_create();
Guido van Rossum627b2d71993-12-24 10:39:16 +00002468
Guido van Rossumf78abae1997-01-21 22:02:36 +00002469int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002470thr_create()
2471; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002472EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002473if { (eval echo configure:2474: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002474 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002475 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002476else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002477 echo "configure: failed program was:" >&5
2478 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002479 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002480 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002481fi
2482rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002483LIBS="$ac_save_LIBS"
2484
2485fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002486if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002487 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002488 cat >> confdefs.h <<\EOF
2489#define WITH_THREAD 1
2490EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00002491
Guido van Rossum7f43da71994-08-01 12:15:30 +00002492LIBS="$LIBS -lthread"
2493LIBOBJS="$LIBOBJS thread.o"
2494else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002495 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00002496fi
2497
Guido van Rossum7f43da71994-08-01 12:15:30 +00002498
Guido van Rossumda88dad1995-01-26 00:46:29 +00002499else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002500 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00002501fi
2502
Guido van Rossum7f43da71994-08-01 12:15:30 +00002503
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002504# -I${DLINCLDIR} is added to the compile rule for importdl.o
Guido van Rossum7f43da71994-08-01 12:15:30 +00002505
2506DLINCLDIR=/
2507
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002508echo $ac_n "checking for --with-sgi-dl""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002509echo "configure:2510: checking for --with-sgi-dl" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002510# Check whether --with-sgi-dl or --without-sgi-dl was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002511if test "${with_sgi_dl+set}" = set; then
2512 withval="$with_sgi_dl"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002513
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002514echo "$ac_t""$withval" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002515cat >> confdefs.h <<\EOF
2516#define WITH_SGI_DL 1
2517EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00002518
2519dldir=$withval
2520if test -d "$dldir"
Guido van Rossum84e7b241996-08-19 21:59:00 +00002521then LDFLAGS="$LDFLAGS -L$dldir"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002522else { echo "configure: error: proper usage is --with-sgi-dl=DIRECTORY" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00002523fi
2524DLINCLDIR=${dldir}
2525LIBS="$LIBS -ldl -lmld"
Guido van Rossumda88dad1995-01-26 00:46:29 +00002526else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002527 echo "$ac_t""no" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00002528fi
2529
2530
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002531echo $ac_n "checking for --with-dl-dld""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002532echo "configure:2533: checking for --with-dl-dld" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002533# Check whether --with-dl-dld or --without-dl-dld was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002534if test "${with_dl_dld+set}" = set; then
2535 withval="$with_dl_dld"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002536
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002537echo "$ac_t""$withval" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002538cat >> confdefs.h <<\EOF
2539#define WITH_DL_DLD 1
2540EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00002541
2542dldir=`echo "$withval" | sed 's/,.*//'`
2543dlddir=`echo "$withval" | sed 's/.*,//'`
2544if test -d "$dldir" -a -d "$dlddir"
Guido van Rossum84e7b241996-08-19 21:59:00 +00002545then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002546else { echo "configure: error: proper usage is --with-dl-dld=DL_DIRECTORY" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00002547fi
2548DLINCLDIR=${dldir}
2549LIBS="$LIBS -ldl -ldld"
Guido van Rossumda88dad1995-01-26 00:46:29 +00002550else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002551 echo "$ac_t""no" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00002552fi
2553
2554
Guido van Rossum627b2d71993-12-24 10:39:16 +00002555# checks for library functions
Guido van Rossum1171ee61997-08-22 20:42:00 +00002556for ac_func in alarm chown clock dlopen execv flock fork ftime ftruncate \
2557 gethostname_r getpeername getpgrp getpid getpwent gettimeofday getwd \
2558 kill link lstat mkfifo nice pause plock putenv readlink \
Guido van Rossum96013151997-10-08 22:47:52 +00002559 select setgid setlocale setuid setsid setpgid setpgrp setvbuf \
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002560 sigaction siginterrupt sigrelse strftime symlink \
2561 tcgetpgrp tcsetpgrp times truncate uname waitpid
Guido van Rossum627b2d71993-12-24 10:39:16 +00002562do
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002563echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002564echo "configure:2565: checking for $ac_func" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002565if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2566 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002567else
2568 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002569#line 2570 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002570#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002571/* System header to define __stub macros and hopefully few prototypes,
2572 which can conflict with char $ac_func(); below. */
2573#include <assert.h>
2574/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002575/* We use char because int might match the return type of a gcc2
2576 builtin and then its argument prototype would still apply. */
2577char $ac_func();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002578
Guido van Rossumf78abae1997-01-21 22:02:36 +00002579int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002580
Guido van Rossum627b2d71993-12-24 10:39:16 +00002581/* The GNU C library defines this for functions which it implements
2582 to always fail with ENOSYS. Some functions are actually named
2583 something starting with __ and the normal name is an alias. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002584#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +00002585choke me
2586#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002587$ac_func();
Guido van Rossum627b2d71993-12-24 10:39:16 +00002588#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002589
Guido van Rossum7f43da71994-08-01 12:15:30 +00002590; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002591EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002592if { (eval echo configure:2593: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002593 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002594 eval "ac_cv_func_$ac_func=yes"
2595else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002596 echo "configure: failed program was:" >&5
2597 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002598 rm -rf conftest*
2599 eval "ac_cv_func_$ac_func=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002600fi
2601rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002602fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00002603
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002604if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002605 echo "$ac_t""yes" 1>&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002606 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002607 cat >> confdefs.h <<EOF
2608#define $ac_tr_func 1
2609EOF
2610
2611else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002612 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002613fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00002614done
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002615
Guido van Rossum2b3ac691996-08-30 15:18:41 +00002616for ac_func in dup2 getcwd strdup strerror memmove
Guido van Rossum627b2d71993-12-24 10:39:16 +00002617do
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002618echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002619echo "configure:2620: checking for $ac_func" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002620if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2621 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002622else
2623 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002624#line 2625 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002625#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002626/* System header to define __stub macros and hopefully few prototypes,
2627 which can conflict with char $ac_func(); below. */
2628#include <assert.h>
2629/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002630/* We use char because int might match the return type of a gcc2
2631 builtin and then its argument prototype would still apply. */
2632char $ac_func();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002633
Guido van Rossumf78abae1997-01-21 22:02:36 +00002634int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002635
Guido van Rossum627b2d71993-12-24 10:39:16 +00002636/* The GNU C library defines this for functions which it implements
2637 to always fail with ENOSYS. Some functions are actually named
2638 something starting with __ and the normal name is an alias. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002639#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +00002640choke me
2641#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002642$ac_func();
Guido van Rossum627b2d71993-12-24 10:39:16 +00002643#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002644
Guido van Rossum7f43da71994-08-01 12:15:30 +00002645; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002646EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002647if { (eval echo configure:2648: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002648 rm -rf conftest*
2649 eval "ac_cv_func_$ac_func=yes"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002650else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002651 echo "configure: failed program was:" >&5
2652 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00002653 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002654 eval "ac_cv_func_$ac_func=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002655fi
2656rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002657fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00002658
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002659if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002660 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00002661 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2662 cat >> confdefs.h <<EOF
2663#define $ac_tr_func 1
2664EOF
2665
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002666else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002667 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002668LIBOBJS="$LIBOBJS ${ac_func}.o"
2669fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00002670done
2671
Guido van Rossumf78abae1997-01-21 22:02:36 +00002672
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002673echo $ac_n "checking for getpgrp""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002674echo "configure:2675: checking for getpgrp" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002675if eval "test \"`echo '$''{'ac_cv_func_getpgrp'+set}'`\" = set"; then
2676 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002677else
2678 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002679#line 2680 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002680#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002681/* System header to define __stub macros and hopefully few prototypes,
2682 which can conflict with char getpgrp(); below. */
2683#include <assert.h>
2684/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002685/* We use char because int might match the return type of a gcc2
2686 builtin and then its argument prototype would still apply. */
2687char getpgrp();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002688
Guido van Rossumf78abae1997-01-21 22:02:36 +00002689int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002690
Guido van Rossum627b2d71993-12-24 10:39:16 +00002691/* The GNU C library defines this for functions which it implements
2692 to always fail with ENOSYS. Some functions are actually named
2693 something starting with __ and the normal name is an alias. */
2694#if defined (__stub_getpgrp) || defined (__stub___getpgrp)
2695choke me
2696#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002697getpgrp();
Guido van Rossum627b2d71993-12-24 10:39:16 +00002698#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002699
2700; return 0; }
2701EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002702if { (eval echo configure:2703: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002703 rm -rf conftest*
2704 eval "ac_cv_func_getpgrp=yes"
2705else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002706 echo "configure: failed program was:" >&5
2707 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002708 rm -rf conftest*
2709 eval "ac_cv_func_getpgrp=no"
2710fi
2711rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002712fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00002713
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002714if eval "test \"`echo '$ac_cv_func_'getpgrp`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002715 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002716 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002717#line 2718 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002718#include "confdefs.h"
2719#include <unistd.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002720int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002721getpgrp(0);
Guido van Rossum7f43da71994-08-01 12:15:30 +00002722; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002723EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002724if { (eval echo configure:2725: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002725 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002726 cat >> confdefs.h <<\EOF
2727#define GETPGRP_HAVE_ARG 1
Guido van Rossum627b2d71993-12-24 10:39:16 +00002728EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00002729
Guido van Rossumf78abae1997-01-21 22:02:36 +00002730else
2731 echo "configure: failed program was:" >&5
2732 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00002733fi
2734rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002735else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002736 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00002737fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00002738
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002739echo $ac_n "checking for setpgrp""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002740echo "configure:2741: checking for setpgrp" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002741if eval "test \"`echo '$''{'ac_cv_func_setpgrp'+set}'`\" = set"; then
2742 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002743else
2744 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002745#line 2746 "configure"
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002746#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002747/* System header to define __stub macros and hopefully few prototypes,
2748 which can conflict with char setpgrp(); below. */
2749#include <assert.h>
2750/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002751/* We use char because int might match the return type of a gcc2
2752 builtin and then its argument prototype would still apply. */
2753char setpgrp();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002754
Guido van Rossumf78abae1997-01-21 22:02:36 +00002755int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002756
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002757/* The GNU C library defines this for functions which it implements
2758 to always fail with ENOSYS. Some functions are actually named
2759 something starting with __ and the normal name is an alias. */
2760#if defined (__stub_setpgrp) || defined (__stub___setpgrp)
2761choke me
2762#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002763setpgrp();
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002764#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002765
2766; return 0; }
2767EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002768if { (eval echo configure:2769: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002769 rm -rf conftest*
2770 eval "ac_cv_func_setpgrp=yes"
2771else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002772 echo "configure: failed program was:" >&5
2773 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002774 rm -rf conftest*
2775 eval "ac_cv_func_setpgrp=no"
2776fi
2777rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002778fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00002779
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002780if eval "test \"`echo '$ac_cv_func_'setpgrp`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002781 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002782 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002783#line 2784 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002784#include "confdefs.h"
2785#include <unistd.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002786int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002787setpgrp(0,0);
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002788; return 0; }
2789EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002790if { (eval echo configure:2791: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002791 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002792 cat >> confdefs.h <<\EOF
2793#define SETPGRP_HAVE_ARG 1
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002794EOF
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002795
Guido van Rossumf78abae1997-01-21 22:02:36 +00002796else
2797 echo "configure: failed program was:" >&5
2798 cat conftest.$ac_ext >&5
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002799fi
2800rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002801else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002802 echo "$ac_t""no" 1>&6
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002803fi
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002804
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002805echo $ac_n "checking for gettimeofday""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002806echo "configure:2807: checking for gettimeofday" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002807if eval "test \"`echo '$''{'ac_cv_func_gettimeofday'+set}'`\" = set"; then
2808 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002809else
2810 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002811#line 2812 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002812#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002813/* System header to define __stub macros and hopefully few prototypes,
2814 which can conflict with char gettimeofday(); below. */
2815#include <assert.h>
2816/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002817/* We use char because int might match the return type of a gcc2
2818 builtin and then its argument prototype would still apply. */
2819char gettimeofday();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002820
Guido van Rossumf78abae1997-01-21 22:02:36 +00002821int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002822
2823/* The GNU C library defines this for functions which it implements
2824 to always fail with ENOSYS. Some functions are actually named
2825 something starting with __ and the normal name is an alias. */
2826#if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
2827choke me
2828#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002829gettimeofday();
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002830#endif
2831
2832; return 0; }
2833EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002834if { (eval echo configure:2835: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002835 rm -rf conftest*
2836 eval "ac_cv_func_gettimeofday=yes"
2837else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002838 echo "configure: failed program was:" >&5
2839 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002840 rm -rf conftest*
2841 eval "ac_cv_func_gettimeofday=no"
2842fi
2843rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002844fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00002845
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002846if eval "test \"`echo '$ac_cv_func_'gettimeofday`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002847 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002848 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002849#line 2850 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002850#include "confdefs.h"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002851#include <sys/time.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002852int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002853gettimeofday((struct timeval*)0,(struct timezone*)0);
2854; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002855EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002856if { (eval echo configure:2857: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002857 :
2858else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002859 echo "configure: failed program was:" >&5
2860 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00002861 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002862 cat >> confdefs.h <<\EOF
2863#define GETTIMEOFDAY_NO_TZ 1
2864EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00002865
2866fi
2867rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002868else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002869 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002870fi
2871
2872
2873# checks for structures
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002874echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002875echo "configure:2876: checking whether time.h and sys/time.h may both be included" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002876if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
2877 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002878else
2879 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002880#line 2881 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002881#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002882#include <sys/types.h>
2883#include <sys/time.h>
2884#include <time.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002885int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002886struct tm *tp;
2887; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002888EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002889if { (eval echo configure:2890: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002890 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002891 ac_cv_header_time=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00002892else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002893 echo "configure: failed program was:" >&5
2894 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00002895 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002896 ac_cv_header_time=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00002897fi
2898rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002899fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002900
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002901echo "$ac_t""$ac_cv_header_time" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002902if test $ac_cv_header_time = yes; then
2903 cat >> confdefs.h <<\EOF
2904#define TIME_WITH_SYS_TIME 1
2905EOF
2906
2907fi
2908
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002909echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002910echo "configure:2911: checking whether struct tm is in sys/time.h or time.h" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002911if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
2912 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002913else
2914 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002915#line 2916 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002916#include "confdefs.h"
2917#include <sys/types.h>
2918#include <time.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002919int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002920struct tm *tp; tp->tm_sec;
2921; return 0; }
2922EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002923if { (eval echo configure:2924: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002924 rm -rf conftest*
2925 ac_cv_struct_tm=time.h
2926else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002927 echo "configure: failed program was:" >&5
2928 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002929 rm -rf conftest*
2930 ac_cv_struct_tm=sys/time.h
2931fi
2932rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002933fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002934
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002935echo "$ac_t""$ac_cv_struct_tm" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002936if test $ac_cv_struct_tm = sys/time.h; then
2937 cat >> confdefs.h <<\EOF
2938#define TM_IN_SYS_TIME 1
2939EOF
2940
2941fi
2942
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002943echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002944echo "configure:2945: checking for tm_zone in struct tm" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002945if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then
2946 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002947else
2948 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002949#line 2950 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002950#include "confdefs.h"
2951#include <sys/types.h>
2952#include <$ac_cv_struct_tm>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002953int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002954struct tm tm; tm.tm_zone;
2955; return 0; }
2956EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002957if { (eval echo configure:2958: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002958 rm -rf conftest*
2959 ac_cv_struct_tm_zone=yes
2960else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002961 echo "configure: failed program was:" >&5
2962 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002963 rm -rf conftest*
2964 ac_cv_struct_tm_zone=no
2965fi
2966rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002967fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002968
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002969echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002970if test "$ac_cv_struct_tm_zone" = yes; then
2971 cat >> confdefs.h <<\EOF
2972#define HAVE_TM_ZONE 1
2973EOF
2974
2975else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002976 echo $ac_n "checking for tzname""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00002977echo "configure:2978: checking for tzname" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002978if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then
2979 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002980else
2981 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002982#line 2983 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002983#include "confdefs.h"
2984#include <time.h>
2985#ifndef tzname /* For SGI. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002986extern char *tzname[]; /* RS6000 and others reject char **tzname. */
Guido van Rossum627b2d71993-12-24 10:39:16 +00002987#endif
Guido van Rossumf78abae1997-01-21 22:02:36 +00002988int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002989atoi(*tzname);
2990; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002991EOF
Guido van Rossum91922671997-10-09 20:24:13 +00002992if { (eval echo configure:2993: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002993 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002994 ac_cv_var_tzname=yes
2995else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002996 echo "configure: failed program was:" >&5
2997 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002998 rm -rf conftest*
2999 ac_cv_var_tzname=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00003000fi
3001rm -f conftest*
Guido van Rossum627b2d71993-12-24 10:39:16 +00003002fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003003
3004echo "$ac_t""$ac_cv_var_tzname" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003005 if test $ac_cv_var_tzname = yes; then
3006 cat >> confdefs.h <<\EOF
3007#define HAVE_TZNAME 1
3008EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00003009
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003010 fi
3011fi
3012
3013
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003014echo $ac_n "checking for time.h that defines altzone""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003015echo "configure:3016: checking for time.h that defines altzone" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003016if eval "test \"`echo '$''{'ac_cv_header_time_altzone'+set}'`\" = set"; then
3017 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003018else
3019 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003020#line 3021 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003021#include "confdefs.h"
3022#include <time.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00003023int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003024return altzone;
3025; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00003026EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003027if { (eval echo configure:3028: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00003028 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003029 ac_cv_header_time_altzone=yes
3030else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003031 echo "configure: failed program was:" >&5
3032 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003033 rm -rf conftest*
3034 ac_cv_header_time_altzone=no
Guido van Rossum7f43da71994-08-01 12:15:30 +00003035fi
3036rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003037fi
3038
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003039echo "$ac_t""$ac_cv_header_time_altzone" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003040if test $ac_cv_header_time_altzone = yes; then
3041 cat >> confdefs.h <<\EOF
3042#define HAVE_ALTZONE 1
3043EOF
3044
3045fi
3046
Guido van Rossumda88dad1995-01-26 00:46:29 +00003047was_it_defined=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003048echo $ac_n "checking whether sys/select.h and sys/time.h may both be included""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003049echo "configure:3050: checking whether sys/select.h and sys/time.h may both be included" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003050cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003051#line 3052 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003052#include "confdefs.h"
3053
3054#include <sys/types.h>
3055#include <sys/select.h>
3056#include <sys/time.h>
3057
Guido van Rossumf78abae1997-01-21 22:02:36 +00003058int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003059;
3060; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00003061EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003062if { (eval echo configure:3063: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00003063 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003064 cat >> confdefs.h <<\EOF
3065#define SYS_SELECT_WITH_SYS_TIME 1
3066EOF
Guido van Rossumda88dad1995-01-26 00:46:29 +00003067 was_it_defined=yes
Guido van Rossumf78abae1997-01-21 22:02:36 +00003068else
3069 echo "configure: failed program was:" >&5
3070 cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +00003071fi
3072rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003073echo "$ac_t""$was_it_defined" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00003074
3075# checks for compiler characteristics
Guido van Rossum7f43da71994-08-01 12:15:30 +00003076
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003077echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003078echo "configure:3079: checking whether char is unsigned" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003079if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then
3080 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003081else
3082 if test "$GCC" = yes; then
3083 # GCC predefines this symbol on systems where it applies.
3084cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003085#line 3086 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003086#include "confdefs.h"
3087#ifdef __CHAR_UNSIGNED__
3088 yes
3089#endif
3090
3091EOF
3092if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3093 egrep "yes" >/dev/null 2>&1; then
3094 rm -rf conftest*
3095 ac_cv_c_char_unsigned=yes
3096else
3097 rm -rf conftest*
3098 ac_cv_c_char_unsigned=no
3099fi
3100rm -f conftest*
3101
3102else
3103if test "$cross_compiling" = yes; then
3104 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
3105else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003106 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003107#line 3108 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003108#include "confdefs.h"
3109/* volatile prevents gcc2 from optimizing the test away on sparcs. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003110#if !defined(__STDC__) || __STDC__ != 1
Guido van Rossum7f43da71994-08-01 12:15:30 +00003111#define volatile
3112#endif
3113main() {
Guido van Rossum7f43da71994-08-01 12:15:30 +00003114 volatile char c = 255; exit(c < 0);
Guido van Rossum7f43da71994-08-01 12:15:30 +00003115}
3116EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003117if { (eval echo configure:3118: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Guido van Rossumf78abae1997-01-21 22:02:36 +00003118then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003119 ac_cv_c_char_unsigned=yes
3120else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003121 echo "configure: failed program was:" >&5
3122 cat conftest.$ac_ext >&5
3123 rm -fr conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003124 ac_cv_c_char_unsigned=no
3125fi
Guido van Rossum7f43da71994-08-01 12:15:30 +00003126rm -fr conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003127fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00003128
3129fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003130fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003131
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003132echo "$ac_t""$ac_cv_c_char_unsigned" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003133if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
3134 cat >> confdefs.h <<\EOF
3135#define __CHAR_UNSIGNED__ 1
3136EOF
3137
3138fi
Guido van Rossum7f43da71994-08-01 12:15:30 +00003139
3140
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003141echo $ac_n "checking for working const""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003142echo "configure:3143: checking for working const" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003143if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
3144 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003145else
3146 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003147#line 3148 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003148#include "confdefs.h"
3149
Guido van Rossumf78abae1997-01-21 22:02:36 +00003150int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003151
3152/* Ultrix mips cc rejects this. */
Guido van Rossum627b2d71993-12-24 10:39:16 +00003153typedef int charset[2]; const charset x;
3154/* SunOS 4.1.1 cc rejects this. */
3155char const *const *ccp;
3156char **p;
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003157/* NEC SVR4.0.2 mips cc rejects this. */
3158struct point {int x, y;};
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003159static struct point const zero = {0,0};
Guido van Rossum627b2d71993-12-24 10:39:16 +00003160/* AIX XL C 1.02.0.0 rejects this.
3161 It does not let you subtract one const X* pointer from another in an arm
3162 of an if-expression whose if-part is not a constant expression */
3163const char *g = "string";
3164ccp = &g + (g ? g-g : 0);
3165/* HPUX 7.0 cc rejects these. */
3166++ccp;
3167p = (char**) ccp;
3168ccp = (char const *const *) p;
3169{ /* SCO 3.2v4 cc rejects this. */
3170 char *t;
3171 char const *s = 0 ? (char *) 0 : (char const *) 0;
3172
3173 *t++ = 0;
3174}
3175{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003176 int x[] = {25, 17};
Guido van Rossum627b2d71993-12-24 10:39:16 +00003177 const int *foo = &x[0];
3178 ++foo;
3179}
3180{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
3181 typedef const int *iptr;
3182 iptr p = 0;
3183 ++p;
3184}
3185{ /* AIX XL C 1.02.0.0 rejects this saying
3186 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
3187 struct s { int j; const int *ap[3]; };
3188 struct s *b; b->j = 5;
3189}
3190{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
3191 const int foo = 10;
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003192}
3193
3194; return 0; }
3195EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003196if { (eval echo configure:3197: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003197 rm -rf conftest*
3198 ac_cv_c_const=yes
3199else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003200 echo "configure: failed program was:" >&5
3201 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003202 rm -rf conftest*
3203 ac_cv_c_const=no
3204fi
3205rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003206fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003207
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003208echo "$ac_t""$ac_cv_c_const" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003209if test $ac_cv_c_const = no; then
3210 cat >> confdefs.h <<\EOF
3211#define const
3212EOF
3213
3214fi
3215
3216
Guido van Rossumda88dad1995-01-26 00:46:29 +00003217works=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003218echo $ac_n "checking for working volatile""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003219echo "configure:3220: checking for working volatile" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003220cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003221#line 3222 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003222#include "confdefs.h"
3223
Guido van Rossumf78abae1997-01-21 22:02:36 +00003224int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003225volatile int x; x = 0;
3226; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00003227EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003228if { (eval echo configure:3229: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00003229 rm -rf conftest*
3230 works=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00003231else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003232 echo "configure: failed program was:" >&5
3233 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00003234 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003235 cat >> confdefs.h <<\EOF
3236#define volatile
3237EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00003238
3239fi
3240rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003241echo "$ac_t""$works" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00003242
Guido van Rossumda88dad1995-01-26 00:46:29 +00003243works=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003244echo $ac_n "checking for working signed char""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003245echo "configure:3246: checking for working signed char" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003246cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003247#line 3248 "configure"
Guido van Rossumdabb11b1994-10-11 15:04:27 +00003248#include "confdefs.h"
3249
Guido van Rossumf78abae1997-01-21 22:02:36 +00003250int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003251signed char c;
3252; return 0; }
Guido van Rossumdabb11b1994-10-11 15:04:27 +00003253EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003254if { (eval echo configure:3255: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00003255 rm -rf conftest*
3256 works=yes
Guido van Rossumdabb11b1994-10-11 15:04:27 +00003257else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003258 echo "configure: failed program was:" >&5
3259 cat conftest.$ac_ext >&5
Guido van Rossumdabb11b1994-10-11 15:04:27 +00003260 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003261 cat >> confdefs.h <<\EOF
3262#define signed
Guido van Rossum627b2d71993-12-24 10:39:16 +00003263EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00003264
3265fi
3266rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003267echo "$ac_t""$works" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00003268
Guido van Rossumda88dad1995-01-26 00:46:29 +00003269have_prototypes=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003270echo $ac_n "checking for prototypes""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003271echo "configure:3272: checking for prototypes" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003272cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003273#line 3274 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003274#include "confdefs.h"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003275int foo(int x) { return 0; }
Guido van Rossumf78abae1997-01-21 22:02:36 +00003276int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003277return foo(10);
3278; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00003279EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003280if { (eval echo configure:3281: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003281 rm -rf conftest*
3282 cat >> confdefs.h <<\EOF
3283#define HAVE_PROTOTYPES 1
3284EOF
3285 have_prototypes=yes
Guido van Rossumf78abae1997-01-21 22:02:36 +00003286else
3287 echo "configure: failed program was:" >&5
3288 cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +00003289fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003290rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003291echo "$ac_t""$have_prototypes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003292
Guido van Rossumda88dad1995-01-26 00:46:29 +00003293works=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003294echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003295echo "configure:3296: checking for variable length prototypes and stdarg.h" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003296cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003297#line 3298 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003298#include "confdefs.h"
3299
3300#include <stdarg.h>
Guido van Rossum90eea071996-08-30 20:58:57 +00003301int foo(int x, ...) {
3302 va_list va;
3303 va_start(va, x);
3304 va_arg(va, int);
3305 va_arg(va, char *);
3306 va_arg(va, double);
3307 return 0;
3308}
Guido van Rossum7f43da71994-08-01 12:15:30 +00003309
Guido van Rossumf78abae1997-01-21 22:02:36 +00003310int main() {
Guido van Rossum90eea071996-08-30 20:58:57 +00003311return foo(10, "", 3.14);
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003312; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00003313EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003314if { (eval echo configure:3315: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003315 rm -rf conftest*
3316 cat >> confdefs.h <<\EOF
3317#define HAVE_STDARG_PROTOTYPES 1
3318EOF
Guido van Rossumda88dad1995-01-26 00:46:29 +00003319 works=yes
Guido van Rossumf78abae1997-01-21 22:02:36 +00003320else
3321 echo "configure: failed program was:" >&5
3322 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00003323fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003324rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003325echo "$ac_t""$works" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003326
Guido van Rossumda88dad1995-01-26 00:46:29 +00003327if test "$have_prototypes" = yes; then
3328bad_prototypes=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003329echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003330echo "configure:3331: checking for bad exec* prototypes" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003331cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003332#line 3333 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003333#include "confdefs.h"
3334#include <unistd.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00003335int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003336char **t;execve("@",t,t);
3337; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00003338EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003339if { (eval echo configure:3340: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00003340 :
3341else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003342 echo "configure: failed program was:" >&5
3343 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00003344 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003345 cat >> confdefs.h <<\EOF
3346#define BAD_EXEC_PROTOTYPES 1
3347EOF
Guido van Rossumda88dad1995-01-26 00:46:29 +00003348 bad_prototypes=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00003349fi
3350rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003351echo "$ac_t""$bad_prototypes" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00003352fi
3353
Guido van Rossumda88dad1995-01-26 00:46:29 +00003354bad_forward=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003355echo $ac_n "checking for bad static forward""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003356echo "configure:3357: checking for bad static forward" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003357if test "$cross_compiling" = yes; then
3358 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
3359else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003360 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003361#line 3362 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003362#include "confdefs.h"
3363
3364struct s { int a; int b; };
3365static struct s foo;
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003366int foobar() {
3367 static int random;
3368 random = (int) &foo;
3369 return random;
3370}
Guido van Rossum7f43da71994-08-01 12:15:30 +00003371static struct s foo = { 1, 2 };
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003372main() {
3373 exit(!((int)&foo == foobar()));
3374}
Guido van Rossum7f43da71994-08-01 12:15:30 +00003375
3376EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003377if { (eval echo configure:3378: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Guido van Rossumf78abae1997-01-21 22:02:36 +00003378then
Guido van Rossum7f43da71994-08-01 12:15:30 +00003379 :
3380else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003381 echo "configure: failed program was:" >&5
3382 cat conftest.$ac_ext >&5
3383 rm -fr conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003384 cat >> confdefs.h <<\EOF
3385#define BAD_STATIC_FORWARD 1
3386EOF
Guido van Rossumda88dad1995-01-26 00:46:29 +00003387 bad_forward=yes
Guido van Rossum7f43da71994-08-01 12:15:30 +00003388fi
3389rm -fr conftest*
Guido van Rossumf78abae1997-01-21 22:02:36 +00003390fi
3391
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003392echo "$ac_t""$bad_forward" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00003393
Guido van Rossumda88dad1995-01-26 00:46:29 +00003394va_list_is_array=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003395echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003396echo "configure:3397: checking whether va_list is an array" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003397cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003398#line 3399 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003399#include "confdefs.h"
3400
3401#ifdef HAVE_STDARG_PROTOTYPES
3402#include <stdarg.h>
3403#else
3404#include <varargs.h>
3405#endif
3406
Guido van Rossumf78abae1997-01-21 22:02:36 +00003407int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003408va_list list1, list2; list1 = list2;
3409; return 0; }
3410EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003411if { (eval echo configure:3412: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003412 :
3413else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003414 echo "configure: failed program was:" >&5
3415 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003416 rm -rf conftest*
3417 cat >> confdefs.h <<\EOF
3418#define VA_LIST_IS_ARRAY 1
3419EOF
Guido van Rossumda88dad1995-01-26 00:46:29 +00003420 va_list_is_array=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003421fi
3422rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003423echo "$ac_t""$va_list_is_array" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003424
Guido van Rossum627b2d71993-12-24 10:39:16 +00003425# checks for system services
3426# (none yet)
3427
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003428# Linux requires this for correct f.p. operations
Guido van Rossumf78abae1997-01-21 22:02:36 +00003429echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003430echo "configure:3431: checking for __fpu_control in -lieee" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00003431ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003432if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003433 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003434else
3435 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003436LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003437cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003438#line 3439 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003439#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003440/* Override any gcc2 internal prototype to avoid an error. */
3441/* We use char because int might match the return type of a gcc2
3442 builtin and then its argument prototype would still apply. */
3443char __fpu_control();
Guido van Rossum627b2d71993-12-24 10:39:16 +00003444
Guido van Rossumf78abae1997-01-21 22:02:36 +00003445int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003446__fpu_control()
3447; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00003448EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003449if { (eval echo configure:3450: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00003450 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003451 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003452else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003453 echo "configure: failed program was:" >&5
3454 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00003455 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003456 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003457fi
3458rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003459LIBS="$ac_save_LIBS"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003460
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003461fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003462if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003463 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00003464 ac_tr_lib=HAVE_LIB`echo ieee | sed -e 's/[^a-zA-Z0-9_]/_/g' \
3465 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003466 cat >> confdefs.h <<EOF
3467#define $ac_tr_lib 1
3468EOF
3469
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003470 LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003471
3472else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003473 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00003474fi
3475
3476
Guido van Rossum7f253911997-05-09 02:42:48 +00003477# Check for --with-fpectl
Guido van Rossum7f253911997-05-09 02:42:48 +00003478echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003479echo "configure:3480: checking for --with-fpectl" >&5
Guido van Rossum7f253911997-05-09 02:42:48 +00003480# Check whether --with-fpectl or --without-fpectl was given.
3481if test "${with_fpectl+set}" = set; then
3482 withval="$with_fpectl"
3483
3484if test "$withval" != no
3485then cat >> confdefs.h <<\EOF
3486#define WANT_SIGFPE_HANDLER 1
3487EOF
3488 echo "$ac_t""yes" 1>&6
3489else echo "$ac_t""no" 1>&6
3490fi
3491fi
3492
3493
Guido van Rossum7f43da71994-08-01 12:15:30 +00003494# check for --with-libm=...
3495
Guido van Rossum563e7081996-09-10 18:20:48 +00003496case $ac_sys_system in
3497next) ;;
3498*) LIBM=-lm
3499esac
Guido van Rossum7f253911997-05-09 02:42:48 +00003500echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003501echo "configure:3502: checking for --with-libm=STRING" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003502# Check whether --with-libm or --without-libm was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003503if test "${with_libm+set}" = set; then
3504 withval="$with_libm"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003505
Guido van Rossum7f253911997-05-09 02:42:48 +00003506if test "$withval" = no
3507then LIBM=
3508 echo "$ac_t""force LIBM empty" 1>&6
3509elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +00003510then LIBM=$withval
Guido van Rossum7f253911997-05-09 02:42:48 +00003511 echo "$ac_t""set LIBM=\"$withval\"" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003512else { echo "configure: error: proper usage is --with-libm=STRING" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00003513fi
Guido van Rossum7f253911997-05-09 02:42:48 +00003514else
3515 echo "$ac_t""default LIBM=\"$LIBM\"" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00003516fi
3517
3518
3519# check for --with-libc=...
3520
Guido van Rossum7f253911997-05-09 02:42:48 +00003521echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003522echo "configure:3523: checking for --with-libc=STRING" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003523# Check whether --with-libc or --without-libc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003524if test "${with_libc+set}" = set; then
3525 withval="$with_libc"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003526
Guido van Rossum7f253911997-05-09 02:42:48 +00003527if test "$withval" = no
3528then LIBC=
3529 echo "$ac_t""force LIBC empty" 1>&6
3530elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +00003531then LIBC=$withval
Guido van Rossum7f253911997-05-09 02:42:48 +00003532 echo "$ac_t""set LIBC=\"$withval\"" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003533else { echo "configure: error: proper usage is --with-libc=STRING" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00003534fi
Guido van Rossum7f253911997-05-09 02:42:48 +00003535else
3536 echo "$ac_t""default LIBC=\"$LIBC\"" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00003537fi
3538
3539
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003540# check for hypot() in math library
3541LIBS_SAVE=$LIBS
3542LIBS="$LIBS $LIBM"
3543for ac_func in hypot
3544do
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003545echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003546echo "configure:3547: checking for $ac_func" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003547if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3548 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003549else
3550 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003551#line 3552 "configure"
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003552#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003553/* System header to define __stub macros and hopefully few prototypes,
3554 which can conflict with char $ac_func(); below. */
3555#include <assert.h>
3556/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003557/* We use char because int might match the return type of a gcc2
3558 builtin and then its argument prototype would still apply. */
3559char $ac_func();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003560
Guido van Rossumf78abae1997-01-21 22:02:36 +00003561int main() {
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003562
3563/* The GNU C library defines this for functions which it implements
3564 to always fail with ENOSYS. Some functions are actually named
3565 something starting with __ and the normal name is an alias. */
3566#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3567choke me
3568#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003569$ac_func();
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003570#endif
3571
3572; return 0; }
3573EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003574if { (eval echo configure:3575: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003575 rm -rf conftest*
3576 eval "ac_cv_func_$ac_func=yes"
3577else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003578 echo "configure: failed program was:" >&5
3579 cat conftest.$ac_ext >&5
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003580 rm -rf conftest*
3581 eval "ac_cv_func_$ac_func=no"
3582fi
3583rm -f conftest*
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003584fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00003585
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003586if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003587 echo "$ac_t""yes" 1>&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003588 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003589 cat >> confdefs.h <<EOF
3590#define $ac_tr_func 1
3591EOF
3592
3593else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003594 echo "$ac_t""no" 1>&6
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003595fi
3596done
3597
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003598for ac_func in hypot
3599do
3600echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003601echo "configure:3602: checking for $ac_func" >&5
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003602if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3603 echo $ac_n "(cached) $ac_c" 1>&6
3604else
3605 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003606#line 3607 "configure"
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003607#include "confdefs.h"
3608/* System header to define __stub macros and hopefully few prototypes,
3609 which can conflict with char $ac_func(); below. */
3610#include <assert.h>
3611/* Override any gcc2 internal prototype to avoid an error. */
3612/* We use char because int might match the return type of a gcc2
3613 builtin and then its argument prototype would still apply. */
3614char $ac_func();
3615
Guido van Rossumf78abae1997-01-21 22:02:36 +00003616int main() {
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003617
3618/* The GNU C library defines this for functions which it implements
3619 to always fail with ENOSYS. Some functions are actually named
3620 something starting with __ and the normal name is an alias. */
3621#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3622choke me
3623#else
3624$ac_func();
3625#endif
3626
3627; return 0; }
3628EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003629if { (eval echo configure:3630: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003630 rm -rf conftest*
3631 eval "ac_cv_func_$ac_func=yes"
3632else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003633 echo "configure: failed program was:" >&5
3634 cat conftest.$ac_ext >&5
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003635 rm -rf conftest*
3636 eval "ac_cv_func_$ac_func=no"
3637fi
3638rm -f conftest*
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003639fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00003640
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003641if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3642 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00003643 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3644 cat >> confdefs.h <<EOF
3645#define $ac_tr_func 1
3646EOF
3647
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003648else
3649 echo "$ac_t""no" 1>&6
3650LIBOBJS="$LIBOBJS ${ac_func}.o"
3651fi
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003652done
3653
Guido van Rossumf78abae1997-01-21 22:02:36 +00003654
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003655LIBS=$LIBS_SAVE
3656
Guido van Rossumda88dad1995-01-26 00:46:29 +00003657# check for getopt
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003658echo $ac_n "checking for genuine getopt""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003659echo "configure:3660: checking for genuine getopt" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003660if eval "test \"`echo '$''{'ac_cv_func_getopt'+set}'`\" = set"; then
3661 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossumda88dad1995-01-26 00:46:29 +00003662else
3663 if test "$cross_compiling" = yes; then
3664 ac_cv_func_getopt=no
3665else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003666 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003667#line 3668 "configure"
Guido van Rossumda88dad1995-01-26 00:46:29 +00003668#include "confdefs.h"
3669#include <stdio.h>
3670extern int optind, opterr, getopt();
3671extern char* optarg;
3672int main() {
3673 char* av[] = { "testprog", "parameter", "-fFlag", NULL };
3674 opterr = 0;
3675 if (getopt(3, av, "f:") == 'f') { exit(1); }
3676 exit(0);
3677}
3678EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003679if { (eval echo configure:3680: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Guido van Rossumf78abae1997-01-21 22:02:36 +00003680then
Guido van Rossumda88dad1995-01-26 00:46:29 +00003681 ac_cv_func_getopt=yes
3682else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003683 echo "configure: failed program was:" >&5
3684 cat conftest.$ac_ext >&5
3685 rm -fr conftest*
Guido van Rossumda88dad1995-01-26 00:46:29 +00003686 ac_cv_func_getopt=no
3687fi
Guido van Rossumda88dad1995-01-26 00:46:29 +00003688rm -fr conftest*
3689fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00003690
3691fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003692echo "$ac_t""$ac_cv_func_getopt" 1>&6
Guido van Rossumda88dad1995-01-26 00:46:29 +00003693test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o"
3694
Guido van Rossumad713701997-07-10 22:42:38 +00003695# check whether malloc(0) returns NULL or not
Guido van Rossumad713701997-07-10 22:42:38 +00003696echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6
Guido van Rossum91922671997-10-09 20:24:13 +00003697echo "configure:3698: checking what malloc(0) returns" >&5
Guido van Rossumad713701997-07-10 22:42:38 +00003698if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then
3699 echo $ac_n "(cached) $ac_c" 1>&6
3700else
3701 if test "$cross_compiling" = yes; then
3702 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
3703else
3704 cat > conftest.$ac_ext <<EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003705#line 3706 "configure"
Guido van Rossumad713701997-07-10 22:42:38 +00003706#include "confdefs.h"
3707#include <stdio.h>
3708#ifdef HAVE_STDLIB
3709#include <stdlib.h>
3710#else
3711char *malloc(), *realloc();
3712int *free();
3713#endif
3714main() {
3715 char *p;
3716 p = malloc(0);
3717 if (p == NULL) exit(1);
3718 p = realloc(p, 0);
3719 if (p == NULL) exit(1);
3720 free(p);
3721 exit(0);
3722}
3723EOF
Guido van Rossum91922671997-10-09 20:24:13 +00003724if { (eval echo configure:3725: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
Guido van Rossumad713701997-07-10 22:42:38 +00003725then
3726 ac_cv_malloc_zero=nonnull
3727else
3728 echo "configure: failed program was:" >&5
3729 cat conftest.$ac_ext >&5
3730 rm -fr conftest*
3731 ac_cv_malloc_zero=null
3732fi
3733rm -fr conftest*
3734fi
3735
3736fi
3737
3738echo "$ac_t""$ac_cv_malloc_zero" 1>&6
3739if test "$ac_cv_malloc_zero" = null
3740then
3741 cat >> confdefs.h <<\EOF
3742#define MALLOC_ZERO_RETURNS_NULL 1
3743EOF
3744
3745fi
3746
Guido van Rossum627b2d71993-12-24 10:39:16 +00003747# generate output files
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003748trap '' 1 2 15
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003749cat > confcache <<\EOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003750# This file is a shell script that caches the results of configure
3751# tests run on this system so they can be shared between configure
3752# scripts and configure runs. It is not useful on other systems.
3753# If it contains results you don't want to keep, you may remove or edit it.
3754#
3755# By default, configure uses ./config.cache as the cache file,
3756# creating it if it does not exist already. You can give configure
3757# the --cache-file=FILE option to use a different cache file; that is
3758# what configure does when it calls configure scripts in
3759# subdirectories, so they share the cache.
3760# Giving --cache-file=/dev/null disables caching, for debugging configure.
3761# config.status only pays attention to the cache file if you give it the
3762# --recheck option to rerun configure.
3763#
3764EOF
Guido van Rossumf78abae1997-01-21 22:02:36 +00003765# The following way of writing the cache mishandles newlines in values,
3766# but we know of no workaround that is simple, portable, and efficient.
3767# So, don't put newlines in cache variables' values.
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003768# Ultrix sh set writes to stderr and can't be redirected directly,
3769# and sets the high bit in the cache file unless we assign to the vars.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003770(set) 2>&1 |
Guido van Rossumf78abae1997-01-21 22:02:36 +00003771 case `(ac_space=' '; set) 2>&1` in
3772 *ac_space=\ *)
3773 # `set' does not quote correctly, so add quotes (double-quote substitution
3774 # turns \\\\ into \\, and sed turns \\ into \).
3775 sed -n \
3776 -e "s/'/'\\\\''/g" \
3777 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
3778 ;;
3779 *)
3780 # `set' quotes correctly as required by POSIX, so do not add quotes.
3781 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
3782 ;;
3783 esac >> confcache
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003784if cmp -s $cache_file confcache; then
3785 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003786else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003787 if test -w $cache_file; then
3788 echo "updating cache $cache_file"
3789 cat confcache > $cache_file
3790 else
3791 echo "not updating unwritable cache $cache_file"
3792 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003793fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003794rm -f confcache
Guido van Rossum0a516c91994-09-12 10:58:40 +00003795
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003796trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003797
3798test "x$prefix" = xNONE && prefix=$ac_default_prefix
3799# Let make expand exec_prefix.
3800test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
Guido van Rossum0a516c91994-09-12 10:58:40 +00003801
Guido van Rossum7f43da71994-08-01 12:15:30 +00003802# Any assignment to VPATH causes Sun make to only execute
3803# the first set of double-colon rules, so remove it if not needed.
3804# If there is a colon in the path, we need to keep it.
3805if test "x$srcdir" = x.; then
3806 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
3807fi
3808
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003809trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
Guido van Rossum627b2d71993-12-24 10:39:16 +00003810
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003811DEFS=-DHAVE_CONFIG_H
3812
3813# Without the "./", some shells look in PATH for config.status.
3814: ${CONFIG_STATUS=./config.status}
3815
3816echo creating $CONFIG_STATUS
3817rm -f $CONFIG_STATUS
3818cat > $CONFIG_STATUS <<EOF
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003819#! /bin/sh
Guido van Rossum627b2d71993-12-24 10:39:16 +00003820# Generated automatically by configure.
3821# Run this file to recreate the current configuration.
3822# This directory was configured as follows,
3823# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3824#
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003825# $0 $ac_configure_args
3826#
3827# Compiler output produced by configure, useful for debugging
3828# configure, is in ./config.log if it exists.
Guido van Rossum627b2d71993-12-24 10:39:16 +00003829
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003830ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003831for ac_option
Guido van Rossum627b2d71993-12-24 10:39:16 +00003832do
Guido van Rossum7f43da71994-08-01 12:15:30 +00003833 case "\$ac_option" in
3834 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003835 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
3836 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00003837 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
Guido van Rossumf78abae1997-01-21 22:02:36 +00003838 echo "$CONFIG_STATUS generated by autoconf version 2.12"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003839 exit 0 ;;
3840 -help | --help | --hel | --he | --h)
3841 echo "\$ac_cs_usage"; exit 0 ;;
3842 *) echo "\$ac_cs_usage"; exit 1 ;;
Guido van Rossum627b2d71993-12-24 10:39:16 +00003843 esac
3844done
3845
Guido van Rossum7f43da71994-08-01 12:15:30 +00003846ac_given_srcdir=$srcdir
Guido van Rossum627b2d71993-12-24 10:39:16 +00003847
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003848trap 'rm -fr `echo "Makefile \
3849 Objects/Makefile \
3850 Parser/Makefile \
3851 Python/Makefile \
3852 Modules/Makefile.pre config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003853EOF
3854cat >> $CONFIG_STATUS <<EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00003855
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003856# Protect against being on the right side of a sed subst in config.status.
3857sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
3858 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00003859$ac_vpsub
Guido van Rossum627b2d71993-12-24 10:39:16 +00003860$extrasub
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003861s%@CFLAGS@%$CFLAGS%g
3862s%@CPPFLAGS@%$CPPFLAGS%g
3863s%@CXXFLAGS@%$CXXFLAGS%g
3864s%@DEFS@%$DEFS%g
3865s%@LDFLAGS@%$LDFLAGS%g
3866s%@LIBS@%$LIBS%g
3867s%@exec_prefix@%$exec_prefix%g
3868s%@prefix@%$prefix%g
3869s%@program_transform_name@%$program_transform_name%g
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003870s%@bindir@%$bindir%g
3871s%@sbindir@%$sbindir%g
3872s%@libexecdir@%$libexecdir%g
3873s%@datadir@%$datadir%g
3874s%@sysconfdir@%$sysconfdir%g
3875s%@sharedstatedir@%$sharedstatedir%g
3876s%@localstatedir@%$localstatedir%g
3877s%@libdir@%$libdir%g
3878s%@includedir@%$includedir%g
3879s%@oldincludedir@%$oldincludedir%g
3880s%@infodir@%$infodir%g
3881s%@mandir@%$mandir%g
Guido van Rossum1fd74a71997-07-19 19:36:02 +00003882s%@VERSION@%$VERSION%g
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003883s%@MACHDEP@%$MACHDEP%g
Guido van Rossum91922671997-10-09 20:24:13 +00003884s%@SGI_ABI@%$SGI_ABI%g
3885s%@SET_CCC@%$SET_CCC%g
Guido van Rossum627b2d71993-12-24 10:39:16 +00003886s%@CC@%$CC%g
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003887s%@LINKCC@%$LINKCC%g
Guido van Rossum627b2d71993-12-24 10:39:16 +00003888s%@RANLIB@%$RANLIB%g
Guido van Rossum7f43da71994-08-01 12:15:30 +00003889s%@AR@%$AR%g
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003890s%@INSTALL@%$INSTALL%g
Guido van Rossumda88dad1995-01-26 00:46:29 +00003891s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
3892s%@INSTALL_DATA@%$INSTALL_DATA%g
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003893s%@OPT@%$OPT%g
Guido van Rossum627b2d71993-12-24 10:39:16 +00003894s%@CPP@%$CPP%g
Guido van Rossum0a516c91994-09-12 10:58:40 +00003895s%@SO@%$SO%g
3896s%@LDSHARED@%$LDSHARED%g
3897s%@CCSHARED@%$CCSHARED%g
3898s%@LINKFORSHARED@%$LINKFORSHARED%g
Guido van Rossumec2f0731997-01-22 20:54:01 +00003899s%@LDLAST@%$LDLAST%g
Guido van Rossum7f43da71994-08-01 12:15:30 +00003900s%@DLINCLDIR@%$DLINCLDIR%g
Guido van Rossum627b2d71993-12-24 10:39:16 +00003901s%@LIBOBJS@%$LIBOBJS%g
Guido van Rossum7f43da71994-08-01 12:15:30 +00003902s%@LIBM@%$LIBM%g
3903s%@LIBC@%$LIBC%g
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003904
3905CEOF
3906EOF
Guido van Rossumf78abae1997-01-21 22:02:36 +00003907
3908cat >> $CONFIG_STATUS <<\EOF
3909
3910# Split the substitutions into bite-sized pieces for seds with
3911# small command number limits, like on Digital OSF/1 and HP-UX.
3912ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
3913ac_file=1 # Number of current file.
3914ac_beg=1 # First line for current file.
3915ac_end=$ac_max_sed_cmds # Line after last line for current file.
3916ac_more_lines=:
3917ac_sed_cmds=""
3918while $ac_more_lines; do
3919 if test $ac_beg -gt 1; then
3920 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
3921 else
3922 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
3923 fi
3924 if test ! -s conftest.s$ac_file; then
3925 ac_more_lines=false
3926 rm -f conftest.s$ac_file
3927 else
3928 if test -z "$ac_sed_cmds"; then
3929 ac_sed_cmds="sed -f conftest.s$ac_file"
3930 else
3931 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
3932 fi
3933 ac_file=`expr $ac_file + 1`
3934 ac_beg=$ac_end
3935 ac_end=`expr $ac_end + $ac_max_sed_cmds`
3936 fi
3937done
3938if test -z "$ac_sed_cmds"; then
3939 ac_sed_cmds=cat
3940fi
3941EOF
3942
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003943cat >> $CONFIG_STATUS <<EOF
3944
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003945CONFIG_FILES=\${CONFIG_FILES-"Makefile \
3946 Objects/Makefile \
3947 Parser/Makefile \
3948 Python/Makefile \
3949 Modules/Makefile.pre"}
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003950EOF
3951cat >> $CONFIG_STATUS <<\EOF
3952for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00003953 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003954 case "$ac_file" in
Guido van Rossumf78abae1997-01-21 22:02:36 +00003955 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003956 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3957 *) ac_file_in="${ac_file}.in" ;;
3958 esac
3959
Guido van Rossumf78abae1997-01-21 22:02:36 +00003960 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003961
3962 # Remove last slash and all that follows it. Not all systems have dirname.
3963 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3964 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3965 # The file is in a subdirectory.
3966 test ! -d "$ac_dir" && mkdir "$ac_dir"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003967 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003968 # A "../" for each directory in $ac_dir_suffix.
3969 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
3970 else
3971 ac_dir_suffix= ac_dots=
3972 fi
3973
3974 case "$ac_given_srcdir" in
3975 .) srcdir=.
3976 if test -z "$ac_dots"; then top_srcdir=.
3977 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
3978 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
3979 *) # Relative path.
3980 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
3981 top_srcdir="$ac_dots$ac_given_srcdir" ;;
3982 esac
3983
Guido van Rossumf78abae1997-01-21 22:02:36 +00003984
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003985 echo creating "$ac_file"
3986 rm -f "$ac_file"
3987 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
3988 case "$ac_file" in
3989 *Makefile*) ac_comsub="1i\\
3990# $configure_input" ;;
3991 *) ac_comsub= ;;
3992 esac
Guido van Rossumf78abae1997-01-21 22:02:36 +00003993
3994 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003995 sed -e "$ac_comsub
3996s%@configure_input@%$configure_input%g
Guido van Rossum627b2d71993-12-24 10:39:16 +00003997s%@srcdir@%$srcdir%g
Guido van Rossum7f43da71994-08-01 12:15:30 +00003998s%@top_srcdir@%$top_srcdir%g
Guido van Rossumf78abae1997-01-21 22:02:36 +00003999" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
Guido van Rossum627b2d71993-12-24 10:39:16 +00004000fi; done
Guido van Rossumf78abae1997-01-21 22:02:36 +00004001rm -f conftest.s*
Guido van Rossum627b2d71993-12-24 10:39:16 +00004002
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004003# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
4004# NAME is the cpp macro being defined and VALUE is the value it is being given.
Guido van Rossum7f43da71994-08-01 12:15:30 +00004005#
4006# ac_d sets the value in "#define NAME VALUE" lines.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004007ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
4008ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
Guido van Rossum7f43da71994-08-01 12:15:30 +00004009ac_dC='\3'
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004010ac_dD='%g'
Guido van Rossum7f43da71994-08-01 12:15:30 +00004011# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004012ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
4013ac_uB='\([ ]\)%\1#\2define\3'
Guido van Rossum7f43da71994-08-01 12:15:30 +00004014ac_uC=' '
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004015ac_uD='\4%g'
Guido van Rossum7f43da71994-08-01 12:15:30 +00004016# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004017ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
4018ac_eB='$%\1#\2define\3'
Guido van Rossum7f43da71994-08-01 12:15:30 +00004019ac_eC=' '
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004020ac_eD='%g'
Guido van Rossum7f43da71994-08-01 12:15:30 +00004021
Guido van Rossumf78abae1997-01-21 22:02:36 +00004022if test "${CONFIG_HEADERS+set}" != set; then
4023EOF
4024cat >> $CONFIG_STATUS <<EOF
4025 CONFIG_HEADERS="config.h"
4026EOF
4027cat >> $CONFIG_STATUS <<\EOF
4028fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004029for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00004030 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004031 case "$ac_file" in
Guido van Rossumf78abae1997-01-21 22:02:36 +00004032 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004033 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
4034 *) ac_file_in="${ac_file}.in" ;;
4035 esac
4036
Guido van Rossum7f43da71994-08-01 12:15:30 +00004037 echo creating $ac_file
4038
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004039 rm -f conftest.frag conftest.in conftest.out
Guido van Rossumf78abae1997-01-21 22:02:36 +00004040 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4041 cat $ac_file_inputs > conftest.in
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004042
4043EOF
4044
4045# Transform confdefs.h into a sed script conftest.vals that substitutes
4046# the proper values into config.h.in to produce config.h. And first:
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004047# Protect against being on the right side of a sed subst in config.status.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004048# Protect against being in an unquoted here document in config.status.
4049rm -f conftest.vals
4050cat > conftest.hdr <<\EOF
4051s/[\\&%]/\\&/g
4052s%[\\$`]%\\&%g
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004053s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004054s%ac_d%ac_u%gp
4055s%ac_u%ac_e%gp
4056EOF
4057sed -n -f conftest.hdr confdefs.h > conftest.vals
4058rm -f conftest.hdr
4059
4060# This sed command replaces #undef with comments. This is necessary, for
4061# example, in the case of _POSIX_SOURCE, which is predefined and required
4062# on some systems where configure will not decide to define it.
4063cat >> conftest.vals <<\EOF
4064s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
4065EOF
4066
4067# Break up conftest.vals because some shells have a limit on
4068# the size of here documents, and old seds have small limits too.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004069
4070rm -f conftest.tail
4071while :
4072do
4073 ac_lines=`grep -c . conftest.vals`
4074 # grep -c gives empty output for an empty file on some AIX systems.
4075 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
4076 # Write a limited-size here document to conftest.frag.
4077 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
4078 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
4079 echo 'CEOF
4080 sed -f conftest.frag conftest.in > conftest.out
4081 rm -f conftest.in
4082 mv conftest.out conftest.in
4083' >> $CONFIG_STATUS
4084 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
4085 rm -f conftest.vals
4086 mv conftest.tail conftest.vals
4087done
4088rm -f conftest.vals
4089
4090cat >> $CONFIG_STATUS <<\EOF
4091 rm -f conftest.frag conftest.h
Guido van Rossum7f43da71994-08-01 12:15:30 +00004092 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004093 cat conftest.in >> conftest.h
4094 rm -f conftest.in
Guido van Rossum7f43da71994-08-01 12:15:30 +00004095 if cmp -s $ac_file conftest.h 2>/dev/null; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00004096 echo "$ac_file is unchanged"
4097 rm -f conftest.h
4098 else
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004099 # Remove last slash and all that follows it. Not all systems have dirname.
4100 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4101 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4102 # The file is in a subdirectory.
4103 test ! -d "$ac_dir" && mkdir "$ac_dir"
4104 fi
Guido van Rossum7f43da71994-08-01 12:15:30 +00004105 rm -f $ac_file
4106 mv conftest.h $ac_file
4107 fi
4108fi; done
4109
Guido van Rossumf78abae1997-01-21 22:02:36 +00004110EOF
4111cat >> $CONFIG_STATUS <<EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00004112
Guido van Rossumf78abae1997-01-21 22:02:36 +00004113EOF
4114cat >> $CONFIG_STATUS <<\EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00004115
4116exit 0
4117EOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004118chmod +x $CONFIG_STATUS
4119rm -fr confdefs* $ac_clean_files
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00004120test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
Guido van Rossum627b2d71993-12-24 10:39:16 +00004121