blob: fed4d637b20dcf884e0e76074e65ca46601232b9 [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 Rossum76c5fe21997-08-14 19:45:07 +00003# From configure.in Revision: 1.58
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
580 MACHDEP="$ac_sys_system$ac_sys_release"
581 fi
582fi
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000583
584# Set name for machine-dependent library files
585
586echo $ac_n "checking MACHDEP""... $ac_c" 1>&6
Guido van Rossumb06df271997-08-05 21:50:20 +0000587echo "configure:588: checking MACHDEP" >&5
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000588if test -z "$MACHDEP"
589then
Guido van Rossum563e7081996-09-10 18:20:48 +0000590 ac_sys_system=`uname -s`
591 if test "$ac_sys_system" = "AIX" ; then
592 ac_sys_release=`uname -v`
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000593 else
Guido van Rossum563e7081996-09-10 18:20:48 +0000594 ac_sys_release=`uname -r`
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000595 fi
Guido van Rossum563e7081996-09-10 18:20:48 +0000596 ac_md_system=`echo $ac_sys_system |
597 tr -d '/ ' | tr '[A-Z]' '[a-z]'`
598 ac_md_release=`echo $ac_sys_release |
599 tr -d '/ ' | sed 's/\..*//'`
600 MACHDEP="$ac_md_system$ac_md_release"
601
Guido van Rossum07397971997-04-29 21:49:50 +0000602 case $MACHDEP in
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000603 '') MACHDEP=unknown;;
604 esac
605fi
606echo "$ac_t""$MACHDEP" 1>&6
607
Guido van Rossum627b2d71993-12-24 10:39:16 +0000608# checks for alternative programs
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000609echo $ac_n "checking for --without-gcc""... $ac_c" 1>&6
Guido van Rossumb06df271997-08-05 21:50:20 +0000610echo "configure:611: checking for --without-gcc" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000611# Check whether --with-gcc or --without-gcc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000612if test "${with_gcc+set}" = set; then
613 withval="$with_gcc"
Guido van Rossum7f43da71994-08-01 12:15:30 +0000614
615 case $withval in
Guido van Rossumda88dad1995-01-26 00:46:29 +0000616 no) CC=cc
617 without_gcc=yes;;
618 yes) CC=gcc
619 without_gcc=no;;
620 *) CC=$withval
621 without_gcc=$withval;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000622 esac
Guido van Rossumda88dad1995-01-26 00:46:29 +0000623else
Guido van Rossume77438c1995-09-13 18:59:59 +0000624
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000625 case $ac_sys_system in
Guido van Rossume77438c1995-09-13 18:59:59 +0000626 OSF1) CC=cc
627 without_gcc=;;
628 *) without_gcc=no;;
629 esac
Guido van Rossum7f43da71994-08-01 12:15:30 +0000630fi
631
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000632echo "$ac_t""$without_gcc" 1>&6
Guido van Rossumda88dad1995-01-26 00:46:29 +0000633
Guido van Rossum8b131c51995-03-09 14:10:13 +0000634# If the user switches compilers, we can't believe the cache
635if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC"
636then
637 { echo "configure: error: cached CC is different -- throw away $cache_file
638(it is also a good idea to do 'make clean' before compiling)" 1>&2; exit 1; }
639fi
640
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000641# Extract the first word of "gcc", so it can be a program name with args.
642set dummy gcc; ac_word=$2
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000643echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Guido van Rossumb06df271997-08-05 21:50:20 +0000644echo "configure:645: checking for $ac_word" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000645if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
646 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000647else
648 if test -n "$CC"; then
649 ac_cv_prog_CC="$CC" # Let the user override the test.
650else
Guido van Rossum7f43da71994-08-01 12:15:30 +0000651 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
652 for ac_dir in $PATH; do
653 test -z "$ac_dir" && ac_dir=.
654 if test -f $ac_dir/$ac_word; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000655 ac_cv_prog_CC="gcc"
Guido van Rossum627b2d71993-12-24 10:39:16 +0000656 break
657 fi
658 done
Guido van Rossum7f43da71994-08-01 12:15:30 +0000659 IFS="$ac_save_ifs"
Guido van Rossum627b2d71993-12-24 10:39:16 +0000660fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000661fi
662CC="$ac_cv_prog_CC"
663if test -n "$CC"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000664 echo "$ac_t""$CC" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000665else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000666 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000667fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000668
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000669if test -z "$CC"; then
670 # Extract the first word of "cc", so it can be a program name with args.
671set dummy cc; ac_word=$2
672echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Guido van Rossumb06df271997-08-05 21:50:20 +0000673echo "configure:674: checking for $ac_word" >&5
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000674if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
675 echo $ac_n "(cached) $ac_c" 1>&6
676else
677 if test -n "$CC"; then
678 ac_cv_prog_CC="$CC" # Let the user override the test.
679else
680 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
681 ac_prog_rejected=no
682 for ac_dir in $PATH; do
683 test -z "$ac_dir" && ac_dir=.
684 if test -f $ac_dir/$ac_word; then
685 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
686 ac_prog_rejected=yes
687 continue
688 fi
689 ac_cv_prog_CC="cc"
690 break
691 fi
692 done
693 IFS="$ac_save_ifs"
694if test $ac_prog_rejected = yes; then
695 # We found a bogon in the path, so make sure we never use it.
696 set dummy $ac_cv_prog_CC
697 shift
698 if test $# -gt 0; then
699 # We chose a different compiler from the bogus one.
700 # However, it has the same basename, so the bogon will be chosen
701 # first if we set CC to just the basename; use the full file name.
702 shift
703 set dummy "$ac_dir/$ac_word" "$@"
704 shift
705 ac_cv_prog_CC="$@"
706 fi
707fi
708fi
709fi
710CC="$ac_cv_prog_CC"
711if test -n "$CC"; then
712 echo "$ac_t""$CC" 1>&6
713else
714 echo "$ac_t""no" 1>&6
715fi
716
717 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
718fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000719
Guido van Rossumf78abae1997-01-21 22:02:36 +0000720echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
Guido van Rossumb06df271997-08-05 21:50:20 +0000721echo "configure:722: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +0000722
723ac_ext=c
724# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
725ac_cpp='$CPP $CPPFLAGS'
726ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
727ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
728cross_compiling=$ac_cv_prog_cc_cross
729
730cat > conftest.$ac_ext <<EOF
Guido van Rossumb06df271997-08-05 21:50:20 +0000731#line 732 "configure"
Guido van Rossumf78abae1997-01-21 22:02:36 +0000732#include "confdefs.h"
733main(){return(0);}
734EOF
Guido van Rossumb06df271997-08-05 21:50:20 +0000735if { (eval echo configure:736: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossumf78abae1997-01-21 22:02:36 +0000736 ac_cv_prog_cc_works=yes
737 # If we can't run a trivial program, we are probably using a cross compiler.
738 if (./conftest; exit) 2>/dev/null; then
739 ac_cv_prog_cc_cross=no
740 else
741 ac_cv_prog_cc_cross=yes
742 fi
743else
744 echo "configure: failed program was:" >&5
745 cat conftest.$ac_ext >&5
746 ac_cv_prog_cc_works=no
747fi
748rm -fr conftest*
749
750echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
751if test $ac_cv_prog_cc_works = no; then
752 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
753fi
754echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
Guido van Rossumb06df271997-08-05 21:50:20 +0000755echo "configure:756: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +0000756echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
757cross_compiling=$ac_cv_prog_cc_cross
758
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000759echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
Guido van Rossumb06df271997-08-05 21:50:20 +0000760echo "configure:761: checking whether we are using GNU C" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000761if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
762 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000763else
764 cat > conftest.c <<EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +0000765#ifdef __GNUC__
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000766 yes;
Guido van Rossum627b2d71993-12-24 10:39:16 +0000767#endif
768EOF
Guido van Rossumb06df271997-08-05 21:50:20 +0000769if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:770: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000770 ac_cv_prog_gcc=yes
771else
772 ac_cv_prog_gcc=no
773fi
774fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000775
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000776echo "$ac_t""$ac_cv_prog_gcc" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +0000777
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000778if test $ac_cv_prog_gcc = yes; then
779 GCC=yes
Guido van Rossumf78abae1997-01-21 22:02:36 +0000780 ac_test_CFLAGS="${CFLAGS+set}"
781 ac_save_CFLAGS="$CFLAGS"
782 CFLAGS=
783 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
Guido van Rossumb06df271997-08-05 21:50:20 +0000784echo "configure:785: checking whether ${CC-cc} accepts -g" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +0000785if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000786 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000787else
788 echo 'void f(){}' > conftest.c
789if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
Guido van Rossumf78abae1997-01-21 22:02:36 +0000790 ac_cv_prog_cc_g=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000791else
Guido van Rossumf78abae1997-01-21 22:02:36 +0000792 ac_cv_prog_cc_g=no
Guido van Rossum627b2d71993-12-24 10:39:16 +0000793fi
794rm -f conftest*
795
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000796fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000797
Guido van Rossumf78abae1997-01-21 22:02:36 +0000798echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
799 if test "$ac_test_CFLAGS" = set; then
800 CFLAGS="$ac_save_CFLAGS"
801 elif test $ac_cv_prog_cc_g = yes; then
802 CFLAGS="-g -O2"
803 else
804 CFLAGS="-O2"
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000805 fi
806else
807 GCC=
808 test "${CFLAGS+set}" = set || CFLAGS="-g"
809fi
810
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000811
812# LINKCC is the command that links the python executable -- default is $(CC).
813# This is altered for AIX in order to build the export list before linking.
814
815echo $ac_n "checking LINKCC""... $ac_c" 1>&6
816echo "configure:817: checking LINKCC" >&5
817if test -z "$LINKCC"
818then
819 case $ac_sys_system in
820 AIX*)
821 LINKCC="makexp_aix python.exp \"\" \$(MYLIBS) \$(ADDOBJS); \$(CC)";;
822 *) LINKCC="\$(CC)";;
823 esac
824fi
825echo "$ac_t""$LINKCC" 1>&6
826
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000827# Extract the first word of "ranlib", so it can be a program name with args.
828set dummy ranlib; ac_word=$2
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000829echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000830echo "configure:831: checking for $ac_word" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000831if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
832 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000833else
834 if test -n "$RANLIB"; then
835 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
836else
Guido van Rossum7f43da71994-08-01 12:15:30 +0000837 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
838 for ac_dir in $PATH; do
839 test -z "$ac_dir" && ac_dir=.
840 if test -f $ac_dir/$ac_word; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000841 ac_cv_prog_RANLIB="ranlib"
Guido van Rossum627b2d71993-12-24 10:39:16 +0000842 break
843 fi
844 done
Guido van Rossum7f43da71994-08-01 12:15:30 +0000845 IFS="$ac_save_ifs"
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000846 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
Guido van Rossum627b2d71993-12-24 10:39:16 +0000847fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000848fi
849RANLIB="$ac_cv_prog_RANLIB"
850if test -n "$RANLIB"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000851 echo "$ac_t""$RANLIB" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000852else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000853 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000854fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000855
856
Guido van Rossum7f43da71994-08-01 12:15:30 +0000857for ac_prog in ar aal
858do
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000859# Extract the first word of "$ac_prog", so it can be a program name with args.
860set dummy $ac_prog; ac_word=$2
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000861echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000862echo "configure:863: checking for $ac_word" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000863if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
864 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000865else
866 if test -n "$AR"; then
867 ac_cv_prog_AR="$AR" # Let the user override the test.
868else
Guido van Rossum7f43da71994-08-01 12:15:30 +0000869 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
870 for ac_dir in $PATH; do
871 test -z "$ac_dir" && ac_dir=.
872 if test -f $ac_dir/$ac_word; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000873 ac_cv_prog_AR="$ac_prog"
Guido van Rossum7f43da71994-08-01 12:15:30 +0000874 break
875 fi
876 done
877 IFS="$ac_save_ifs"
878fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000879fi
880AR="$ac_cv_prog_AR"
881if test -n "$AR"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000882 echo "$ac_t""$AR" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000883else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000884 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000885fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000886
887test -n "$AR" && break
888done
889test -n "$AR" || AR="ar"
890
891
Guido van Rossumda88dad1995-01-26 00:46:29 +0000892
893
Guido van Rossumb1ba03f1994-08-19 15:34:50 +0000894# Install just never works :-(
895if test -z "$INSTALL"
Guido van Rossumda88dad1995-01-26 00:46:29 +0000896then
897 INSTALL=cp
898 INSTALL_PROGRAM=cp
899 INSTALL_DATA=cp
900else
901 INSTALL_PROGRAM="$INSTALL"
902 INSTALL_DATA="$INSTALL -m 644"
Guido van Rossumb1ba03f1994-08-19 15:34:50 +0000903fi
904
905# Optimizer/debugger flags passed between Makefiles
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000906
Guido van Rossumb1ba03f1994-08-19 15:34:50 +0000907if test -z "$OPT"
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000908then
Guido van Rossumedca74a1997-07-18 23:29:40 +0000909 case $GCC in
910 yes)
911 case $ac_cv_prog_cc_g in
912 yes) OPT="-g -O2";;
913 *) OPT="-O2";;
914 esac
915 ;;
Guido van Rossum7b3853f1996-07-30 18:09:35 +0000916 *) OPT="-O";;
917 esac
Guido van Rossumb1ba03f1994-08-19 15:34:50 +0000918fi
919
Guido van Rossum563e7081996-09-10 18:20:48 +0000920if test "$ac_arch_flags"
Guido van Rossuma68acba1996-07-31 17:36:39 +0000921then
922 OPT="$OPT $ac_arch_flags"
923fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000924# checks for UNIX variants that set C preprocessor variables
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000925echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000926echo "configure:927: checking how to run the C preprocessor" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000927# On Suns, sometimes $CPP names a directory.
928if test -n "$CPP" && test -d "$CPP"; then
929 CPP=
930fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000931if test -z "$CPP"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000932if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
933 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000934else
935 # This must be in double quotes, not single quotes, because CPP may get
936 # substituted into the Makefile and "${CC-cc}" will confuse make.
Guido van Rossum627b2d71993-12-24 10:39:16 +0000937 CPP="${CC-cc} -E"
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000938 # On the NeXT, cc -E runs the code through the compiler's parser,
939 # not just through cpp.
940 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000941#line 942 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +0000942#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000943#include <assert.h>
Guido van Rossum627b2d71993-12-24 10:39:16 +0000944Syntax Error
945EOF
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000946ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000947{ (eval echo configure:948: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000948ac_err=`grep -v '^ *+' conftest.out`
Guido van Rossum7f43da71994-08-01 12:15:30 +0000949if test -z "$ac_err"; then
950 :
951else
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000952 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +0000953 echo "configure: failed program was:" >&5
954 cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +0000955 rm -rf conftest*
956 CPP="${CC-cc} -E -traditional-cpp"
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000957 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000958#line 959 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +0000959#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000960#include <assert.h>
Guido van Rossum7f43da71994-08-01 12:15:30 +0000961Syntax Error
962EOF
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000963ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000964{ (eval echo configure:965: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000965ac_err=`grep -v '^ *+' conftest.out`
Guido van Rossum7f43da71994-08-01 12:15:30 +0000966if test -z "$ac_err"; then
Guido van Rossum627b2d71993-12-24 10:39:16 +0000967 :
968else
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000969 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +0000970 echo "configure: failed program was:" >&5
971 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +0000972 rm -rf conftest*
973 CPP=/lib/cpp
974fi
975rm -f conftest*
976fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000977rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000978 ac_cv_prog_CPP="$CPP"
Guido van Rossum7f43da71994-08-01 12:15:30 +0000979fi
Guido van Rossume77438c1995-09-13 18:59:59 +0000980 CPP="$ac_cv_prog_CPP"
981else
982 ac_cv_prog_CPP="$CPP"
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000983fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000984echo "$ac_t""$CPP" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +0000985
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000986echo $ac_n "checking for AIX""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000987echo "configure:988: checking for AIX" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000988cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +0000989#line 990 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +0000990#include "confdefs.h"
991#ifdef _AIX
992 yes
993#endif
994
995EOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000996if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
997 egrep "yes" >/dev/null 2>&1; then
Guido van Rossum627b2d71993-12-24 10:39:16 +0000998 rm -rf conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +0000999 echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001000#define _ALL_SOURCE 1
1001EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001002
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001003else
1004 rm -rf conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001005 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00001006fi
1007rm -f conftest*
1008
1009
Guido van Rossumf78abae1997-01-21 22:02:36 +00001010ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'`
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001011echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001012echo "configure:1013: checking for minix/config.h" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001013if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1014 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001015else
1016 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001017#line 1018 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001018#include "confdefs.h"
1019#include <minix/config.h>
1020EOF
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001021ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001022{ (eval echo configure:1023: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001023ac_err=`grep -v '^ *+' conftest.out`
Guido van Rossum7f43da71994-08-01 12:15:30 +00001024if test -z "$ac_err"; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001025 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001026 eval "ac_cv_header_$ac_safe=yes"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001027else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001028 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001029 echo "configure: failed program was:" >&5
1030 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001031 rm -rf conftest*
1032 eval "ac_cv_header_$ac_safe=no"
1033fi
1034rm -f conftest*
1035fi
1036if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001037 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001038 MINIX=yes
1039else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001040 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001041MINIX=
Guido van Rossum627b2d71993-12-24 10:39:16 +00001042fi
1043
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001044if test "$MINIX" = yes; then
1045 cat >> confdefs.h <<\EOF
1046#define _POSIX_SOURCE 1
1047EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001048
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001049 cat >> confdefs.h <<\EOF
1050#define _POSIX_1_SOURCE 2
1051EOF
1052
1053 cat >> confdefs.h <<\EOF
1054#define _MINIX 1
1055EOF
1056
1057fi
1058
Guido van Rossumda88dad1995-01-26 00:46:29 +00001059
Guido van Rossum201afe51997-05-14 21:14:44 +00001060echo $ac_n "checking whether $CC accepts -Olimit 1500""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001061echo "configure:1062: checking whether $CC accepts -Olimit 1500" >&5
Guido van Rossum201afe51997-05-14 21:14:44 +00001062if eval "test \"`echo '$''{'ac_cv_olimit_ok'+set}'`\" = set"; then
1063 echo $ac_n "(cached) $ac_c" 1>&6
1064else
1065 ac_save_cc="$CC"
1066CC="$CC -Olimit 1500"
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001067if test "$cross_compiling" = yes; then
1068 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1069else
1070 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001071#line 1072 "configure"
Guido van Rossum201afe51997-05-14 21:14:44 +00001072#include "confdefs.h"
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001073int main() { return 0; }
Guido van Rossum201afe51997-05-14 21:14:44 +00001074EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001075if { (eval echo configure:1076: \"$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 +00001076then
Guido van Rossum201afe51997-05-14 21:14:44 +00001077 ac_cv_olimit_ok=yes
1078else
1079 echo "configure: failed program was:" >&5
1080 cat conftest.$ac_ext >&5
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001081 rm -fr conftest*
Guido van Rossum201afe51997-05-14 21:14:44 +00001082 ac_cv_olimit_ok=no
1083fi
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001084rm -fr conftest*
1085fi
1086
Guido van Rossum201afe51997-05-14 21:14:44 +00001087CC="$ac_save_cc"
1088fi
1089
1090echo "$ac_t""$ac_cv_olimit_ok" 1>&6
1091if test $ac_cv_olimit_ok = yes; then
1092 OPT="$OPT -Olimit 1500"
1093fi
1094
Guido van Rossum84e7b241996-08-19 21:59:00 +00001095# check for ANSI or K&R ("traditional") preprocessor
1096echo $ac_n "checking for C preprocessor type""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001097echo "configure:1098: checking for C preprocessor type" >&5
Guido van Rossum84e7b241996-08-19 21:59:00 +00001098cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001099#line 1100 "configure"
Guido van Rossum84e7b241996-08-19 21:59:00 +00001100#include "confdefs.h"
1101
1102#define spam(name, doc) {#name, &name, #name "() -- " doc}
1103int foo;
1104struct {char *name; int *addr; char *doc;} desc = spam(foo, "something");
1105
Guido van Rossumf78abae1997-01-21 22:02:36 +00001106int main() {
Guido van Rossum84e7b241996-08-19 21:59:00 +00001107;
1108; return 0; }
1109EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001110if { (eval echo configure:1111: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum84e7b241996-08-19 21:59:00 +00001111 rm -rf conftest*
1112 cpp_type=ansi
1113else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001114 echo "configure: failed program was:" >&5
1115 cat conftest.$ac_ext >&5
Guido van Rossum84e7b241996-08-19 21:59:00 +00001116 rm -rf conftest*
1117 cat >> confdefs.h <<\EOF
1118#define HAVE_OLD_CPP 1
1119EOF
1120 cpp_type=traditional
1121fi
1122rm -f conftest*
Guido van Rossum84e7b241996-08-19 21:59:00 +00001123echo "$ac_t""$cpp_type" 1>&6
1124
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001125# checks for header files
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001126echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001127echo "configure:1128: checking for ANSI C header files" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001128if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1129 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001130else
1131 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001132#line 1133 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001133#include "confdefs.h"
1134#include <stdlib.h>
1135#include <stdarg.h>
1136#include <string.h>
1137#include <float.h>
1138EOF
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001139ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001140{ (eval echo configure:1141: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001141ac_err=`grep -v '^ *+' conftest.out`
Guido van Rossum7f43da71994-08-01 12:15:30 +00001142if test -z "$ac_err"; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001143 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001144 ac_cv_header_stdc=yes
1145else
1146 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001147 echo "configure: failed program was:" >&5
1148 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00001149 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001150 ac_cv_header_stdc=no
1151fi
1152rm -f conftest*
1153
1154if test $ac_cv_header_stdc = yes; then
1155 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1156cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001157#line 1158 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001158#include "confdefs.h"
1159#include <string.h>
1160EOF
1161if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1162 egrep "memchr" >/dev/null 2>&1; then
1163 :
1164else
1165 rm -rf conftest*
1166 ac_cv_header_stdc=no
1167fi
1168rm -f conftest*
1169
1170fi
1171
1172if test $ac_cv_header_stdc = yes; then
1173 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1174cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001175#line 1176 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001176#include "confdefs.h"
1177#include <stdlib.h>
1178EOF
1179if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1180 egrep "free" >/dev/null 2>&1; then
1181 :
1182else
1183 rm -rf conftest*
1184 ac_cv_header_stdc=no
1185fi
1186rm -f conftest*
1187
1188fi
1189
1190if test $ac_cv_header_stdc = yes; then
1191 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1192if test "$cross_compiling" = yes; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001193 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001194else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001195 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001196#line 1197 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001197#include "confdefs.h"
1198#include <ctype.h>
1199#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1200#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001201#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
Guido van Rossum627b2d71993-12-24 10:39:16 +00001202int main () { int i; for (i = 0; i < 256; i++)
1203if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1204exit (0); }
1205
1206EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001207if { (eval echo configure:1208: \"$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 +00001208then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001209 :
1210else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001211 echo "configure: failed program was:" >&5
1212 cat conftest.$ac_ext >&5
1213 rm -fr conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001214 ac_cv_header_stdc=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001215fi
1216rm -fr conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001217fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00001218
1219fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001220fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001221
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001222echo "$ac_t""$ac_cv_header_stdc" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001223if test $ac_cv_header_stdc = yes; then
1224 cat >> confdefs.h <<\EOF
1225#define STDC_HEADERS 1
1226EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001227
1228fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00001229
Guido van Rossum07397971997-04-29 21:49:50 +00001230for ac_hdr in dlfcn.h fcntl.h limits.h ncurses.h pthread.h \
Guido van Rossum2d38f911996-06-26 19:47:01 +00001231signal.h stdarg.h stddef.h stdlib.h thread.h unistd.h utime.h \
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001232sys/audioio.h sys/file.h sys/lock.h \
1233sys/param.h sys/select.h sys/time.h sys/times.h \
Guido van Rossum2d38f911996-06-26 19:47:01 +00001234sys/un.h sys/utsname.h sys/wait.h
Guido van Rossum627b2d71993-12-24 10:39:16 +00001235do
Guido van Rossumf78abae1997-01-21 22:02:36 +00001236ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001237echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001238echo "configure:1239: checking for $ac_hdr" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001239if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1240 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001241else
1242 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001243#line 1244 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001244#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001245#include <$ac_hdr>
Guido van Rossum627b2d71993-12-24 10:39:16 +00001246EOF
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001247ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001248{ (eval echo configure:1249: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001249ac_err=`grep -v '^ *+' conftest.out`
Guido van Rossum7f43da71994-08-01 12:15:30 +00001250if test -z "$ac_err"; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001251 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001252 eval "ac_cv_header_$ac_safe=yes"
1253else
1254 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001255 echo "configure: failed program was:" >&5
1256 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001257 rm -rf conftest*
1258 eval "ac_cv_header_$ac_safe=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001259fi
1260rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001261fi
1262if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001263 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00001264 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001265 cat >> confdefs.h <<EOF
1266#define $ac_tr_hdr 1
1267EOF
1268
1269else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001270 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001271fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00001272done
1273
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001274ac_header_dirent=no
1275for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
1276do
Guido van Rossumf78abae1997-01-21 22:02:36 +00001277ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001278echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001279echo "configure:1280: checking for $ac_hdr that defines DIR" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001280if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
1281 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00001282else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001283 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001284#line 1285 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001285#include "confdefs.h"
1286#include <sys/types.h>
1287#include <$ac_hdr>
Guido van Rossumf78abae1997-01-21 22:02:36 +00001288int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001289DIR *dirp = 0;
1290; return 0; }
1291EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001292if { (eval echo configure:1293: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001293 rm -rf conftest*
1294 eval "ac_cv_header_dirent_$ac_safe=yes"
1295else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001296 echo "configure: failed program was:" >&5
1297 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001298 rm -rf conftest*
1299 eval "ac_cv_header_dirent_$ac_safe=no"
1300fi
1301rm -f conftest*
Guido van Rossum627b2d71993-12-24 10:39:16 +00001302fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001303if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001304 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00001305 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001306 cat >> confdefs.h <<EOF
1307#define $ac_tr_hdr 1
1308EOF
1309 ac_header_dirent=$ac_hdr; break
1310else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001311 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001312fi
1313done
1314# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
1315if test $ac_header_dirent = dirent.h; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00001316echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001317echo "configure:1318: checking for opendir in -ldir" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001318ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001319if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001320 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001321else
1322 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001323LIBS="-ldir $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001324cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001325#line 1326 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001326#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001327/* Override any gcc2 internal prototype to avoid an error. */
1328/* We use char because int might match the return type of a gcc2
1329 builtin and then its argument prototype would still apply. */
1330char opendir();
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001331
Guido van Rossumf78abae1997-01-21 22:02:36 +00001332int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001333opendir()
1334; return 0; }
1335EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001336if { (eval echo configure:1337: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001337 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001338 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001339else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001340 echo "configure: failed program was:" >&5
1341 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001342 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001343 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001344fi
1345rm -f conftest*
1346LIBS="$ac_save_LIBS"
1347
1348fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001349if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001350 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001351 LIBS="$LIBS -ldir"
1352else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001353 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001354fi
1355
1356else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001357echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001358echo "configure:1359: checking for opendir in -lx" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001359ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001360if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001361 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001362else
1363 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001364LIBS="-lx $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001365cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001366#line 1367 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001367#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001368/* Override any gcc2 internal prototype to avoid an error. */
1369/* We use char because int might match the return type of a gcc2
1370 builtin and then its argument prototype would still apply. */
1371char opendir();
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001372
Guido van Rossumf78abae1997-01-21 22:02:36 +00001373int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001374opendir()
1375; return 0; }
1376EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001377if { (eval echo configure:1378: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001378 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001379 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001380else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001381 echo "configure: failed program was:" >&5
1382 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001383 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001384 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001385fi
1386rm -f conftest*
1387LIBS="$ac_save_LIBS"
1388
1389fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001390if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001391 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001392 LIBS="$LIBS -lx"
1393else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001394 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001395fi
1396
1397fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00001398
1399
1400# checks for typedefs
Guido van Rossumda88dad1995-01-26 00:46:29 +00001401was_it_defined=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001402echo $ac_n "checking for clock_t in time.h""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001403echo "configure:1404: checking for clock_t in time.h" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001404cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001405#line 1406 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001406#include "confdefs.h"
1407#include <time.h>
1408EOF
1409if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1410 egrep "clock_t" >/dev/null 2>&1; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00001411 rm -rf conftest*
1412 was_it_defined=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00001413else
1414 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001415 cat >> confdefs.h <<\EOF
1416#define clock_t long
1417EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001418
1419fi
1420rm -f conftest*
1421
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001422echo "$ac_t""$was_it_defined" 1>&6
Guido van Rossumda88dad1995-01-26 00:46:29 +00001423
Guido van Rossum84e7b241996-08-19 21:59:00 +00001424# Add some code to confdefs.h so that the test for off_t works on SCO
1425cat >> confdefs.h <<\EOF
1426#if defined(SCO_DS)
1427#undef _OFF_T
1428#endif
1429EOF
1430
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001431echo $ac_n "checking for mode_t""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001432echo "configure:1433: checking for mode_t" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001433if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
1434 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001435else
1436 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001437#line 1438 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001438#include "confdefs.h"
1439#include <sys/types.h>
1440#if STDC_HEADERS
1441#include <stdlib.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00001442#include <stddef.h>
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001443#endif
1444EOF
1445if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Guido van Rossumf78abae1997-01-21 22:02:36 +00001446 egrep "mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001447 rm -rf conftest*
1448 ac_cv_type_mode_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00001449else
1450 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001451 ac_cv_type_mode_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001452fi
1453rm -f conftest*
1454
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001455fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001456echo "$ac_t""$ac_cv_type_mode_t" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001457if test $ac_cv_type_mode_t = no; then
1458 cat >> confdefs.h <<\EOF
1459#define mode_t int
1460EOF
1461
1462fi
1463
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001464echo $ac_n "checking for off_t""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001465echo "configure:1466: checking for off_t" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001466if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
1467 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001468else
1469 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001470#line 1471 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001471#include "confdefs.h"
1472#include <sys/types.h>
1473#if STDC_HEADERS
1474#include <stdlib.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00001475#include <stddef.h>
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001476#endif
1477EOF
1478if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Guido van Rossumf78abae1997-01-21 22:02:36 +00001479 egrep "off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001480 rm -rf conftest*
1481 ac_cv_type_off_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00001482else
1483 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001484 ac_cv_type_off_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001485fi
1486rm -f conftest*
1487
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001488fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001489echo "$ac_t""$ac_cv_type_off_t" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001490if test $ac_cv_type_off_t = no; then
1491 cat >> confdefs.h <<\EOF
1492#define off_t long
1493EOF
1494
1495fi
1496
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001497echo $ac_n "checking for pid_t""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001498echo "configure:1499: checking for pid_t" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001499if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
1500 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001501else
1502 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001503#line 1504 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001504#include "confdefs.h"
1505#include <sys/types.h>
1506#if STDC_HEADERS
1507#include <stdlib.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00001508#include <stddef.h>
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001509#endif
1510EOF
1511if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Guido van Rossumf78abae1997-01-21 22:02:36 +00001512 egrep "pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001513 rm -rf conftest*
1514 ac_cv_type_pid_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00001515else
1516 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001517 ac_cv_type_pid_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001518fi
1519rm -f conftest*
1520
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001521fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001522echo "$ac_t""$ac_cv_type_pid_t" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001523if test $ac_cv_type_pid_t = no; then
1524 cat >> confdefs.h <<\EOF
1525#define pid_t int
1526EOF
1527
1528fi
1529
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001530echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001531echo "configure:1532: checking return type of signal handlers" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001532if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
1533 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001534else
1535 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001536#line 1537 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001537#include "confdefs.h"
1538#include <sys/types.h>
1539#include <signal.h>
1540#ifdef signal
1541#undef signal
1542#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001543#ifdef __cplusplus
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001544extern "C" void (*signal (int, void (*)(int)))(int);
1545#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001546void (*signal ()) ();
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001547#endif
1548
Guido van Rossumf78abae1997-01-21 22:02:36 +00001549int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001550int i;
1551; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00001552EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001553if { (eval echo configure:1554: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001554 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001555 ac_cv_type_signal=void
Guido van Rossum627b2d71993-12-24 10:39:16 +00001556else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001557 echo "configure: failed program was:" >&5
1558 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00001559 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001560 ac_cv_type_signal=int
Guido van Rossum627b2d71993-12-24 10:39:16 +00001561fi
1562rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001563fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001564
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001565echo "$ac_t""$ac_cv_type_signal" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001566cat >> confdefs.h <<EOF
1567#define RETSIGTYPE $ac_cv_type_signal
1568EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001569
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001570
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001571echo $ac_n "checking for size_t""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001572echo "configure:1573: checking for size_t" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001573if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
1574 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001575else
1576 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001577#line 1578 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001578#include "confdefs.h"
1579#include <sys/types.h>
1580#if STDC_HEADERS
1581#include <stdlib.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00001582#include <stddef.h>
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001583#endif
1584EOF
1585if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Guido van Rossumf78abae1997-01-21 22:02:36 +00001586 egrep "size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001587 rm -rf conftest*
1588 ac_cv_type_size_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00001589else
1590 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001591 ac_cv_type_size_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001592fi
1593rm -f conftest*
1594
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001595fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001596echo "$ac_t""$ac_cv_type_size_t" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001597if test $ac_cv_type_size_t = no; then
1598 cat >> confdefs.h <<\EOF
1599#define size_t unsigned
1600EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001601
1602fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001603
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001604echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001605echo "configure:1606: checking for uid_t in sys/types.h" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001606if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
1607 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001608else
1609 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001610#line 1611 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001611#include "confdefs.h"
1612#include <sys/types.h>
1613EOF
1614if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1615 egrep "uid_t" >/dev/null 2>&1; then
1616 rm -rf conftest*
1617 ac_cv_type_uid_t=yes
1618else
1619 rm -rf conftest*
1620 ac_cv_type_uid_t=no
1621fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00001622rm -f conftest*
1623
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001624fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001625
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001626echo "$ac_t""$ac_cv_type_uid_t" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001627if test $ac_cv_type_uid_t = no; then
1628 cat >> confdefs.h <<\EOF
1629#define uid_t int
1630EOF
1631
1632 cat >> confdefs.h <<\EOF
1633#define gid_t int
1634EOF
1635
1636fi
1637
Guido van Rossum627b2d71993-12-24 10:39:16 +00001638
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001639echo $ac_n "checking size of int""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001640echo "configure:1641: checking size of int" >&5
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001641if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
1642 echo $ac_n "(cached) $ac_c" 1>&6
1643else
1644 if test "$cross_compiling" = yes; then
1645 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1646else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001647 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001648#line 1649 "configure"
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001649#include "confdefs.h"
1650#include <stdio.h>
1651main()
1652{
1653 FILE *f=fopen("conftestval", "w");
1654 if (!f) exit(1);
1655 fprintf(f, "%d\n", sizeof(int));
1656 exit(0);
1657}
1658EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001659if { (eval echo configure:1660: \"$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 +00001660then
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001661 ac_cv_sizeof_int=`cat conftestval`
1662else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001663 echo "configure: failed program was:" >&5
1664 cat conftest.$ac_ext >&5
1665 rm -fr conftest*
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001666 ac_cv_sizeof_int=0
1667fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001668rm -fr conftest*
1669fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00001670
1671fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001672echo "$ac_t""$ac_cv_sizeof_int" 1>&6
1673cat >> confdefs.h <<EOF
1674#define SIZEOF_INT $ac_cv_sizeof_int
1675EOF
1676
1677
1678echo $ac_n "checking size of long""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001679echo "configure:1680: checking size of long" >&5
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001680if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
1681 echo $ac_n "(cached) $ac_c" 1>&6
1682else
1683 if test "$cross_compiling" = yes; then
1684 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1685else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001686 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001687#line 1688 "configure"
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001688#include "confdefs.h"
1689#include <stdio.h>
1690main()
1691{
1692 FILE *f=fopen("conftestval", "w");
1693 if (!f) exit(1);
1694 fprintf(f, "%d\n", sizeof(long));
1695 exit(0);
1696}
1697EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001698if { (eval echo configure:1699: \"$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 +00001699then
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001700 ac_cv_sizeof_long=`cat conftestval`
1701else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001702 echo "configure: failed program was:" >&5
1703 cat conftest.$ac_ext >&5
1704 rm -fr conftest*
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001705 ac_cv_sizeof_long=0
1706fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001707rm -fr conftest*
1708fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00001709
1710fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001711echo "$ac_t""$ac_cv_sizeof_long" 1>&6
1712cat >> confdefs.h <<EOF
1713#define SIZEOF_LONG $ac_cv_sizeof_long
1714EOF
1715
1716
Guido van Rossum0a516c91994-09-12 10:58:40 +00001717
1718# Set info about shared libraries.
Guido van Rossum0a516c91994-09-12 10:58:40 +00001719
1720
1721
1722
Guido van Rossum0a516c91994-09-12 10:58:40 +00001723# SO is the extension of shared libraries `(including the dot!)
1724# -- usually .so, .sl on HP-UX
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001725echo $ac_n "checking SO""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001726echo "configure:1727: checking SO" >&5
Guido van Rossum0a516c91994-09-12 10:58:40 +00001727if test -z "$SO"
1728then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001729 case $ac_sys_system in
Guido van Rossum563e7081996-09-10 18:20:48 +00001730 hp*|HP*) SO=.sl;;
1731 *) SO=.so;;
Guido van Rossum0a516c91994-09-12 10:58:40 +00001732 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00001733fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001734echo "$ac_t""$SO" 1>&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00001735# LDSHARED is the ld *command* used to create shared library
1736# -- "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 +00001737echo $ac_n "checking LDSHARED""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001738echo "configure:1739: checking LDSHARED" >&5
Guido van Rossum0a516c91994-09-12 10:58:40 +00001739if test -z "$LDSHARED"
1740then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001741 case $ac_sys_system/$ac_sys_release in
Guido van Rossum84e7b241996-08-19 21:59:00 +00001742 AIX*) LDSHARED="ld_so_aix \$(CC)";;
Guido van Rossum07397971997-04-29 21:49:50 +00001743 IRIX/5*) LDSHARED="ld -shared";;
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001744 IRIX*/6*) LDSHARED="ld $SGI_ABI -shared -all"; OPT="$OPT $SGI_ABI";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00001745 SunOS/4*) LDSHARED="ld";;
1746 SunOS/5*) LDSHARED="ld -G";;
1747 hp*|HP*) LDSHARED="ld -b";;
Guido van Rossumda88dad1995-01-26 00:46:29 +00001748 OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";;
1749 DYNIX/ptx*) LDSHARED="ld -G";;
Guido van Rossum563e7081996-09-10 18:20:48 +00001750 next/*) LDSHARED='$(CC) $(CFLAGS) -nostdlib -r';;
Guido van Rossum81652ab1996-07-21 02:53:27 +00001751 Linux*) LDSHARED="gcc -shared";;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001752 FreeBSD*) LDSHARED="ld -Bshareable";;
Guido van Rossum84e7b241996-08-19 21:59:00 +00001753 SCO_SV*) LDSHARED="cc -G -KPIC -Ki486 -belf -Wl,-Bexport";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00001754 *) LDSHARED="ld";;
1755 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00001756fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001757echo "$ac_t""$LDSHARED" 1>&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00001758# CCSHARED are the C *flags* used to create objects to go into a shared
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001759# library -- this is only needed for a few systems
1760echo $ac_n "checking CCSHARED""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001761echo "configure:1762: checking CCSHARED" >&5
Guido van Rossum0a516c91994-09-12 10:58:40 +00001762if test -z "$CCSHARED"
1763then
Guido van Rossum07397971997-04-29 21:49:50 +00001764 case $ac_sys_system/$ac_sys_release in
Guido van Rossumaf07a441995-02-13 19:45:27 +00001765 hp*|HP*) if test "$GCC" = yes;
1766 then CCSHARED="-fpic";
1767 else CCSHARED="+z";
1768 fi;;
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001769 Linux*) CCSHARED="-fpic";;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001770 FreeBSD*) CCSHARED="-fpic";;
Guido van Rossum84e7b241996-08-19 21:59:00 +00001771 SCO_SV*) CCSHARED="-KPIC -dy -Bdynamic";;
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001772 IRIX*/6*) CCSHARED="$SGI_ABI -all";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00001773 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00001774fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001775echo "$ac_t""$CCSHARED" 1>&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00001776# LINKFORSHARED are the flags passed to the $(CC) command that links
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001777# the python executable -- this is only needed for a few systems
1778echo $ac_n "checking LINKFORSHARED""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001779echo "configure:1780: checking LINKFORSHARED" >&5
Guido van Rossum0a516c91994-09-12 10:58:40 +00001780if test -z "$LINKFORSHARED"
1781then
Guido van Rossum07397971997-04-29 21:49:50 +00001782 case $ac_sys_system/$ac_sys_release in
Guido van Rossume4766f61997-05-13 21:04:26 +00001783 AIX*) LINKFORSHARED='-Wl,-bE:$(srcdir)/python.exp -lld';;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00001784 hp*|HP*)
1785 LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/sharedmodules";;
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001786 Linux*) LINKFORSHARED="-rdynamic";;
Guido van Rossum563e7081996-09-10 18:20:48 +00001787 next) LINKFORSHARED="-u libsys_s";;
Guido van Rossum84e7b241996-08-19 21:59:00 +00001788 SCO_SV*) LINKFORSHARED="-Bdynamic -dy -Wl,-Bexport";;
Guido van Rossumdb7098c1997-05-30 14:24:16 +00001789 IRIX*/6*) LINKFORSHARED="$SGI_ABI -all";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00001790 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00001791fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001792echo "$ac_t""$LINKFORSHARED" 1>&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00001793
Guido van Rossum627b2d71993-12-24 10:39:16 +00001794# checks for libraries
Guido van Rossumf78abae1997-01-21 22:02:36 +00001795echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001796echo "configure:1797: checking for dlopen in -ldl" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001797ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001798if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001799 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001800else
1801 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001802LIBS="-ldl $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001803cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001804#line 1805 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001805#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001806/* Override any gcc2 internal prototype to avoid an error. */
1807/* We use char because int might match the return type of a gcc2
1808 builtin and then its argument prototype would still apply. */
1809char dlopen();
Guido van Rossum627b2d71993-12-24 10:39:16 +00001810
Guido van Rossumf78abae1997-01-21 22:02:36 +00001811int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001812dlopen()
1813; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00001814EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001815if { (eval echo configure:1816: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001816 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001817 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001818else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001819 echo "configure: failed program was:" >&5
1820 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001821 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001822 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001823fi
1824rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001825LIBS="$ac_save_LIBS"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001826
Guido van Rossum627b2d71993-12-24 10:39:16 +00001827fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001828if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001829 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00001830 ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1831 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001832 cat >> confdefs.h <<EOF
1833#define $ac_tr_lib 1
1834EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001835
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001836 LIBS="-ldl $LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001837
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001838else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001839 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001840fi
1841 # Dynamic linking for SunOS/Solaris and SYSV
Guido van Rossumf78abae1997-01-21 22:02:36 +00001842echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001843echo "configure:1844: checking for shl_load in -ldld" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001844ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001845if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001846 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001847else
1848 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001849LIBS="-ldld $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001850cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001851#line 1852 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001852#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001853/* Override any gcc2 internal prototype to avoid an error. */
1854/* We use char because int might match the return type of a gcc2
1855 builtin and then its argument prototype would still apply. */
1856char shl_load();
Guido van Rossum627b2d71993-12-24 10:39:16 +00001857
Guido van Rossumf78abae1997-01-21 22:02:36 +00001858int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001859shl_load()
1860; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00001861EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001862if { (eval echo configure:1863: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001863 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001864 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001865else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001866 echo "configure: failed program was:" >&5
1867 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001868 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001869 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001870fi
1871rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001872LIBS="$ac_save_LIBS"
Guido van Rossum627b2d71993-12-24 10:39:16 +00001873
Guido van Rossum627b2d71993-12-24 10:39:16 +00001874fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001875if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001876 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00001877 ac_tr_lib=HAVE_LIB`echo dld | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1878 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001879 cat >> confdefs.h <<EOF
1880#define $ac_tr_lib 1
1881EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00001882
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001883 LIBS="-ldld $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001884
1885else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001886 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001887fi
1888 # Dynamic linking for HP-UX
Guido van Rossumf78abae1997-01-21 22:02:36 +00001889echo $ac_n "checking for getpwnam in -lsun""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001890echo "configure:1891: checking for getpwnam in -lsun" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001891ac_lib_var=`echo sun'_'getpwnam | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001892if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001893 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001894else
1895 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001896LIBS="-lsun $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001897cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001898#line 1899 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001899#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001900/* Override any gcc2 internal prototype to avoid an error. */
1901/* We use char because int might match the return type of a gcc2
1902 builtin and then its argument prototype would still apply. */
1903char getpwnam();
Guido van Rossum7f43da71994-08-01 12:15:30 +00001904
Guido van Rossumf78abae1997-01-21 22:02:36 +00001905int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001906getpwnam()
1907; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00001908EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001909if { (eval echo configure:1910: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00001910 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001911 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001912else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001913 echo "configure: failed program was:" >&5
1914 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001915 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001916 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001917fi
1918rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001919LIBS="$ac_save_LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001920
Guido van Rossum7f43da71994-08-01 12:15:30 +00001921fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001922if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001923 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00001924 ac_tr_lib=HAVE_LIB`echo sun | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1925 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001926 cat >> confdefs.h <<EOF
1927#define $ac_tr_lib 1
1928EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00001929
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001930 LIBS="-lsun $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001931
1932else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001933 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001934fi
1935 # NIS (== YP) interface for IRIX 4
Guido van Rossumda88dad1995-01-26 00:46:29 +00001936# The following three (nsl,inet,socket) are needed on Sequent;
1937# the order of checking must be this. Most SVR4 platforms will
1938# need -lsocket and -lnsl. However on SGI IRIX 5, these exist but
1939# broken. I see no elegant solution (probably CHECK_LIB should be
1940# fixed to only add the library if the given entry point is not
1941# satisfied without it).
Guido van Rossum2b3ac691996-08-30 15:18:41 +00001942if test "$ac_sys_system" != IRIX
Guido van Rossumda88dad1995-01-26 00:46:29 +00001943then
Guido van Rossumf78abae1997-01-21 22:02:36 +00001944echo $ac_n "checking for t_open in -lnsl""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001945echo "configure:1946: checking for t_open in -lnsl" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001946ac_lib_var=`echo nsl'_'t_open | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001947if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001948 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001949else
1950 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001951LIBS="-lnsl $LIBS"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001952cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001953#line 1954 "configure"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001954#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001955/* Override any gcc2 internal prototype to avoid an error. */
1956/* We use char because int might match the return type of a gcc2
1957 builtin and then its argument prototype would still apply. */
1958char t_open();
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001959
Guido van Rossumf78abae1997-01-21 22:02:36 +00001960int main() {
Guido van Rossum0ddb0281995-01-17 16:46:14 +00001961t_open()
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001962; return 0; }
1963EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001964if { (eval echo configure:1965: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001965 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001966 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001967else
Guido van Rossumf78abae1997-01-21 22:02:36 +00001968 echo "configure: failed program was:" >&5
1969 cat conftest.$ac_ext >&5
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001970 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001971 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001972fi
1973rm -f conftest*
1974LIBS="$ac_save_LIBS"
1975
1976fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001977if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001978 echo "$ac_t""yes" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001979 LIBS="-lnsl $LIBS"
1980else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001981 echo "$ac_t""no" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001982fi
Guido van Rossum0ddb0281995-01-17 16:46:14 +00001983 # SVR4
Guido van Rossumf78abae1997-01-21 22:02:36 +00001984echo $ac_n "checking for gethostbyname in -linet""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001985echo "configure:1986: checking for gethostbyname in -linet" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00001986ac_lib_var=`echo inet'_'gethostbyname | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001987if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001988 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001989else
1990 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001991LIBS="-linet -lnsl $LIBS"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001992cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00001993#line 1994 "configure"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001994#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001995/* Override any gcc2 internal prototype to avoid an error. */
1996/* We use char because int might match the return type of a gcc2
1997 builtin and then its argument prototype would still apply. */
1998char gethostbyname();
Guido van Rossum79dddcb1995-01-12 12:25:42 +00001999
Guido van Rossumf78abae1997-01-21 22:02:36 +00002000int main() {
Guido van Rossum0ddb0281995-01-17 16:46:14 +00002001gethostbyname()
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002002; return 0; }
2003EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002004if { (eval echo configure:2005: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002005 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002006 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002007else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002008 echo "configure: failed program was:" >&5
2009 cat conftest.$ac_ext >&5
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002010 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002011 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002012fi
2013rm -f conftest*
2014LIBS="$ac_save_LIBS"
2015
2016fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002017if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002018 echo "$ac_t""yes" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002019 LIBS="-linet $LIBS"
2020else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002021 echo "$ac_t""no" 1>&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002022fi
Guido van Rossum0ddb0281995-01-17 16:46:14 +00002023 # Sequent
Guido van Rossumf78abae1997-01-21 22:02:36 +00002024echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002025echo "configure:2026: checking for socket in -lsocket" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002026ac_lib_var=`echo socket'_'socket | 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 Rossum76be6ed1995-01-02 18:33:54 +00002029else
2030 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002031LIBS="-lsocket $LIBS $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002032cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002033#line 2034 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +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 socket();
Guido van Rossum7f43da71994-08-01 12:15:30 +00002039
Guido van Rossumf78abae1997-01-21 22:02:36 +00002040int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002041socket()
2042; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00002043EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002044if { (eval echo configure:2045: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00002045 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002046 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002047else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002048 echo "configure: failed program was:" >&5
2049 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002050 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002051 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002052fi
2053rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002054LIBS="$ac_save_LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002055
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002056fi
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="-lsocket $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002060else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002061 echo "$ac_t""no" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00002062fi
Guido van Rossum79dddcb1995-01-12 12:25:42 +00002063 # SVR4 sockets
Guido van Rossumda88dad1995-01-26 00:46:29 +00002064fi
Guido van Rossuma68acba1996-07-31 17:36:39 +00002065echo $ac_n "checking for --with-libs""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002066echo "configure:2067: checking for --with-libs" >&5
Guido van Rossuma68acba1996-07-31 17:36:39 +00002067# Check whether --with-libs or --without-libs was given.
2068if test "${with_libs+set}" = set; then
2069 withval="$with_libs"
2070
2071echo "$ac_t""$withval" 1>&6
2072LIBS="$withval $LIBS"
2073
2074else
2075 echo "$ac_t""no" 1>&6
2076fi
2077
Guido van Rossum7f43da71994-08-01 12:15:30 +00002078
Guido van Rossum3c83bb41996-12-31 22:35:16 +00002079echo $ac_n "checking for --with(out)-readline""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002080echo "configure:2081: checking for --with(out)-readline" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002081# Check whether --with-readline or --without-readline was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002082if test "${with_readline+set}" = set; then
2083 withval="$with_readline"
Guido van Rossumb06df271997-08-05 21:50:20 +00002084 echo "$ac_t""$withval" 1>&6
2085{ echo "configure: error: --with(out)-readline is obsolete" 1>&2; exit 1; }
Guido van Rossum3c83bb41996-12-31 22:35:16 +00002086else
Guido van Rossumb06df271997-08-05 21:50:20 +00002087 echo "$ac_t""not specified." 1>&6
Guido van Rossum3c83bb41996-12-31 22:35:16 +00002088fi
2089
Guido van Rossum7f43da71994-08-01 12:15:30 +00002090
Guido van Rossumec2f0731997-01-22 20:54:01 +00002091echo $ac_n "checking for --with-dec-threads""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002092echo "configure:2093: checking for --with-dec-threads" >&5
Guido van Rossumec2f0731997-01-22 20:54:01 +00002093
2094# Check whether --with-dec-threads or --without-dec-threads was given.
2095if test "${with_dec_threads+set}" = set; then
2096 withval="$with_dec_threads"
2097 echo "$ac_t""$withval" 1>&6
2098LDLAST=-threads
Guido van Rossumf78abae1997-01-21 22:02:36 +00002099if test "${with_thread+set}" != set; then
Guido van Rossumec2f0731997-01-22 20:54:01 +00002100 with_thread="$withval";
Guido van Rossumf78abae1997-01-21 22:02:36 +00002101fi
Guido van Rossumec2f0731997-01-22 20:54:01 +00002102else
2103 echo "$ac_t""no" 1>&6
2104fi
2105
2106
2107echo $ac_n "checking for --with-threads""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002108echo "configure:2109: checking for --with-threads" >&5
Guido van Rossumec2f0731997-01-22 20:54:01 +00002109# Check whether --with-threads or --without-threads was given.
2110if test "${with_threads+set}" = set; then
2111 withval="$with_threads"
2112 echo "$ac_t""$withval" 1>&6
2113if test "${with_thread+set}" != set; then
2114 with_thread="$withval";
2115fi
2116else
2117 echo "$ac_t""no" 1>&6
2118fi
2119
2120
2121echo $ac_n "checking for --with-thread""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002122echo "configure:2123: checking for --with-thread" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002123# Check whether --with-thread or --without-thread was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002124if test "${with_thread+set}" = set; then
2125 withval="$with_thread"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002126
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002127echo "$ac_t""$withval" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00002128if test -d "$withval"
Guido van Rossum84e7b241996-08-19 21:59:00 +00002129then LDFLAGS="$LDFLAGS -L$withval"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002130fi
Guido van Rossum9caf77a1996-08-01 00:52:26 +00002131cat >> confdefs.h <<\EOF
2132#define _REENTRANT 1
2133EOF
2134
Guido van Rossumf78abae1997-01-21 22:02:36 +00002135ac_safe=`echo "mach/cthreads.h" | sed 'y%./+-%__p_%'`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002136echo $ac_n "checking for mach/cthreads.h""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002137echo "configure:2138: checking for mach/cthreads.h" >&5
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002138if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2139 echo $ac_n "(cached) $ac_c" 1>&6
2140else
2141 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002142#line 2143 "configure"
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002143#include "confdefs.h"
2144#include <mach/cthreads.h>
2145EOF
2146ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002147{ (eval echo configure:2148: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002148ac_err=`grep -v '^ *+' conftest.out`
2149if test -z "$ac_err"; then
2150 rm -rf conftest*
2151 eval "ac_cv_header_$ac_safe=yes"
2152else
2153 echo "$ac_err" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002154 echo "configure: failed program was:" >&5
2155 cat conftest.$ac_ext >&5
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002156 rm -rf conftest*
2157 eval "ac_cv_header_$ac_safe=no"
2158fi
2159rm -f conftest*
2160fi
2161if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2162 echo "$ac_t""yes" 1>&6
2163 cat >> confdefs.h <<\EOF
2164#define WITH_THREAD 1
2165EOF
2166
2167cat >> confdefs.h <<\EOF
2168#define C_THREADS 1
2169EOF
2170
2171LIBOBJS="$LIBOBJS thread.o"
2172else
2173 echo "$ac_t""no" 1>&6
2174
Guido van Rossumf78abae1997-01-21 22:02:36 +00002175echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002176echo "configure:2177: checking for pthread_create in -lpthreads" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002177ac_lib_var=`echo pthreads'_'pthread_create | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002178if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002179 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002180else
2181 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002182LIBS="-lpthreads $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002183cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002184#line 2185 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002185#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002186/* Override any gcc2 internal prototype to avoid an error. */
2187/* We use char because int might match the return type of a gcc2
2188 builtin and then its argument prototype would still apply. */
2189char pthread_create();
Guido van Rossum7f43da71994-08-01 12:15:30 +00002190
Guido van Rossumf78abae1997-01-21 22:02:36 +00002191int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002192pthread_create()
2193; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00002194EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002195if { (eval echo configure:2196: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00002196 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002197 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002198else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002199 echo "configure: failed program was:" >&5
2200 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002201 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002202 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002203fi
2204rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002205LIBS="$ac_save_LIBS"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002206
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002207fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002208if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002209 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002210 cat >> confdefs.h <<\EOF
2211#define WITH_THREAD 1
2212EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00002213
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002214cat >> confdefs.h <<\EOF
2215#define _POSIX_THREADS 1
2216EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00002217
2218LIBS="$LIBS -lpthreads"
2219LIBOBJS="$LIBOBJS thread.o"
2220else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002221 echo "$ac_t""no" 1>&6
Guido van Rossum2d38f911996-06-26 19:47:01 +00002222
Guido van Rossumf78abae1997-01-21 22:02:36 +00002223echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002224echo "configure:2225: checking for pthread_create in -lpthread" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002225ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'`
Guido van Rossum2d38f911996-06-26 19:47:01 +00002226if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2227 echo $ac_n "(cached) $ac_c" 1>&6
2228else
2229 ac_save_LIBS="$LIBS"
2230LIBS="-lpthread $LIBS"
2231cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002232#line 2233 "configure"
Guido van Rossum2d38f911996-06-26 19:47:01 +00002233#include "confdefs.h"
2234/* Override any gcc2 internal prototype to avoid an error. */
2235/* We use char because int might match the return type of a gcc2
2236 builtin and then its argument prototype would still apply. */
2237char pthread_create();
2238
Guido van Rossumf78abae1997-01-21 22:02:36 +00002239int main() {
Guido van Rossum2d38f911996-06-26 19:47:01 +00002240pthread_create()
2241; return 0; }
2242EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002243if { (eval echo configure:2244: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum2d38f911996-06-26 19:47:01 +00002244 rm -rf conftest*
2245 eval "ac_cv_lib_$ac_lib_var=yes"
2246else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002247 echo "configure: failed program was:" >&5
2248 cat conftest.$ac_ext >&5
Guido van Rossum2d38f911996-06-26 19:47:01 +00002249 rm -rf conftest*
2250 eval "ac_cv_lib_$ac_lib_var=no"
2251fi
2252rm -f conftest*
2253LIBS="$ac_save_LIBS"
2254
2255fi
2256if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2257 echo "$ac_t""yes" 1>&6
2258 cat >> confdefs.h <<\EOF
2259#define WITH_THREAD 1
2260EOF
2261
2262cat >> confdefs.h <<\EOF
2263#define _POSIX_THREADS 1
2264EOF
2265
2266LIBS="$LIBS -lpthread"
2267LIBOBJS="$LIBOBJS thread.o"
2268else
2269 echo "$ac_t""no" 1>&6
Guido van Rossum0be3e491997-05-22 20:33:33 +00002270
2271echo $ac_n "checking for __d6_pthread_create in -lthread""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002272echo "configure:2273: checking for __d6_pthread_create in -lthread" >&5
Guido van Rossum0be3e491997-05-22 20:33:33 +00002273ac_lib_var=`echo thread'_'__d6_pthread_create | sed 'y%./+-%__p_%'`
2274if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2275 echo $ac_n "(cached) $ac_c" 1>&6
2276else
2277 ac_save_LIBS="$LIBS"
2278LIBS="-lthread $LIBS"
2279cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002280#line 2281 "configure"
Guido van Rossum0be3e491997-05-22 20:33:33 +00002281#include "confdefs.h"
2282/* Override any gcc2 internal prototype to avoid an error. */
2283/* We use char because int might match the return type of a gcc2
2284 builtin and then its argument prototype would still apply. */
2285char __d6_pthread_create();
2286
2287int main() {
2288__d6_pthread_create()
2289; return 0; }
2290EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002291if { (eval echo configure:2292: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum0be3e491997-05-22 20:33:33 +00002292 rm -rf conftest*
2293 eval "ac_cv_lib_$ac_lib_var=yes"
2294else
2295 echo "configure: failed program was:" >&5
2296 cat conftest.$ac_ext >&5
2297 rm -rf conftest*
2298 eval "ac_cv_lib_$ac_lib_var=no"
2299fi
2300rm -f conftest*
2301LIBS="$ac_save_LIBS"
2302
2303fi
2304if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2305 echo "$ac_t""yes" 1>&6
2306 cat >> confdefs.h <<\EOF
2307#define WITH_THREAD 1
2308EOF
2309
2310cat >> confdefs.h <<\EOF
2311#define _POSIX_THREADS 1
2312EOF
2313
2314LIBS="$LIBS -lthread"
2315LIBOBJS="$LIBOBJS thread.o"
2316else
2317 echo "$ac_t""no" 1>&6
Guido van Rossum2d38f911996-06-26 19:47:01 +00002318fi
2319
2320
Guido van Rossum627b2d71993-12-24 10:39:16 +00002321fi
2322
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002323fi
2324
Guido van Rossum0be3e491997-05-22 20:33:33 +00002325fi
2326
2327
Guido van Rossumf78abae1997-01-21 22:02:36 +00002328echo $ac_n "checking for usconfig in -lmpc""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002329echo "configure:2330: checking for usconfig in -lmpc" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002330ac_lib_var=`echo mpc'_'usconfig | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002331if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002332 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002333else
2334 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002335LIBS="-lmpc $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002336cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002337#line 2338 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002338#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002339/* Override any gcc2 internal prototype to avoid an error. */
2340/* We use char because int might match the return type of a gcc2
2341 builtin and then its argument prototype would still apply. */
2342char usconfig();
Guido van Rossum627b2d71993-12-24 10:39:16 +00002343
Guido van Rossumf78abae1997-01-21 22:02:36 +00002344int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002345usconfig()
2346; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002347EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002348if { (eval echo configure:2349: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002349 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002350 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002351else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002352 echo "configure: failed program was:" >&5
2353 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002354 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002355 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002356fi
2357rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002358LIBS="$ac_save_LIBS"
2359
2360fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002361if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002362 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002363 cat >> confdefs.h <<\EOF
2364#define WITH_THREAD 1
2365EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00002366
Guido van Rossum7f43da71994-08-01 12:15:30 +00002367LIBS="$LIBS -lmpc"
2368LIBOBJS="$LIBOBJS thread.o"
2369else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002370 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00002371fi
2372
Guido van Rossumf78abae1997-01-21 22:02:36 +00002373echo $ac_n "checking for thr_create in -lthread""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002374echo "configure:2375: checking for thr_create in -lthread" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00002375ac_lib_var=`echo thread'_'thr_create | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002376if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002377 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002378else
2379 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002380LIBS="-lthread $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002381cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002382#line 2383 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002383#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002384/* Override any gcc2 internal prototype to avoid an error. */
2385/* We use char because int might match the return type of a gcc2
2386 builtin and then its argument prototype would still apply. */
2387char thr_create();
Guido van Rossum627b2d71993-12-24 10:39:16 +00002388
Guido van Rossumf78abae1997-01-21 22:02:36 +00002389int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002390thr_create()
2391; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002392EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002393if { (eval echo configure:2394: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002394 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002395 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002396else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002397 echo "configure: failed program was:" >&5
2398 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002399 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002400 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002401fi
2402rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002403LIBS="$ac_save_LIBS"
2404
2405fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002406if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002407 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002408 cat >> confdefs.h <<\EOF
2409#define WITH_THREAD 1
2410EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00002411
Guido van Rossum7f43da71994-08-01 12:15:30 +00002412LIBS="$LIBS -lthread"
2413LIBOBJS="$LIBOBJS thread.o"
2414else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002415 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00002416fi
2417
Guido van Rossum7f43da71994-08-01 12:15:30 +00002418
Guido van Rossumda88dad1995-01-26 00:46:29 +00002419else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002420 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00002421fi
2422
Guido van Rossum7f43da71994-08-01 12:15:30 +00002423
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002424# -I${DLINCLDIR} is added to the compile rule for importdl.o
Guido van Rossum7f43da71994-08-01 12:15:30 +00002425
2426DLINCLDIR=/
2427
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002428echo $ac_n "checking for --with-sgi-dl""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002429echo "configure:2430: checking for --with-sgi-dl" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002430# Check whether --with-sgi-dl or --without-sgi-dl was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002431if test "${with_sgi_dl+set}" = set; then
2432 withval="$with_sgi_dl"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002433
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002434echo "$ac_t""$withval" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002435cat >> confdefs.h <<\EOF
2436#define WITH_SGI_DL 1
2437EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00002438
2439dldir=$withval
2440if test -d "$dldir"
Guido van Rossum84e7b241996-08-19 21:59:00 +00002441then LDFLAGS="$LDFLAGS -L$dldir"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002442else { echo "configure: error: proper usage is --with-sgi-dl=DIRECTORY" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00002443fi
2444DLINCLDIR=${dldir}
2445LIBS="$LIBS -ldl -lmld"
Guido van Rossumda88dad1995-01-26 00:46:29 +00002446else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002447 echo "$ac_t""no" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00002448fi
2449
2450
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002451echo $ac_n "checking for --with-dl-dld""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002452echo "configure:2453: checking for --with-dl-dld" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002453# Check whether --with-dl-dld or --without-dl-dld was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002454if test "${with_dl_dld+set}" = set; then
2455 withval="$with_dl_dld"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002456
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002457echo "$ac_t""$withval" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002458cat >> confdefs.h <<\EOF
2459#define WITH_DL_DLD 1
2460EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00002461
2462dldir=`echo "$withval" | sed 's/,.*//'`
2463dlddir=`echo "$withval" | sed 's/.*,//'`
2464if test -d "$dldir" -a -d "$dlddir"
Guido van Rossum84e7b241996-08-19 21:59:00 +00002465then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002466else { echo "configure: error: proper usage is --with-dl-dld=DL_DIRECTORY" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00002467fi
2468DLINCLDIR=${dldir}
2469LIBS="$LIBS -ldl -ldld"
Guido van Rossumda88dad1995-01-26 00:46:29 +00002470else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002471 echo "$ac_t""no" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00002472fi
2473
2474
Guido van Rossum627b2d71993-12-24 10:39:16 +00002475# checks for library functions
Guido van Rossum0be3e491997-05-22 20:33:33 +00002476for ac_func in chown clock dlopen execv flock fork ftime ftruncate \
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002477 gethostname_r getpeername getpgrp getpid gettimeofday getwd \
Guido van Rossum0be3e491997-05-22 20:33:33 +00002478 kill link lstat mkfifo nice plock putenv readlink \
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002479 select setgid setuid setsid setpgid setpgrp setvbuf \
2480 sigaction siginterrupt sigrelse strftime symlink \
2481 tcgetpgrp tcsetpgrp times truncate uname waitpid
Guido van Rossum627b2d71993-12-24 10:39:16 +00002482do
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002483echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002484echo "configure:2485: checking for $ac_func" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002485if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2486 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002487else
2488 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002489#line 2490 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002490#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002491/* System header to define __stub macros and hopefully few prototypes,
2492 which can conflict with char $ac_func(); below. */
2493#include <assert.h>
2494/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002495/* We use char because int might match the return type of a gcc2
2496 builtin and then its argument prototype would still apply. */
2497char $ac_func();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002498
Guido van Rossumf78abae1997-01-21 22:02:36 +00002499int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002500
Guido van Rossum627b2d71993-12-24 10:39:16 +00002501/* The GNU C library defines this for functions which it implements
2502 to always fail with ENOSYS. Some functions are actually named
2503 something starting with __ and the normal name is an alias. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002504#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +00002505choke me
2506#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002507$ac_func();
Guido van Rossum627b2d71993-12-24 10:39:16 +00002508#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002509
Guido van Rossum7f43da71994-08-01 12:15:30 +00002510; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002511EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002512if { (eval echo configure:2513: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002513 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002514 eval "ac_cv_func_$ac_func=yes"
2515else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002516 echo "configure: failed program was:" >&5
2517 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002518 rm -rf conftest*
2519 eval "ac_cv_func_$ac_func=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002520fi
2521rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002522fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00002523
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002524if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002525 echo "$ac_t""yes" 1>&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002526 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002527 cat >> confdefs.h <<EOF
2528#define $ac_tr_func 1
2529EOF
2530
2531else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002532 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002533fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00002534done
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002535
Guido van Rossum2b3ac691996-08-30 15:18:41 +00002536for ac_func in dup2 getcwd strdup strerror memmove
Guido van Rossum627b2d71993-12-24 10:39:16 +00002537do
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002538echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002539echo "configure:2540: checking for $ac_func" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002540if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2541 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002542else
2543 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002544#line 2545 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002545#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002546/* System header to define __stub macros and hopefully few prototypes,
2547 which can conflict with char $ac_func(); below. */
2548#include <assert.h>
2549/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002550/* We use char because int might match the return type of a gcc2
2551 builtin and then its argument prototype would still apply. */
2552char $ac_func();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002553
Guido van Rossumf78abae1997-01-21 22:02:36 +00002554int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002555
Guido van Rossum627b2d71993-12-24 10:39:16 +00002556/* The GNU C library defines this for functions which it implements
2557 to always fail with ENOSYS. Some functions are actually named
2558 something starting with __ and the normal name is an alias. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002559#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +00002560choke me
2561#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002562$ac_func();
Guido van Rossum627b2d71993-12-24 10:39:16 +00002563#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002564
Guido van Rossum7f43da71994-08-01 12:15:30 +00002565; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002566EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002567if { (eval echo configure:2568: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002568 rm -rf conftest*
2569 eval "ac_cv_func_$ac_func=yes"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002570else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002571 echo "configure: failed program was:" >&5
2572 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00002573 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002574 eval "ac_cv_func_$ac_func=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002575fi
2576rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002577fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00002578
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002579if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002580 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00002581 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2582 cat >> confdefs.h <<EOF
2583#define $ac_tr_func 1
2584EOF
2585
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002586else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002587 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002588LIBOBJS="$LIBOBJS ${ac_func}.o"
2589fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00002590done
2591
Guido van Rossumf78abae1997-01-21 22:02:36 +00002592
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002593echo $ac_n "checking for getpgrp""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002594echo "configure:2595: checking for getpgrp" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002595if eval "test \"`echo '$''{'ac_cv_func_getpgrp'+set}'`\" = set"; then
2596 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002597else
2598 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002599#line 2600 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002600#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002601/* System header to define __stub macros and hopefully few prototypes,
2602 which can conflict with char getpgrp(); below. */
2603#include <assert.h>
2604/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002605/* We use char because int might match the return type of a gcc2
2606 builtin and then its argument prototype would still apply. */
2607char getpgrp();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002608
Guido van Rossumf78abae1997-01-21 22:02:36 +00002609int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002610
Guido van Rossum627b2d71993-12-24 10:39:16 +00002611/* The GNU C library defines this for functions which it implements
2612 to always fail with ENOSYS. Some functions are actually named
2613 something starting with __ and the normal name is an alias. */
2614#if defined (__stub_getpgrp) || defined (__stub___getpgrp)
2615choke me
2616#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002617getpgrp();
Guido van Rossum627b2d71993-12-24 10:39:16 +00002618#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002619
2620; return 0; }
2621EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002622if { (eval echo configure:2623: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002623 rm -rf conftest*
2624 eval "ac_cv_func_getpgrp=yes"
2625else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002626 echo "configure: failed program was:" >&5
2627 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002628 rm -rf conftest*
2629 eval "ac_cv_func_getpgrp=no"
2630fi
2631rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002632fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00002633
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002634if eval "test \"`echo '$ac_cv_func_'getpgrp`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002635 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002636 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002637#line 2638 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002638#include "confdefs.h"
2639#include <unistd.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002640int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002641getpgrp(0);
Guido van Rossum7f43da71994-08-01 12:15:30 +00002642; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002643EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002644if { (eval echo configure:2645: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002645 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002646 cat >> confdefs.h <<\EOF
2647#define GETPGRP_HAVE_ARG 1
Guido van Rossum627b2d71993-12-24 10:39:16 +00002648EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00002649
Guido van Rossumf78abae1997-01-21 22:02:36 +00002650else
2651 echo "configure: failed program was:" >&5
2652 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00002653fi
2654rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002655else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002656 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00002657fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00002658
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002659echo $ac_n "checking for setpgrp""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002660echo "configure:2661: checking for setpgrp" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002661if eval "test \"`echo '$''{'ac_cv_func_setpgrp'+set}'`\" = set"; then
2662 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002663else
2664 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002665#line 2666 "configure"
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002666#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002667/* System header to define __stub macros and hopefully few prototypes,
2668 which can conflict with char setpgrp(); below. */
2669#include <assert.h>
2670/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002671/* We use char because int might match the return type of a gcc2
2672 builtin and then its argument prototype would still apply. */
2673char setpgrp();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002674
Guido van Rossumf78abae1997-01-21 22:02:36 +00002675int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002676
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002677/* The GNU C library defines this for functions which it implements
2678 to always fail with ENOSYS. Some functions are actually named
2679 something starting with __ and the normal name is an alias. */
2680#if defined (__stub_setpgrp) || defined (__stub___setpgrp)
2681choke me
2682#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002683setpgrp();
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002684#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002685
2686; return 0; }
2687EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002688if { (eval echo configure:2689: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002689 rm -rf conftest*
2690 eval "ac_cv_func_setpgrp=yes"
2691else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002692 echo "configure: failed program was:" >&5
2693 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002694 rm -rf conftest*
2695 eval "ac_cv_func_setpgrp=no"
2696fi
2697rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002698fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00002699
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002700if eval "test \"`echo '$ac_cv_func_'setpgrp`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002701 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002702 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002703#line 2704 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002704#include "confdefs.h"
2705#include <unistd.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002706int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002707setpgrp(0,0);
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002708; return 0; }
2709EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002710if { (eval echo configure:2711: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002711 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002712 cat >> confdefs.h <<\EOF
2713#define SETPGRP_HAVE_ARG 1
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002714EOF
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002715
Guido van Rossumf78abae1997-01-21 22:02:36 +00002716else
2717 echo "configure: failed program was:" >&5
2718 cat conftest.$ac_ext >&5
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002719fi
2720rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002721else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002722 echo "$ac_t""no" 1>&6
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002723fi
Guido van Rossum8eee56f1994-10-20 22:18:37 +00002724
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002725echo $ac_n "checking for gettimeofday""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002726echo "configure:2727: checking for gettimeofday" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002727if eval "test \"`echo '$''{'ac_cv_func_gettimeofday'+set}'`\" = set"; then
2728 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002729else
2730 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002731#line 2732 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002732#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002733/* System header to define __stub macros and hopefully few prototypes,
2734 which can conflict with char gettimeofday(); below. */
2735#include <assert.h>
2736/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002737/* We use char because int might match the return type of a gcc2
2738 builtin and then its argument prototype would still apply. */
2739char gettimeofday();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002740
Guido van Rossumf78abae1997-01-21 22:02:36 +00002741int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002742
2743/* The GNU C library defines this for functions which it implements
2744 to always fail with ENOSYS. Some functions are actually named
2745 something starting with __ and the normal name is an alias. */
2746#if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
2747choke me
2748#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002749gettimeofday();
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002750#endif
2751
2752; return 0; }
2753EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002754if { (eval echo configure:2755: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002755 rm -rf conftest*
2756 eval "ac_cv_func_gettimeofday=yes"
2757else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002758 echo "configure: failed program was:" >&5
2759 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002760 rm -rf conftest*
2761 eval "ac_cv_func_gettimeofday=no"
2762fi
2763rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002764fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00002765
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002766if eval "test \"`echo '$ac_cv_func_'gettimeofday`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002767 echo "$ac_t""yes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002768 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002769#line 2770 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002770#include "confdefs.h"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002771#include <sys/time.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002772int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002773gettimeofday((struct timeval*)0,(struct timezone*)0);
2774; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002775EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002776if { (eval echo configure:2777: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002777 :
2778else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002779 echo "configure: failed program was:" >&5
2780 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00002781 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002782 cat >> confdefs.h <<\EOF
2783#define GETTIMEOFDAY_NO_TZ 1
2784EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00002785
2786fi
2787rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002788else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002789 echo "$ac_t""no" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002790fi
2791
2792
2793# checks for structures
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002794echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002795echo "configure:2796: checking whether time.h and sys/time.h may both be included" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002796if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
2797 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002798else
2799 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002800#line 2801 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002801#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002802#include <sys/types.h>
2803#include <sys/time.h>
2804#include <time.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002805int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002806struct tm *tp;
2807; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002808EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002809if { (eval echo configure:2810: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002810 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002811 ac_cv_header_time=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00002812else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002813 echo "configure: failed program was:" >&5
2814 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00002815 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002816 ac_cv_header_time=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00002817fi
2818rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002819fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002820
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002821echo "$ac_t""$ac_cv_header_time" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002822if test $ac_cv_header_time = yes; then
2823 cat >> confdefs.h <<\EOF
2824#define TIME_WITH_SYS_TIME 1
2825EOF
2826
2827fi
2828
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002829echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002830echo "configure:2831: checking whether struct tm is in sys/time.h or time.h" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002831if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
2832 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002833else
2834 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002835#line 2836 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002836#include "confdefs.h"
2837#include <sys/types.h>
2838#include <time.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002839int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002840struct tm *tp; tp->tm_sec;
2841; return 0; }
2842EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002843if { (eval echo configure:2844: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002844 rm -rf conftest*
2845 ac_cv_struct_tm=time.h
2846else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002847 echo "configure: failed program was:" >&5
2848 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002849 rm -rf conftest*
2850 ac_cv_struct_tm=sys/time.h
2851fi
2852rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002853fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002854
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002855echo "$ac_t""$ac_cv_struct_tm" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002856if test $ac_cv_struct_tm = sys/time.h; then
2857 cat >> confdefs.h <<\EOF
2858#define TM_IN_SYS_TIME 1
2859EOF
2860
2861fi
2862
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002863echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002864echo "configure:2865: checking for tm_zone in struct tm" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002865if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then
2866 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002867else
2868 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002869#line 2870 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002870#include "confdefs.h"
2871#include <sys/types.h>
2872#include <$ac_cv_struct_tm>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002873int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002874struct tm tm; tm.tm_zone;
2875; return 0; }
2876EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002877if { (eval echo configure:2878: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002878 rm -rf conftest*
2879 ac_cv_struct_tm_zone=yes
2880else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002881 echo "configure: failed program was:" >&5
2882 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002883 rm -rf conftest*
2884 ac_cv_struct_tm_zone=no
2885fi
2886rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002887fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002888
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002889echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002890if test "$ac_cv_struct_tm_zone" = yes; then
2891 cat >> confdefs.h <<\EOF
2892#define HAVE_TM_ZONE 1
2893EOF
2894
2895else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002896 echo $ac_n "checking for tzname""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002897echo "configure:2898: checking for tzname" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002898if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then
2899 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002900else
2901 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002902#line 2903 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00002903#include "confdefs.h"
2904#include <time.h>
2905#ifndef tzname /* For SGI. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002906extern char *tzname[]; /* RS6000 and others reject char **tzname. */
Guido van Rossum627b2d71993-12-24 10:39:16 +00002907#endif
Guido van Rossumf78abae1997-01-21 22:02:36 +00002908int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002909atoi(*tzname);
2910; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002911EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002912if { (eval echo configure:2913: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00002913 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002914 ac_cv_var_tzname=yes
2915else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002916 echo "configure: failed program was:" >&5
2917 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002918 rm -rf conftest*
2919 ac_cv_var_tzname=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00002920fi
2921rm -f conftest*
Guido van Rossum627b2d71993-12-24 10:39:16 +00002922fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002923
2924echo "$ac_t""$ac_cv_var_tzname" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002925 if test $ac_cv_var_tzname = yes; then
2926 cat >> confdefs.h <<\EOF
2927#define HAVE_TZNAME 1
2928EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00002929
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002930 fi
2931fi
2932
2933
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002934echo $ac_n "checking for time.h that defines altzone""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002935echo "configure:2936: checking for time.h that defines altzone" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002936if eval "test \"`echo '$''{'ac_cv_header_time_altzone'+set}'`\" = set"; then
2937 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002938else
2939 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002940#line 2941 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002941#include "confdefs.h"
2942#include <time.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00002943int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002944return altzone;
2945; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00002946EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002947if { (eval echo configure:2948: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00002948 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002949 ac_cv_header_time_altzone=yes
2950else
Guido van Rossumf78abae1997-01-21 22:02:36 +00002951 echo "configure: failed program was:" >&5
2952 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002953 rm -rf conftest*
2954 ac_cv_header_time_altzone=no
Guido van Rossum7f43da71994-08-01 12:15:30 +00002955fi
2956rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002957fi
2958
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002959echo "$ac_t""$ac_cv_header_time_altzone" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002960if test $ac_cv_header_time_altzone = yes; then
2961 cat >> confdefs.h <<\EOF
2962#define HAVE_ALTZONE 1
2963EOF
2964
2965fi
2966
Guido van Rossumda88dad1995-01-26 00:46:29 +00002967was_it_defined=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002968echo $ac_n "checking whether sys/select.h and sys/time.h may both be included""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002969echo "configure:2970: checking whether sys/select.h and sys/time.h may both be included" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002970cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002971#line 2972 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00002972#include "confdefs.h"
2973
2974#include <sys/types.h>
2975#include <sys/select.h>
2976#include <sys/time.h>
2977
Guido van Rossumf78abae1997-01-21 22:02:36 +00002978int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002979;
2980; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00002981EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002982if { (eval echo configure:2983: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00002983 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002984 cat >> confdefs.h <<\EOF
2985#define SYS_SELECT_WITH_SYS_TIME 1
2986EOF
Guido van Rossumda88dad1995-01-26 00:46:29 +00002987 was_it_defined=yes
Guido van Rossumf78abae1997-01-21 22:02:36 +00002988else
2989 echo "configure: failed program was:" >&5
2990 cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +00002991fi
2992rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002993echo "$ac_t""$was_it_defined" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00002994
2995# checks for compiler characteristics
Guido van Rossum7f43da71994-08-01 12:15:30 +00002996
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002997echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00002998echo "configure:2999: checking whether char is unsigned" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00002999if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then
3000 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003001else
3002 if test "$GCC" = yes; then
3003 # GCC predefines this symbol on systems where it applies.
3004cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003005#line 3006 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003006#include "confdefs.h"
3007#ifdef __CHAR_UNSIGNED__
3008 yes
3009#endif
3010
3011EOF
3012if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3013 egrep "yes" >/dev/null 2>&1; then
3014 rm -rf conftest*
3015 ac_cv_c_char_unsigned=yes
3016else
3017 rm -rf conftest*
3018 ac_cv_c_char_unsigned=no
3019fi
3020rm -f conftest*
3021
3022else
3023if test "$cross_compiling" = yes; then
3024 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
3025else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003026 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003027#line 3028 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003028#include "confdefs.h"
3029/* volatile prevents gcc2 from optimizing the test away on sparcs. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003030#if !defined(__STDC__) || __STDC__ != 1
Guido van Rossum7f43da71994-08-01 12:15:30 +00003031#define volatile
3032#endif
3033main() {
Guido van Rossum7f43da71994-08-01 12:15:30 +00003034 volatile char c = 255; exit(c < 0);
Guido van Rossum7f43da71994-08-01 12:15:30 +00003035}
3036EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003037if { (eval echo configure:3038: \"$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 +00003038then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003039 ac_cv_c_char_unsigned=yes
3040else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003041 echo "configure: failed program was:" >&5
3042 cat conftest.$ac_ext >&5
3043 rm -fr conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003044 ac_cv_c_char_unsigned=no
3045fi
Guido van Rossum7f43da71994-08-01 12:15:30 +00003046rm -fr conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003047fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00003048
3049fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003050fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003051
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003052echo "$ac_t""$ac_cv_c_char_unsigned" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003053if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
3054 cat >> confdefs.h <<\EOF
3055#define __CHAR_UNSIGNED__ 1
3056EOF
3057
3058fi
Guido van Rossum7f43da71994-08-01 12:15:30 +00003059
3060
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003061echo $ac_n "checking for working const""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003062echo "configure:3063: checking for working const" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003063if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
3064 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003065else
3066 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003067#line 3068 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003068#include "confdefs.h"
3069
Guido van Rossumf78abae1997-01-21 22:02:36 +00003070int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003071
3072/* Ultrix mips cc rejects this. */
Guido van Rossum627b2d71993-12-24 10:39:16 +00003073typedef int charset[2]; const charset x;
3074/* SunOS 4.1.1 cc rejects this. */
3075char const *const *ccp;
3076char **p;
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003077/* NEC SVR4.0.2 mips cc rejects this. */
3078struct point {int x, y;};
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003079static struct point const zero = {0,0};
Guido van Rossum627b2d71993-12-24 10:39:16 +00003080/* AIX XL C 1.02.0.0 rejects this.
3081 It does not let you subtract one const X* pointer from another in an arm
3082 of an if-expression whose if-part is not a constant expression */
3083const char *g = "string";
3084ccp = &g + (g ? g-g : 0);
3085/* HPUX 7.0 cc rejects these. */
3086++ccp;
3087p = (char**) ccp;
3088ccp = (char const *const *) p;
3089{ /* SCO 3.2v4 cc rejects this. */
3090 char *t;
3091 char const *s = 0 ? (char *) 0 : (char const *) 0;
3092
3093 *t++ = 0;
3094}
3095{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003096 int x[] = {25, 17};
Guido van Rossum627b2d71993-12-24 10:39:16 +00003097 const int *foo = &x[0];
3098 ++foo;
3099}
3100{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
3101 typedef const int *iptr;
3102 iptr p = 0;
3103 ++p;
3104}
3105{ /* AIX XL C 1.02.0.0 rejects this saying
3106 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
3107 struct s { int j; const int *ap[3]; };
3108 struct s *b; b->j = 5;
3109}
3110{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
3111 const int foo = 10;
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003112}
3113
3114; return 0; }
3115EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003116if { (eval echo configure:3117: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003117 rm -rf conftest*
3118 ac_cv_c_const=yes
3119else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003120 echo "configure: failed program was:" >&5
3121 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003122 rm -rf conftest*
3123 ac_cv_c_const=no
3124fi
3125rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003126fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003127
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003128echo "$ac_t""$ac_cv_c_const" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003129if test $ac_cv_c_const = no; then
3130 cat >> confdefs.h <<\EOF
3131#define const
3132EOF
3133
3134fi
3135
3136
Guido van Rossumda88dad1995-01-26 00:46:29 +00003137works=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003138echo $ac_n "checking for working volatile""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003139echo "configure:3140: checking for working volatile" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003140cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003141#line 3142 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003142#include "confdefs.h"
3143
Guido van Rossumf78abae1997-01-21 22:02:36 +00003144int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003145volatile int x; x = 0;
3146; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00003147EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003148if { (eval echo configure:3149: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00003149 rm -rf conftest*
3150 works=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00003151else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003152 echo "configure: failed program was:" >&5
3153 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00003154 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003155 cat >> confdefs.h <<\EOF
3156#define volatile
3157EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00003158
3159fi
3160rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003161echo "$ac_t""$works" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00003162
Guido van Rossumda88dad1995-01-26 00:46:29 +00003163works=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003164echo $ac_n "checking for working signed char""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003165echo "configure:3166: checking for working signed char" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003166cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003167#line 3168 "configure"
Guido van Rossumdabb11b1994-10-11 15:04:27 +00003168#include "confdefs.h"
3169
Guido van Rossumf78abae1997-01-21 22:02:36 +00003170int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003171signed char c;
3172; return 0; }
Guido van Rossumdabb11b1994-10-11 15:04:27 +00003173EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003174if { (eval echo configure:3175: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00003175 rm -rf conftest*
3176 works=yes
Guido van Rossumdabb11b1994-10-11 15:04:27 +00003177else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003178 echo "configure: failed program was:" >&5
3179 cat conftest.$ac_ext >&5
Guido van Rossumdabb11b1994-10-11 15:04:27 +00003180 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003181 cat >> confdefs.h <<\EOF
3182#define signed
Guido van Rossum627b2d71993-12-24 10:39:16 +00003183EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00003184
3185fi
3186rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003187echo "$ac_t""$works" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00003188
Guido van Rossumda88dad1995-01-26 00:46:29 +00003189have_prototypes=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003190echo $ac_n "checking for prototypes""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003191echo "configure:3192: checking for prototypes" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003192cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003193#line 3194 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003194#include "confdefs.h"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003195int foo(int x) { return 0; }
Guido van Rossumf78abae1997-01-21 22:02:36 +00003196int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003197return foo(10);
3198; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00003199EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003200if { (eval echo configure:3201: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003201 rm -rf conftest*
3202 cat >> confdefs.h <<\EOF
3203#define HAVE_PROTOTYPES 1
3204EOF
3205 have_prototypes=yes
Guido van Rossumf78abae1997-01-21 22:02:36 +00003206else
3207 echo "configure: failed program was:" >&5
3208 cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +00003209fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003210rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003211echo "$ac_t""$have_prototypes" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003212
Guido van Rossumda88dad1995-01-26 00:46:29 +00003213works=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003214echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003215echo "configure:3216: checking for variable length prototypes and stdarg.h" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003216cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003217#line 3218 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003218#include "confdefs.h"
3219
3220#include <stdarg.h>
Guido van Rossum90eea071996-08-30 20:58:57 +00003221int foo(int x, ...) {
3222 va_list va;
3223 va_start(va, x);
3224 va_arg(va, int);
3225 va_arg(va, char *);
3226 va_arg(va, double);
3227 return 0;
3228}
Guido van Rossum7f43da71994-08-01 12:15:30 +00003229
Guido van Rossumf78abae1997-01-21 22:02:36 +00003230int main() {
Guido van Rossum90eea071996-08-30 20:58:57 +00003231return foo(10, "", 3.14);
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003232; return 0; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00003233EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003234if { (eval echo configure:3235: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003235 rm -rf conftest*
3236 cat >> confdefs.h <<\EOF
3237#define HAVE_STDARG_PROTOTYPES 1
3238EOF
Guido van Rossumda88dad1995-01-26 00:46:29 +00003239 works=yes
Guido van Rossumf78abae1997-01-21 22:02:36 +00003240else
3241 echo "configure: failed program was:" >&5
3242 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00003243fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003244rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003245echo "$ac_t""$works" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003246
Guido van Rossumda88dad1995-01-26 00:46:29 +00003247if test "$have_prototypes" = yes; then
3248bad_prototypes=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003249echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003250echo "configure:3251: checking for bad exec* prototypes" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003251cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003252#line 3253 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003253#include "confdefs.h"
3254#include <unistd.h>
Guido van Rossumf78abae1997-01-21 22:02:36 +00003255int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003256char **t;execve("@",t,t);
3257; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00003258EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003259if { (eval echo configure:3260: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00003260 :
3261else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003262 echo "configure: failed program was:" >&5
3263 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00003264 rm -rf conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003265 cat >> confdefs.h <<\EOF
3266#define BAD_EXEC_PROTOTYPES 1
3267EOF
Guido van Rossumda88dad1995-01-26 00:46:29 +00003268 bad_prototypes=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00003269fi
3270rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003271echo "$ac_t""$bad_prototypes" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00003272fi
3273
Guido van Rossumda88dad1995-01-26 00:46:29 +00003274bad_forward=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003275echo $ac_n "checking for bad static forward""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003276echo "configure:3277: checking for bad static forward" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003277if test "$cross_compiling" = yes; then
3278 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
3279else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003280 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003281#line 3282 "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003282#include "confdefs.h"
3283
3284struct s { int a; int b; };
3285static struct s foo;
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003286int foobar() {
3287 static int random;
3288 random = (int) &foo;
3289 return random;
3290}
Guido van Rossum7f43da71994-08-01 12:15:30 +00003291static struct s foo = { 1, 2 };
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003292main() {
3293 exit(!((int)&foo == foobar()));
3294}
Guido van Rossum7f43da71994-08-01 12:15:30 +00003295
3296EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003297if { (eval echo configure:3298: \"$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 +00003298then
Guido van Rossum7f43da71994-08-01 12:15:30 +00003299 :
3300else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003301 echo "configure: failed program was:" >&5
3302 cat conftest.$ac_ext >&5
3303 rm -fr conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003304 cat >> confdefs.h <<\EOF
3305#define BAD_STATIC_FORWARD 1
3306EOF
Guido van Rossumda88dad1995-01-26 00:46:29 +00003307 bad_forward=yes
Guido van Rossum7f43da71994-08-01 12:15:30 +00003308fi
3309rm -fr conftest*
Guido van Rossumf78abae1997-01-21 22:02:36 +00003310fi
3311
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003312echo "$ac_t""$bad_forward" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00003313
Guido van Rossumda88dad1995-01-26 00:46:29 +00003314va_list_is_array=no
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003315echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003316echo "configure:3317: checking whether va_list is an array" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003317cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003318#line 3319 "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003319#include "confdefs.h"
3320
3321#ifdef HAVE_STDARG_PROTOTYPES
3322#include <stdarg.h>
3323#else
3324#include <varargs.h>
3325#endif
3326
Guido van Rossumf78abae1997-01-21 22:02:36 +00003327int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003328va_list list1, list2; list1 = list2;
3329; return 0; }
3330EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003331if { (eval echo configure:3332: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003332 :
3333else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003334 echo "configure: failed program was:" >&5
3335 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003336 rm -rf conftest*
3337 cat >> confdefs.h <<\EOF
3338#define VA_LIST_IS_ARRAY 1
3339EOF
Guido van Rossumda88dad1995-01-26 00:46:29 +00003340 va_list_is_array=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003341fi
3342rm -f conftest*
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003343echo "$ac_t""$va_list_is_array" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003344
Guido van Rossum627b2d71993-12-24 10:39:16 +00003345# checks for system services
3346# (none yet)
3347
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003348# Linux requires this for correct f.p. operations
Guido van Rossumf78abae1997-01-21 22:02:36 +00003349echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003350echo "configure:3351: checking for __fpu_control in -lieee" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00003351ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'`
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003352if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003353 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003354else
3355 ac_save_LIBS="$LIBS"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003356LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003357cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003358#line 3359 "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003359#include "confdefs.h"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003360/* Override any gcc2 internal prototype to avoid an error. */
3361/* We use char because int might match the return type of a gcc2
3362 builtin and then its argument prototype would still apply. */
3363char __fpu_control();
Guido van Rossum627b2d71993-12-24 10:39:16 +00003364
Guido van Rossumf78abae1997-01-21 22:02:36 +00003365int main() {
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003366__fpu_control()
3367; return 0; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00003368EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003369if { (eval echo configure:3370: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00003370 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003371 eval "ac_cv_lib_$ac_lib_var=yes"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003372else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003373 echo "configure: failed program was:" >&5
3374 cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +00003375 rm -rf conftest*
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003376 eval "ac_cv_lib_$ac_lib_var=no"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003377fi
3378rm -f conftest*
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003379LIBS="$ac_save_LIBS"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003380
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003381fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003382if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003383 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00003384 ac_tr_lib=HAVE_LIB`echo ieee | sed -e 's/[^a-zA-Z0-9_]/_/g' \
3385 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003386 cat >> confdefs.h <<EOF
3387#define $ac_tr_lib 1
3388EOF
3389
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003390 LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003391
3392else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003393 echo "$ac_t""no" 1>&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00003394fi
3395
3396
Guido van Rossum7f253911997-05-09 02:42:48 +00003397# Check for --with-fpectl
Guido van Rossum7f253911997-05-09 02:42:48 +00003398echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003399echo "configure:3400: checking for --with-fpectl" >&5
Guido van Rossum7f253911997-05-09 02:42:48 +00003400# Check whether --with-fpectl or --without-fpectl was given.
3401if test "${with_fpectl+set}" = set; then
3402 withval="$with_fpectl"
3403
3404if test "$withval" != no
3405then cat >> confdefs.h <<\EOF
3406#define WANT_SIGFPE_HANDLER 1
3407EOF
3408 echo "$ac_t""yes" 1>&6
3409else echo "$ac_t""no" 1>&6
3410fi
3411fi
3412
3413
Guido van Rossum7f43da71994-08-01 12:15:30 +00003414# check for --with-libm=...
3415
Guido van Rossum563e7081996-09-10 18:20:48 +00003416case $ac_sys_system in
3417next) ;;
3418*) LIBM=-lm
3419esac
Guido van Rossum7f253911997-05-09 02:42:48 +00003420echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003421echo "configure:3422: checking for --with-libm=STRING" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003422# Check whether --with-libm or --without-libm was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003423if test "${with_libm+set}" = set; then
3424 withval="$with_libm"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003425
Guido van Rossum7f253911997-05-09 02:42:48 +00003426if test "$withval" = no
3427then LIBM=
3428 echo "$ac_t""force LIBM empty" 1>&6
3429elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +00003430then LIBM=$withval
Guido van Rossum7f253911997-05-09 02:42:48 +00003431 echo "$ac_t""set LIBM=\"$withval\"" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003432else { echo "configure: error: proper usage is --with-libm=STRING" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00003433fi
Guido van Rossum7f253911997-05-09 02:42:48 +00003434else
3435 echo "$ac_t""default LIBM=\"$LIBM\"" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00003436fi
3437
3438
3439# check for --with-libc=...
3440
Guido van Rossum7f253911997-05-09 02:42:48 +00003441echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003442echo "configure:3443: checking for --with-libc=STRING" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003443# Check whether --with-libc or --without-libc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003444if test "${with_libc+set}" = set; then
3445 withval="$with_libc"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003446
Guido van Rossum7f253911997-05-09 02:42:48 +00003447if test "$withval" = no
3448then LIBC=
3449 echo "$ac_t""force LIBC empty" 1>&6
3450elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +00003451then LIBC=$withval
Guido van Rossum7f253911997-05-09 02:42:48 +00003452 echo "$ac_t""set LIBC=\"$withval\"" 1>&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003453else { echo "configure: error: proper usage is --with-libc=STRING" 1>&2; exit 1; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00003454fi
Guido van Rossum7f253911997-05-09 02:42:48 +00003455else
3456 echo "$ac_t""default LIBC=\"$LIBC\"" 1>&6
Guido van Rossum7f43da71994-08-01 12:15:30 +00003457fi
3458
3459
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003460# check for hypot() in math library
3461LIBS_SAVE=$LIBS
3462LIBS="$LIBS $LIBM"
3463for ac_func in hypot
3464do
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003465echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003466echo "configure:3467: checking for $ac_func" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003467if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3468 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003469else
3470 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003471#line 3472 "configure"
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003472#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003473/* System header to define __stub macros and hopefully few prototypes,
3474 which can conflict with char $ac_func(); below. */
3475#include <assert.h>
3476/* Override any gcc2 internal prototype to avoid an error. */
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003477/* We use char because int might match the return type of a gcc2
3478 builtin and then its argument prototype would still apply. */
3479char $ac_func();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003480
Guido van Rossumf78abae1997-01-21 22:02:36 +00003481int main() {
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003482
3483/* The GNU C library defines this for functions which it implements
3484 to always fail with ENOSYS. Some functions are actually named
3485 something starting with __ and the normal name is an alias. */
3486#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3487choke me
3488#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003489$ac_func();
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003490#endif
3491
3492; return 0; }
3493EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003494if { (eval echo configure:3495: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003495 rm -rf conftest*
3496 eval "ac_cv_func_$ac_func=yes"
3497else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003498 echo "configure: failed program was:" >&5
3499 cat conftest.$ac_ext >&5
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003500 rm -rf conftest*
3501 eval "ac_cv_func_$ac_func=no"
3502fi
3503rm -f conftest*
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003504fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00003505
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003506if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003507 echo "$ac_t""yes" 1>&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003508 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003509 cat >> confdefs.h <<EOF
3510#define $ac_tr_func 1
3511EOF
3512
3513else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003514 echo "$ac_t""no" 1>&6
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003515fi
3516done
3517
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003518for ac_func in hypot
3519do
3520echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003521echo "configure:3522: checking for $ac_func" >&5
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003522if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3523 echo $ac_n "(cached) $ac_c" 1>&6
3524else
3525 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003526#line 3527 "configure"
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003527#include "confdefs.h"
3528/* System header to define __stub macros and hopefully few prototypes,
3529 which can conflict with char $ac_func(); below. */
3530#include <assert.h>
3531/* Override any gcc2 internal prototype to avoid an error. */
3532/* We use char because int might match the return type of a gcc2
3533 builtin and then its argument prototype would still apply. */
3534char $ac_func();
3535
Guido van Rossumf78abae1997-01-21 22:02:36 +00003536int main() {
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003537
3538/* The GNU C library defines this for functions which it implements
3539 to always fail with ENOSYS. Some functions are actually named
3540 something starting with __ and the normal name is an alias. */
3541#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3542choke me
3543#else
3544$ac_func();
3545#endif
3546
3547; return 0; }
3548EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003549if { (eval echo configure:3550: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003550 rm -rf conftest*
3551 eval "ac_cv_func_$ac_func=yes"
3552else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003553 echo "configure: failed program was:" >&5
3554 cat conftest.$ac_ext >&5
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003555 rm -rf conftest*
3556 eval "ac_cv_func_$ac_func=no"
3557fi
3558rm -f conftest*
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003559fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00003560
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003561if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3562 echo "$ac_t""yes" 1>&6
Guido van Rossumf78abae1997-01-21 22:02:36 +00003563 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3564 cat >> confdefs.h <<EOF
3565#define $ac_tr_func 1
3566EOF
3567
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003568else
3569 echo "$ac_t""no" 1>&6
3570LIBOBJS="$LIBOBJS ${ac_func}.o"
3571fi
Guido van Rossum2b3ac691996-08-30 15:18:41 +00003572done
3573
Guido van Rossumf78abae1997-01-21 22:02:36 +00003574
Guido van Rossumaf5b83e1995-01-04 19:02:35 +00003575LIBS=$LIBS_SAVE
3576
Guido van Rossumda88dad1995-01-26 00:46:29 +00003577# check for getopt
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003578echo $ac_n "checking for genuine getopt""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003579echo "configure:3580: checking for genuine getopt" >&5
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003580if eval "test \"`echo '$''{'ac_cv_func_getopt'+set}'`\" = set"; then
3581 echo $ac_n "(cached) $ac_c" 1>&6
Guido van Rossumda88dad1995-01-26 00:46:29 +00003582else
3583 if test "$cross_compiling" = yes; then
3584 ac_cv_func_getopt=no
3585else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003586 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003587#line 3588 "configure"
Guido van Rossumda88dad1995-01-26 00:46:29 +00003588#include "confdefs.h"
3589#include <stdio.h>
3590extern int optind, opterr, getopt();
3591extern char* optarg;
3592int main() {
3593 char* av[] = { "testprog", "parameter", "-fFlag", NULL };
3594 opterr = 0;
3595 if (getopt(3, av, "f:") == 'f') { exit(1); }
3596 exit(0);
3597}
3598EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003599if { (eval echo configure:3600: \"$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 +00003600then
Guido van Rossumda88dad1995-01-26 00:46:29 +00003601 ac_cv_func_getopt=yes
3602else
Guido van Rossumf78abae1997-01-21 22:02:36 +00003603 echo "configure: failed program was:" >&5
3604 cat conftest.$ac_ext >&5
3605 rm -fr conftest*
Guido van Rossumda88dad1995-01-26 00:46:29 +00003606 ac_cv_func_getopt=no
3607fi
Guido van Rossumda88dad1995-01-26 00:46:29 +00003608rm -fr conftest*
3609fi
Guido van Rossumf78abae1997-01-21 22:02:36 +00003610
3611fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003612echo "$ac_t""$ac_cv_func_getopt" 1>&6
Guido van Rossumda88dad1995-01-26 00:46:29 +00003613test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o"
3614
Guido van Rossumad713701997-07-10 22:42:38 +00003615# check whether malloc(0) returns NULL or not
Guido van Rossumad713701997-07-10 22:42:38 +00003616echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003617echo "configure:3618: checking what malloc(0) returns" >&5
Guido van Rossumad713701997-07-10 22:42:38 +00003618if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then
3619 echo $ac_n "(cached) $ac_c" 1>&6
3620else
3621 if test "$cross_compiling" = yes; then
3622 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
3623else
3624 cat > conftest.$ac_ext <<EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003625#line 3626 "configure"
Guido van Rossumad713701997-07-10 22:42:38 +00003626#include "confdefs.h"
3627#include <stdio.h>
3628#ifdef HAVE_STDLIB
3629#include <stdlib.h>
3630#else
3631char *malloc(), *realloc();
3632int *free();
3633#endif
3634main() {
3635 char *p;
3636 p = malloc(0);
3637 if (p == NULL) exit(1);
3638 p = realloc(p, 0);
3639 if (p == NULL) exit(1);
3640 free(p);
3641 exit(0);
3642}
3643EOF
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003644if { (eval echo configure:3645: \"$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 +00003645then
3646 ac_cv_malloc_zero=nonnull
3647else
3648 echo "configure: failed program was:" >&5
3649 cat conftest.$ac_ext >&5
3650 rm -fr conftest*
3651 ac_cv_malloc_zero=null
3652fi
3653rm -fr conftest*
3654fi
3655
3656fi
3657
3658echo "$ac_t""$ac_cv_malloc_zero" 1>&6
3659if test "$ac_cv_malloc_zero" = null
3660then
3661 cat >> confdefs.h <<\EOF
3662#define MALLOC_ZERO_RETURNS_NULL 1
3663EOF
3664
3665fi
3666
Guido van Rossum627b2d71993-12-24 10:39:16 +00003667# generate output files
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003668trap '' 1 2 15
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003669cat > confcache <<\EOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003670# This file is a shell script that caches the results of configure
3671# tests run on this system so they can be shared between configure
3672# scripts and configure runs. It is not useful on other systems.
3673# If it contains results you don't want to keep, you may remove or edit it.
3674#
3675# By default, configure uses ./config.cache as the cache file,
3676# creating it if it does not exist already. You can give configure
3677# the --cache-file=FILE option to use a different cache file; that is
3678# what configure does when it calls configure scripts in
3679# subdirectories, so they share the cache.
3680# Giving --cache-file=/dev/null disables caching, for debugging configure.
3681# config.status only pays attention to the cache file if you give it the
3682# --recheck option to rerun configure.
3683#
3684EOF
Guido van Rossumf78abae1997-01-21 22:02:36 +00003685# The following way of writing the cache mishandles newlines in values,
3686# but we know of no workaround that is simple, portable, and efficient.
3687# So, don't put newlines in cache variables' values.
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003688# Ultrix sh set writes to stderr and can't be redirected directly,
3689# and sets the high bit in the cache file unless we assign to the vars.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003690(set) 2>&1 |
Guido van Rossumf78abae1997-01-21 22:02:36 +00003691 case `(ac_space=' '; set) 2>&1` in
3692 *ac_space=\ *)
3693 # `set' does not quote correctly, so add quotes (double-quote substitution
3694 # turns \\\\ into \\, and sed turns \\ into \).
3695 sed -n \
3696 -e "s/'/'\\\\''/g" \
3697 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
3698 ;;
3699 *)
3700 # `set' quotes correctly as required by POSIX, so do not add quotes.
3701 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
3702 ;;
3703 esac >> confcache
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003704if cmp -s $cache_file confcache; then
3705 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003706else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003707 if test -w $cache_file; then
3708 echo "updating cache $cache_file"
3709 cat confcache > $cache_file
3710 else
3711 echo "not updating unwritable cache $cache_file"
3712 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003713fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003714rm -f confcache
Guido van Rossum0a516c91994-09-12 10:58:40 +00003715
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003716trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003717
3718test "x$prefix" = xNONE && prefix=$ac_default_prefix
3719# Let make expand exec_prefix.
3720test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
Guido van Rossum0a516c91994-09-12 10:58:40 +00003721
Guido van Rossum7f43da71994-08-01 12:15:30 +00003722# Any assignment to VPATH causes Sun make to only execute
3723# the first set of double-colon rules, so remove it if not needed.
3724# If there is a colon in the path, we need to keep it.
3725if test "x$srcdir" = x.; then
3726 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
3727fi
3728
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003729trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
Guido van Rossum627b2d71993-12-24 10:39:16 +00003730
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003731DEFS=-DHAVE_CONFIG_H
3732
3733# Without the "./", some shells look in PATH for config.status.
3734: ${CONFIG_STATUS=./config.status}
3735
3736echo creating $CONFIG_STATUS
3737rm -f $CONFIG_STATUS
3738cat > $CONFIG_STATUS <<EOF
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003739#! /bin/sh
Guido van Rossum627b2d71993-12-24 10:39:16 +00003740# Generated automatically by configure.
3741# Run this file to recreate the current configuration.
3742# This directory was configured as follows,
3743# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3744#
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003745# $0 $ac_configure_args
3746#
3747# Compiler output produced by configure, useful for debugging
3748# configure, is in ./config.log if it exists.
Guido van Rossum627b2d71993-12-24 10:39:16 +00003749
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003750ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003751for ac_option
Guido van Rossum627b2d71993-12-24 10:39:16 +00003752do
Guido van Rossum7f43da71994-08-01 12:15:30 +00003753 case "\$ac_option" in
3754 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003755 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
3756 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00003757 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
Guido van Rossumf78abae1997-01-21 22:02:36 +00003758 echo "$CONFIG_STATUS generated by autoconf version 2.12"
Guido van Rossum7f43da71994-08-01 12:15:30 +00003759 exit 0 ;;
3760 -help | --help | --hel | --he | --h)
3761 echo "\$ac_cs_usage"; exit 0 ;;
3762 *) echo "\$ac_cs_usage"; exit 1 ;;
Guido van Rossum627b2d71993-12-24 10:39:16 +00003763 esac
3764done
3765
Guido van Rossum7f43da71994-08-01 12:15:30 +00003766ac_given_srcdir=$srcdir
Guido van Rossum627b2d71993-12-24 10:39:16 +00003767
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003768trap 'rm -fr `echo "Makefile \
3769 Objects/Makefile \
3770 Parser/Makefile \
3771 Python/Makefile \
3772 Modules/Makefile.pre config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003773EOF
3774cat >> $CONFIG_STATUS <<EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00003775
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003776# Protect against being on the right side of a sed subst in config.status.
3777sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
3778 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00003779$ac_vpsub
Guido van Rossum627b2d71993-12-24 10:39:16 +00003780$extrasub
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003781s%@CFLAGS@%$CFLAGS%g
3782s%@CPPFLAGS@%$CPPFLAGS%g
3783s%@CXXFLAGS@%$CXXFLAGS%g
3784s%@DEFS@%$DEFS%g
3785s%@LDFLAGS@%$LDFLAGS%g
3786s%@LIBS@%$LIBS%g
3787s%@exec_prefix@%$exec_prefix%g
3788s%@prefix@%$prefix%g
3789s%@program_transform_name@%$program_transform_name%g
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003790s%@bindir@%$bindir%g
3791s%@sbindir@%$sbindir%g
3792s%@libexecdir@%$libexecdir%g
3793s%@datadir@%$datadir%g
3794s%@sysconfdir@%$sysconfdir%g
3795s%@sharedstatedir@%$sharedstatedir%g
3796s%@localstatedir@%$localstatedir%g
3797s%@libdir@%$libdir%g
3798s%@includedir@%$includedir%g
3799s%@oldincludedir@%$oldincludedir%g
3800s%@infodir@%$infodir%g
3801s%@mandir@%$mandir%g
Guido van Rossum1fd74a71997-07-19 19:36:02 +00003802s%@VERSION@%$VERSION%g
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003803s%@MACHDEP@%$MACHDEP%g
Guido van Rossum627b2d71993-12-24 10:39:16 +00003804s%@CC@%$CC%g
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003805s%@LINKCC@%$LINKCC%g
Guido van Rossum627b2d71993-12-24 10:39:16 +00003806s%@RANLIB@%$RANLIB%g
Guido van Rossum7f43da71994-08-01 12:15:30 +00003807s%@AR@%$AR%g
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003808s%@INSTALL@%$INSTALL%g
Guido van Rossumda88dad1995-01-26 00:46:29 +00003809s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
3810s%@INSTALL_DATA@%$INSTALL_DATA%g
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003811s%@OPT@%$OPT%g
Guido van Rossum627b2d71993-12-24 10:39:16 +00003812s%@CPP@%$CPP%g
Guido van Rossum0a516c91994-09-12 10:58:40 +00003813s%@SO@%$SO%g
3814s%@LDSHARED@%$LDSHARED%g
3815s%@CCSHARED@%$CCSHARED%g
3816s%@LINKFORSHARED@%$LINKFORSHARED%g
Guido van Rossumec2f0731997-01-22 20:54:01 +00003817s%@LDLAST@%$LDLAST%g
Guido van Rossum7f43da71994-08-01 12:15:30 +00003818s%@DLINCLDIR@%$DLINCLDIR%g
Guido van Rossum627b2d71993-12-24 10:39:16 +00003819s%@LIBOBJS@%$LIBOBJS%g
Guido van Rossum7f43da71994-08-01 12:15:30 +00003820s%@LIBM@%$LIBM%g
3821s%@LIBC@%$LIBC%g
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003822
3823CEOF
3824EOF
Guido van Rossumf78abae1997-01-21 22:02:36 +00003825
3826cat >> $CONFIG_STATUS <<\EOF
3827
3828# Split the substitutions into bite-sized pieces for seds with
3829# small command number limits, like on Digital OSF/1 and HP-UX.
3830ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
3831ac_file=1 # Number of current file.
3832ac_beg=1 # First line for current file.
3833ac_end=$ac_max_sed_cmds # Line after last line for current file.
3834ac_more_lines=:
3835ac_sed_cmds=""
3836while $ac_more_lines; do
3837 if test $ac_beg -gt 1; then
3838 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
3839 else
3840 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
3841 fi
3842 if test ! -s conftest.s$ac_file; then
3843 ac_more_lines=false
3844 rm -f conftest.s$ac_file
3845 else
3846 if test -z "$ac_sed_cmds"; then
3847 ac_sed_cmds="sed -f conftest.s$ac_file"
3848 else
3849 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
3850 fi
3851 ac_file=`expr $ac_file + 1`
3852 ac_beg=$ac_end
3853 ac_end=`expr $ac_end + $ac_max_sed_cmds`
3854 fi
3855done
3856if test -z "$ac_sed_cmds"; then
3857 ac_sed_cmds=cat
3858fi
3859EOF
3860
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003861cat >> $CONFIG_STATUS <<EOF
3862
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003863CONFIG_FILES=\${CONFIG_FILES-"Makefile \
3864 Objects/Makefile \
3865 Parser/Makefile \
3866 Python/Makefile \
3867 Modules/Makefile.pre"}
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003868EOF
3869cat >> $CONFIG_STATUS <<\EOF
3870for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00003871 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003872 case "$ac_file" in
Guido van Rossumf78abae1997-01-21 22:02:36 +00003873 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003874 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3875 *) ac_file_in="${ac_file}.in" ;;
3876 esac
3877
Guido van Rossumf78abae1997-01-21 22:02:36 +00003878 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003879
3880 # Remove last slash and all that follows it. Not all systems have dirname.
3881 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3882 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3883 # The file is in a subdirectory.
3884 test ! -d "$ac_dir" && mkdir "$ac_dir"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003885 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003886 # A "../" for each directory in $ac_dir_suffix.
3887 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
3888 else
3889 ac_dir_suffix= ac_dots=
3890 fi
3891
3892 case "$ac_given_srcdir" in
3893 .) srcdir=.
3894 if test -z "$ac_dots"; then top_srcdir=.
3895 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
3896 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
3897 *) # Relative path.
3898 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
3899 top_srcdir="$ac_dots$ac_given_srcdir" ;;
3900 esac
3901
Guido van Rossumf78abae1997-01-21 22:02:36 +00003902
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003903 echo creating "$ac_file"
3904 rm -f "$ac_file"
3905 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
3906 case "$ac_file" in
3907 *Makefile*) ac_comsub="1i\\
3908# $configure_input" ;;
3909 *) ac_comsub= ;;
3910 esac
Guido van Rossumf78abae1997-01-21 22:02:36 +00003911
3912 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 +00003913 sed -e "$ac_comsub
3914s%@configure_input@%$configure_input%g
Guido van Rossum627b2d71993-12-24 10:39:16 +00003915s%@srcdir@%$srcdir%g
Guido van Rossum7f43da71994-08-01 12:15:30 +00003916s%@top_srcdir@%$top_srcdir%g
Guido van Rossumf78abae1997-01-21 22:02:36 +00003917" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
Guido van Rossum627b2d71993-12-24 10:39:16 +00003918fi; done
Guido van Rossumf78abae1997-01-21 22:02:36 +00003919rm -f conftest.s*
Guido van Rossum627b2d71993-12-24 10:39:16 +00003920
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003921# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
3922# NAME is the cpp macro being defined and VALUE is the value it is being given.
Guido van Rossum7f43da71994-08-01 12:15:30 +00003923#
3924# ac_d sets the value in "#define NAME VALUE" lines.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003925ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
3926ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
Guido van Rossum7f43da71994-08-01 12:15:30 +00003927ac_dC='\3'
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003928ac_dD='%g'
Guido van Rossum7f43da71994-08-01 12:15:30 +00003929# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003930ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
3931ac_uB='\([ ]\)%\1#\2define\3'
Guido van Rossum7f43da71994-08-01 12:15:30 +00003932ac_uC=' '
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003933ac_uD='\4%g'
Guido van Rossum7f43da71994-08-01 12:15:30 +00003934# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003935ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
3936ac_eB='$%\1#\2define\3'
Guido van Rossum7f43da71994-08-01 12:15:30 +00003937ac_eC=' '
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003938ac_eD='%g'
Guido van Rossum7f43da71994-08-01 12:15:30 +00003939
Guido van Rossumf78abae1997-01-21 22:02:36 +00003940if test "${CONFIG_HEADERS+set}" != set; then
3941EOF
3942cat >> $CONFIG_STATUS <<EOF
3943 CONFIG_HEADERS="config.h"
3944EOF
3945cat >> $CONFIG_STATUS <<\EOF
3946fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003947for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00003948 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003949 case "$ac_file" in
Guido van Rossumf78abae1997-01-21 22:02:36 +00003950 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003951 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3952 *) ac_file_in="${ac_file}.in" ;;
3953 esac
3954
Guido van Rossum7f43da71994-08-01 12:15:30 +00003955 echo creating $ac_file
3956
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003957 rm -f conftest.frag conftest.in conftest.out
Guido van Rossumf78abae1997-01-21 22:02:36 +00003958 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3959 cat $ac_file_inputs > conftest.in
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003960
3961EOF
3962
3963# Transform confdefs.h into a sed script conftest.vals that substitutes
3964# the proper values into config.h.in to produce config.h. And first:
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003965# Protect against being on the right side of a sed subst in config.status.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003966# Protect against being in an unquoted here document in config.status.
3967rm -f conftest.vals
3968cat > conftest.hdr <<\EOF
3969s/[\\&%]/\\&/g
3970s%[\\$`]%\\&%g
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003971s%#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 +00003972s%ac_d%ac_u%gp
3973s%ac_u%ac_e%gp
3974EOF
3975sed -n -f conftest.hdr confdefs.h > conftest.vals
3976rm -f conftest.hdr
3977
3978# This sed command replaces #undef with comments. This is necessary, for
3979# example, in the case of _POSIX_SOURCE, which is predefined and required
3980# on some systems where configure will not decide to define it.
3981cat >> conftest.vals <<\EOF
3982s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
3983EOF
3984
3985# Break up conftest.vals because some shells have a limit on
3986# the size of here documents, and old seds have small limits too.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003987
3988rm -f conftest.tail
3989while :
3990do
3991 ac_lines=`grep -c . conftest.vals`
3992 # grep -c gives empty output for an empty file on some AIX systems.
3993 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
3994 # Write a limited-size here document to conftest.frag.
3995 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
3996 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
3997 echo 'CEOF
3998 sed -f conftest.frag conftest.in > conftest.out
3999 rm -f conftest.in
4000 mv conftest.out conftest.in
4001' >> $CONFIG_STATUS
4002 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
4003 rm -f conftest.vals
4004 mv conftest.tail conftest.vals
4005done
4006rm -f conftest.vals
4007
4008cat >> $CONFIG_STATUS <<\EOF
4009 rm -f conftest.frag conftest.h
Guido van Rossum7f43da71994-08-01 12:15:30 +00004010 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004011 cat conftest.in >> conftest.h
4012 rm -f conftest.in
Guido van Rossum7f43da71994-08-01 12:15:30 +00004013 if cmp -s $ac_file conftest.h 2>/dev/null; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00004014 echo "$ac_file is unchanged"
4015 rm -f conftest.h
4016 else
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004017 # Remove last slash and all that follows it. Not all systems have dirname.
4018 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4019 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4020 # The file is in a subdirectory.
4021 test ! -d "$ac_dir" && mkdir "$ac_dir"
4022 fi
Guido van Rossum7f43da71994-08-01 12:15:30 +00004023 rm -f $ac_file
4024 mv conftest.h $ac_file
4025 fi
4026fi; done
4027
Guido van Rossumf78abae1997-01-21 22:02:36 +00004028EOF
4029cat >> $CONFIG_STATUS <<EOF
Guido van Rossum7f43da71994-08-01 12:15:30 +00004030
Guido van Rossumf78abae1997-01-21 22:02:36 +00004031EOF
4032cat >> $CONFIG_STATUS <<\EOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00004033
4034exit 0
4035EOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004036chmod +x $CONFIG_STATUS
4037rm -fr confdefs* $ac_clean_files
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00004038test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
Guido van Rossum627b2d71993-12-24 10:39:16 +00004039