* configure.in: Added thread support for the alpha architecture.
[bpt/guile.git] / configure
1 #! /bin/sh
2
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.12
5 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6 #
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
9
10 # Defaults:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_help="$ac_help
15 --enable-maintainer-mode enable make rules and dependencies not useful
16 (and sometimes confusing) to the casual installer"
17 ac_help="$ac_help
18 --disable-debug Don't include debugging support"
19 ac_help="$ac_help
20 --enable-dynamic-linking Include support for dynamic linking"
21 ac_help="$ac_help
22 --enable-guile-debug Include internal debugging functions"
23 ac_help="$ac_help
24 --with-gnu-ld assume the C compiler uses GNU ld [default=no]"
25 ac_help="$ac_help
26 --enable-shared build shared libraries [default=yes]"
27 ac_help="$ac_help
28 --enable-static build static libraries [default=yes]"
29
30 # Initialize some variables set by options.
31 # The variables have the same names as the options, with
32 # dashes changed to underlines.
33 build=NONE
34 cache_file=./config.cache
35 exec_prefix=NONE
36 host=NONE
37 no_create=
38 nonopt=NONE
39 no_recursion=
40 prefix=NONE
41 program_prefix=NONE
42 program_suffix=NONE
43 program_transform_name=s,x,x,
44 silent=
45 site=
46 srcdir=
47 target=NONE
48 verbose=
49 x_includes=NONE
50 x_libraries=NONE
51 bindir='${exec_prefix}/bin'
52 sbindir='${exec_prefix}/sbin'
53 libexecdir='${exec_prefix}/libexec'
54 datadir='${prefix}/share'
55 sysconfdir='${prefix}/etc'
56 sharedstatedir='${prefix}/com'
57 localstatedir='${prefix}/var'
58 libdir='${exec_prefix}/lib'
59 includedir='${prefix}/include'
60 oldincludedir='/usr/include'
61 infodir='${prefix}/info'
62 mandir='${prefix}/man'
63
64 # Initialize some other variables.
65 subdirs=
66 MFLAGS= MAKEFLAGS=
67 # Maximum number of lines to put in a shell here document.
68 ac_max_here_lines=12
69
70 ac_prev=
71 for ac_option
72 do
73
74 # If the previous option needs an argument, assign it.
75 if test -n "$ac_prev"; then
76 eval "$ac_prev=\$ac_option"
77 ac_prev=
78 continue
79 fi
80
81 case "$ac_option" in
82 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
83 *) ac_optarg= ;;
84 esac
85
86 # Accept the important Cygnus configure options, so we can diagnose typos.
87
88 case "$ac_option" in
89
90 -bindir | --bindir | --bindi | --bind | --bin | --bi)
91 ac_prev=bindir ;;
92 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
93 bindir="$ac_optarg" ;;
94
95 -build | --build | --buil | --bui | --bu)
96 ac_prev=build ;;
97 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
98 build="$ac_optarg" ;;
99
100 -cache-file | --cache-file | --cache-fil | --cache-fi \
101 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
102 ac_prev=cache_file ;;
103 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
104 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
105 cache_file="$ac_optarg" ;;
106
107 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
108 ac_prev=datadir ;;
109 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
110 | --da=*)
111 datadir="$ac_optarg" ;;
112
113 -disable-* | --disable-*)
114 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
115 # Reject names that are not valid shell variable names.
116 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
117 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
118 fi
119 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
120 eval "enable_${ac_feature}=no" ;;
121
122 -enable-* | --enable-*)
123 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
124 # Reject names that are not valid shell variable names.
125 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
126 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
127 fi
128 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
129 case "$ac_option" in
130 *=*) ;;
131 *) ac_optarg=yes ;;
132 esac
133 eval "enable_${ac_feature}='$ac_optarg'" ;;
134
135 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
136 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
137 | --exec | --exe | --ex)
138 ac_prev=exec_prefix ;;
139 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
140 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
141 | --exec=* | --exe=* | --ex=*)
142 exec_prefix="$ac_optarg" ;;
143
144 -gas | --gas | --ga | --g)
145 # Obsolete; use --with-gas.
146 with_gas=yes ;;
147
148 -help | --help | --hel | --he)
149 # Omit some internal or obsolete options to make the list less imposing.
150 # This message is too long to be a string in the A/UX 3.1 sh.
151 cat << EOF
152 Usage: configure [options] [host]
153 Options: [defaults in brackets after descriptions]
154 Configuration:
155 --cache-file=FILE cache test results in FILE
156 --help print this message
157 --no-create do not create output files
158 --quiet, --silent do not print \`checking...' messages
159 --version print the version of autoconf that created configure
160 Directory and file names:
161 --prefix=PREFIX install architecture-independent files in PREFIX
162 [$ac_default_prefix]
163 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
164 [same as prefix]
165 --bindir=DIR user executables in DIR [EPREFIX/bin]
166 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
167 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
168 --datadir=DIR read-only architecture-independent data in DIR
169 [PREFIX/share]
170 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
171 --sharedstatedir=DIR modifiable architecture-independent data in DIR
172 [PREFIX/com]
173 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
174 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
175 --includedir=DIR C header files in DIR [PREFIX/include]
176 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
177 --infodir=DIR info documentation in DIR [PREFIX/info]
178 --mandir=DIR man documentation in DIR [PREFIX/man]
179 --srcdir=DIR find the sources in DIR [configure dir or ..]
180 --program-prefix=PREFIX prepend PREFIX to installed program names
181 --program-suffix=SUFFIX append SUFFIX to installed program names
182 --program-transform-name=PROGRAM
183 run sed PROGRAM on installed program names
184 EOF
185 cat << EOF
186 Host type:
187 --build=BUILD configure for building on BUILD [BUILD=HOST]
188 --host=HOST configure for HOST [guessed]
189 --target=TARGET configure for TARGET [TARGET=HOST]
190 Features and packages:
191 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
192 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
193 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
194 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
195 --x-includes=DIR X include files are in DIR
196 --x-libraries=DIR X library files are in DIR
197 EOF
198 if test -n "$ac_help"; then
199 echo "--enable and --with options recognized:$ac_help"
200 fi
201 exit 0 ;;
202
203 -host | --host | --hos | --ho)
204 ac_prev=host ;;
205 -host=* | --host=* | --hos=* | --ho=*)
206 host="$ac_optarg" ;;
207
208 -includedir | --includedir | --includedi | --included | --include \
209 | --includ | --inclu | --incl | --inc)
210 ac_prev=includedir ;;
211 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
212 | --includ=* | --inclu=* | --incl=* | --inc=*)
213 includedir="$ac_optarg" ;;
214
215 -infodir | --infodir | --infodi | --infod | --info | --inf)
216 ac_prev=infodir ;;
217 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
218 infodir="$ac_optarg" ;;
219
220 -libdir | --libdir | --libdi | --libd)
221 ac_prev=libdir ;;
222 -libdir=* | --libdir=* | --libdi=* | --libd=*)
223 libdir="$ac_optarg" ;;
224
225 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
226 | --libexe | --libex | --libe)
227 ac_prev=libexecdir ;;
228 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
229 | --libexe=* | --libex=* | --libe=*)
230 libexecdir="$ac_optarg" ;;
231
232 -localstatedir | --localstatedir | --localstatedi | --localstated \
233 | --localstate | --localstat | --localsta | --localst \
234 | --locals | --local | --loca | --loc | --lo)
235 ac_prev=localstatedir ;;
236 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
237 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
238 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
239 localstatedir="$ac_optarg" ;;
240
241 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
242 ac_prev=mandir ;;
243 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
244 mandir="$ac_optarg" ;;
245
246 -nfp | --nfp | --nf)
247 # Obsolete; use --without-fp.
248 with_fp=no ;;
249
250 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
251 | --no-cr | --no-c)
252 no_create=yes ;;
253
254 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
255 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
256 no_recursion=yes ;;
257
258 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
259 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
260 | --oldin | --oldi | --old | --ol | --o)
261 ac_prev=oldincludedir ;;
262 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
263 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
264 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
265 oldincludedir="$ac_optarg" ;;
266
267 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
268 ac_prev=prefix ;;
269 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
270 prefix="$ac_optarg" ;;
271
272 -program-prefix | --program-prefix | --program-prefi | --program-pref \
273 | --program-pre | --program-pr | --program-p)
274 ac_prev=program_prefix ;;
275 -program-prefix=* | --program-prefix=* | --program-prefi=* \
276 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
277 program_prefix="$ac_optarg" ;;
278
279 -program-suffix | --program-suffix | --program-suffi | --program-suff \
280 | --program-suf | --program-su | --program-s)
281 ac_prev=program_suffix ;;
282 -program-suffix=* | --program-suffix=* | --program-suffi=* \
283 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
284 program_suffix="$ac_optarg" ;;
285
286 -program-transform-name | --program-transform-name \
287 | --program-transform-nam | --program-transform-na \
288 | --program-transform-n | --program-transform- \
289 | --program-transform | --program-transfor \
290 | --program-transfo | --program-transf \
291 | --program-trans | --program-tran \
292 | --progr-tra | --program-tr | --program-t)
293 ac_prev=program_transform_name ;;
294 -program-transform-name=* | --program-transform-name=* \
295 | --program-transform-nam=* | --program-transform-na=* \
296 | --program-transform-n=* | --program-transform-=* \
297 | --program-transform=* | --program-transfor=* \
298 | --program-transfo=* | --program-transf=* \
299 | --program-trans=* | --program-tran=* \
300 | --progr-tra=* | --program-tr=* | --program-t=*)
301 program_transform_name="$ac_optarg" ;;
302
303 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
304 | -silent | --silent | --silen | --sile | --sil)
305 silent=yes ;;
306
307 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
308 ac_prev=sbindir ;;
309 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
310 | --sbi=* | --sb=*)
311 sbindir="$ac_optarg" ;;
312
313 -sharedstatedir | --sharedstatedir | --sharedstatedi \
314 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
315 | --sharedst | --shareds | --shared | --share | --shar \
316 | --sha | --sh)
317 ac_prev=sharedstatedir ;;
318 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
319 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
320 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
321 | --sha=* | --sh=*)
322 sharedstatedir="$ac_optarg" ;;
323
324 -site | --site | --sit)
325 ac_prev=site ;;
326 -site=* | --site=* | --sit=*)
327 site="$ac_optarg" ;;
328
329 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
330 ac_prev=srcdir ;;
331 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
332 srcdir="$ac_optarg" ;;
333
334 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
335 | --syscon | --sysco | --sysc | --sys | --sy)
336 ac_prev=sysconfdir ;;
337 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
338 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
339 sysconfdir="$ac_optarg" ;;
340
341 -target | --target | --targe | --targ | --tar | --ta | --t)
342 ac_prev=target ;;
343 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
344 target="$ac_optarg" ;;
345
346 -v | -verbose | --verbose | --verbos | --verbo | --verb)
347 verbose=yes ;;
348
349 -version | --version | --versio | --versi | --vers)
350 echo "configure generated by autoconf version 2.12"
351 exit 0 ;;
352
353 -with-* | --with-*)
354 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
355 # Reject names that are not valid shell variable names.
356 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
357 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
358 fi
359 ac_package=`echo $ac_package| sed 's/-/_/g'`
360 case "$ac_option" in
361 *=*) ;;
362 *) ac_optarg=yes ;;
363 esac
364 eval "with_${ac_package}='$ac_optarg'" ;;
365
366 -without-* | --without-*)
367 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
368 # Reject names that are not valid shell variable names.
369 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
370 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
371 fi
372 ac_package=`echo $ac_package| sed 's/-/_/g'`
373 eval "with_${ac_package}=no" ;;
374
375 --x)
376 # Obsolete; use --with-x.
377 with_x=yes ;;
378
379 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
380 | --x-incl | --x-inc | --x-in | --x-i)
381 ac_prev=x_includes ;;
382 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
383 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
384 x_includes="$ac_optarg" ;;
385
386 -x-libraries | --x-libraries | --x-librarie | --x-librari \
387 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
388 ac_prev=x_libraries ;;
389 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
390 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
391 x_libraries="$ac_optarg" ;;
392
393 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
394 ;;
395
396 *)
397 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
398 echo "configure: warning: $ac_option: invalid host type" 1>&2
399 fi
400 if test "x$nonopt" != xNONE; then
401 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
402 fi
403 nonopt="$ac_option"
404 ;;
405
406 esac
407 done
408
409 if test -n "$ac_prev"; then
410 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
411 fi
412
413 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
414
415 # File descriptor usage:
416 # 0 standard input
417 # 1 file creation
418 # 2 errors and warnings
419 # 3 some systems may open it to /dev/tty
420 # 4 used on the Kubota Titan
421 # 6 checking for... messages and results
422 # 5 compiler messages saved in config.log
423 if test "$silent" = yes; then
424 exec 6>/dev/null
425 else
426 exec 6>&1
427 fi
428 exec 5>./config.log
429
430 echo "\
431 This file contains any messages produced by compilers while
432 running configure, to aid debugging if configure makes a mistake.
433 " 1>&5
434
435 # Strip out --no-create and --no-recursion so they do not pile up.
436 # Also quote any args containing shell metacharacters.
437 ac_configure_args=
438 for ac_arg
439 do
440 case "$ac_arg" in
441 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
442 | --no-cr | --no-c) ;;
443 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
444 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
445 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
446 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
447 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
448 esac
449 done
450
451 # NLS nuisances.
452 # Only set these to C if already set. These must not be set unconditionally
453 # because not all systems understand e.g. LANG=C (notably SCO).
454 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
455 # Non-C LC_CTYPE values break the ctype check.
456 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
457 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
458 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
459 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
460
461 # confdefs.h avoids OS command line length limits that DEFS can exceed.
462 rm -rf conftest* confdefs.h
463 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
464 echo > confdefs.h
465
466 # A filename unique to this package, relative to the directory that
467 # configure is in, which we can look for to find out if srcdir is correct.
468 ac_unique_file=Makefile.in
469
470 # Find the source files, if location was not specified.
471 if test -z "$srcdir"; then
472 ac_srcdir_defaulted=yes
473 # Try the directory containing this script, then its parent.
474 ac_prog=$0
475 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
476 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
477 srcdir=$ac_confdir
478 if test ! -r $srcdir/$ac_unique_file; then
479 srcdir=..
480 fi
481 else
482 ac_srcdir_defaulted=no
483 fi
484 if test ! -r $srcdir/$ac_unique_file; then
485 if test "$ac_srcdir_defaulted" = yes; then
486 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
487 else
488 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
489 fi
490 fi
491 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
492
493 # Prefer explicitly selected file to automatically selected ones.
494 if test -z "$CONFIG_SITE"; then
495 if test "x$prefix" != xNONE; then
496 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
497 else
498 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
499 fi
500 fi
501 for ac_site_file in $CONFIG_SITE; do
502 if test -r "$ac_site_file"; then
503 echo "loading site script $ac_site_file"
504 . "$ac_site_file"
505 fi
506 done
507
508 if test -r "$cache_file"; then
509 echo "loading cache $cache_file"
510 . $cache_file
511 else
512 echo "creating cache $cache_file"
513 > $cache_file
514 fi
515
516 ac_ext=c
517 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
518 ac_cpp='$CPP $CPPFLAGS'
519 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
520 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
521 cross_compiling=$ac_cv_prog_cc_cross
522
523 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
524 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
525 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
526 ac_n= ac_c='
527 ' ac_t=' '
528 else
529 ac_n=-n ac_c= ac_t=
530 fi
531 else
532 ac_n= ac_c='\c' ac_t=
533 fi
534
535
536 . $srcdir/GUILE-VERSION
537 ac_aux_dir=
538 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
539 if test -f $ac_dir/install-sh; then
540 ac_aux_dir=$ac_dir
541 ac_install_sh="$ac_aux_dir/install-sh -c"
542 break
543 elif test -f $ac_dir/install.sh; then
544 ac_aux_dir=$ac_dir
545 ac_install_sh="$ac_aux_dir/install.sh -c"
546 break
547 fi
548 done
549 if test -z "$ac_aux_dir"; then
550 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
551 fi
552 ac_config_guess=$ac_aux_dir/config.guess
553 ac_config_sub=$ac_aux_dir/config.sub
554 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
555
556 # Find a good install program. We prefer a C program (faster),
557 # so one script is as good as another. But avoid the broken or
558 # incompatible versions:
559 # SysV /etc/install, /usr/sbin/install
560 # SunOS /usr/etc/install
561 # IRIX /sbin/install
562 # AIX /bin/install
563 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
564 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
565 # ./install, which can be erroneously created by make from ./install.sh.
566 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
567 echo "configure:568: checking for a BSD compatible install" >&5
568 if test -z "$INSTALL"; then
569 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
570 echo $ac_n "(cached) $ac_c" 1>&6
571 else
572 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
573 for ac_dir in $PATH; do
574 # Account for people who put trailing slashes in PATH elements.
575 case "$ac_dir/" in
576 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
577 *)
578 # OSF1 and SCO ODT 3.0 have their own names for install.
579 for ac_prog in ginstall installbsd scoinst install; do
580 if test -f $ac_dir/$ac_prog; then
581 if test $ac_prog = install &&
582 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
583 # AIX install. It has an incompatible calling convention.
584 # OSF/1 installbsd also uses dspmsg, but is usable.
585 :
586 else
587 ac_cv_path_install="$ac_dir/$ac_prog -c"
588 break 2
589 fi
590 fi
591 done
592 ;;
593 esac
594 done
595 IFS="$ac_save_IFS"
596
597 fi
598 if test "${ac_cv_path_install+set}" = set; then
599 INSTALL="$ac_cv_path_install"
600 else
601 # As a last resort, use the slow shell script. We don't cache a
602 # path for INSTALL within a source directory, because that will
603 # break other packages using the cache if that directory is
604 # removed, or if the path is relative.
605 INSTALL="$ac_install_sh"
606 fi
607 fi
608 echo "$ac_t""$INSTALL" 1>&6
609
610 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
611 # It thinks the first close brace ends the variable substitution.
612 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
613
614 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
615
616
617 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
618
619
620 PACKAGE=$PACKAGE
621
622 VERSION=$VERSION
623
624 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
625 { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
626 fi
627
628 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
629 echo "configure:630: checking whether build environment is sane" >&5
630 # Just in case
631 sleep 1
632 echo timestamp > conftestfile
633 # Do `set' in a subshell so we don't clobber the current shell's
634 # arguments. Must try -L first in case configure is actually a
635 # symlink; some systems play weird games with the mod time of symlinks
636 # (eg FreeBSD returns the mod time of the symlink's containing
637 # directory).
638 if (
639 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
640 if test "" = "X"; then
641 # -L didn't work.
642 set X `ls -t $srcdir/configure conftestfile`
643 fi
644 test "$2" = conftestfile
645 )
646 then
647 # Ok.
648 :
649 else
650 { echo "configure: error: newly created file is older than distributed files!
651 Check your system clock" 1>&2; exit 1; }
652 fi
653 rm -f conftest*
654 echo "$ac_t""yes" 1>&6
655 if test "$program_transform_name" = s,x,x,; then
656 program_transform_name=
657 else
658 # Double any \ or $. echo might interpret backslashes.
659 cat <<\EOF_SED > conftestsed
660 s,\\,\\\\,g; s,\$,$$,g
661 EOF_SED
662 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
663 rm -f conftestsed
664 fi
665 test "$program_prefix" != NONE &&
666 program_transform_name="s,^,${program_prefix},; $program_transform_name"
667 # Use a double $ so make ignores it.
668 test "$program_suffix" != NONE &&
669 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
670
671 # sed with no file args requires a program.
672 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
673
674 missing_dir=`cd $ac_aux_dir && pwd`
675 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
676 echo "configure:677: checking for working aclocal" >&5
677 # Run test in a subshell; some versions of sh will print an error if
678 # an executable is not found, even if stderr is redirected.
679 # Redirect stdin to placate older versions of autoconf. Sigh.
680 if (aclocal --version) < /dev/null > /dev/null 2>&1; then
681 ACLOCAL=aclocal
682 echo "$ac_t""found" 1>&6
683 else
684 ACLOCAL="$missing_dir/missing aclocal"
685 echo "$ac_t""missing" 1>&6
686 fi
687
688 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
689 echo "configure:690: checking for working autoconf" >&5
690 # Run test in a subshell; some versions of sh will print an error if
691 # an executable is not found, even if stderr is redirected.
692 # Redirect stdin to placate older versions of autoconf. Sigh.
693 if (autoconf --version) < /dev/null > /dev/null 2>&1; then
694 AUTOCONF=autoconf
695 echo "$ac_t""found" 1>&6
696 else
697 AUTOCONF="$missing_dir/missing autoconf"
698 echo "$ac_t""missing" 1>&6
699 fi
700
701 echo $ac_n "checking for working automake""... $ac_c" 1>&6
702 echo "configure:703: checking for working automake" >&5
703 # Run test in a subshell; some versions of sh will print an error if
704 # an executable is not found, even if stderr is redirected.
705 # Redirect stdin to placate older versions of autoconf. Sigh.
706 if (automake --version) < /dev/null > /dev/null 2>&1; then
707 AUTOMAKE=automake
708 echo "$ac_t""found" 1>&6
709 else
710 AUTOMAKE="$missing_dir/missing automake"
711 echo "$ac_t""missing" 1>&6
712 fi
713
714 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
715 echo "configure:716: checking for working autoheader" >&5
716 # Run test in a subshell; some versions of sh will print an error if
717 # an executable is not found, even if stderr is redirected.
718 # Redirect stdin to placate older versions of autoconf. Sigh.
719 if (autoheader --version) < /dev/null > /dev/null 2>&1; then
720 AUTOHEADER=autoheader
721 echo "$ac_t""found" 1>&6
722 else
723 AUTOHEADER="$missing_dir/missing autoheader"
724 echo "$ac_t""missing" 1>&6
725 fi
726
727 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
728 echo "configure:729: checking for working makeinfo" >&5
729 # Run test in a subshell; some versions of sh will print an error if
730 # an executable is not found, even if stderr is redirected.
731 # Redirect stdin to placate older versions of autoconf. Sigh.
732 if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
733 MAKEINFO=makeinfo
734 echo "$ac_t""found" 1>&6
735 else
736 MAKEINFO="$missing_dir/missing makeinfo"
737 echo "$ac_t""missing" 1>&6
738 fi
739
740 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
741 echo "configure:742: checking whether ${MAKE-make} sets \${MAKE}" >&5
742 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
743 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
744 echo $ac_n "(cached) $ac_c" 1>&6
745 else
746 cat > conftestmake <<\EOF
747 all:
748 @echo 'ac_maketemp="${MAKE}"'
749 EOF
750 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
751 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
752 if test -n "$ac_maketemp"; then
753 eval ac_cv_prog_make_${ac_make}_set=yes
754 else
755 eval ac_cv_prog_make_${ac_make}_set=no
756 fi
757 rm -f conftestmake
758 fi
759 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
760 echo "$ac_t""yes" 1>&6
761 SET_MAKE=
762 else
763 echo "$ac_t""no" 1>&6
764 SET_MAKE="MAKE=${MAKE-make}"
765 fi
766
767 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
768 echo "configure:769: checking whether to enable maintainer-specific portions of Makefiles" >&5
769 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
770 if test "${enable_maintainer_mode+set}" = set; then
771 enableval="$enable_maintainer_mode"
772 USE_MAINTAINER_MODE=$enableval
773 else
774 USE_MAINTAINER_MODE=no
775 fi
776
777 echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
778 if test $USE_MAINTAINER_MODE = yes; then
779 MAINT=
780 else
781 MAINT='#M#'
782 fi
783
784
785
786
787
788
789 #--------------------------------------------------------------------
790 #
791 # User options
792 #
793 #--------------------------------------------------------------------
794
795 # Check whether --enable-debug or --disable-debug was given.
796 if test "${enable_debug+set}" = set; then
797 enableval="$enable_debug"
798 :
799 fi
800
801 if test "$enableval" != n && test "$enableval" != no; then
802 cat >> confdefs.h <<\EOF
803 #define DEBUG_EXTENSIONS 1
804 EOF
805
806 cat >> confdefs.h <<\EOF
807 #define READER_EXTENSIONS 1
808 EOF
809
810 LIBOBJS="backtrace.o stacks.o debug.o srcprop.o $LIBOBJS"
811 fi
812
813 # Check whether --enable-dynamic-linking or --disable-dynamic-linking was given.
814 if test "${enable_dynamic_linking+set}" = set; then
815 enableval="$enable_dynamic_linking"
816 :
817 else
818 enable_dynamic_linking=yes
819 fi
820
821
822 # Check whether --enable-guile-debug or --disable-guile-debug was given.
823 if test "${enable_guile_debug+set}" = set; then
824 enableval="$enable_guile_debug"
825 :
826 fi
827
828 if test "$enableval" = y || test "$enableval" = yes; then
829 cat >> confdefs.h <<\EOF
830 #define GUILE_DEBUG 1
831 EOF
832
833 fi
834
835 #--------------------------------------------------------------------
836
837 # Extract the first word of "gcc", so it can be a program name with args.
838 set dummy gcc; ac_word=$2
839 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
840 echo "configure:841: checking for $ac_word" >&5
841 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
842 echo $ac_n "(cached) $ac_c" 1>&6
843 else
844 if test -n "$CC"; then
845 ac_cv_prog_CC="$CC" # Let the user override the test.
846 else
847 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
848 for ac_dir in $PATH; do
849 test -z "$ac_dir" && ac_dir=.
850 if test -f $ac_dir/$ac_word; then
851 ac_cv_prog_CC="gcc"
852 break
853 fi
854 done
855 IFS="$ac_save_ifs"
856 fi
857 fi
858 CC="$ac_cv_prog_CC"
859 if test -n "$CC"; then
860 echo "$ac_t""$CC" 1>&6
861 else
862 echo "$ac_t""no" 1>&6
863 fi
864
865 if test -z "$CC"; then
866 # Extract the first word of "cc", so it can be a program name with args.
867 set dummy cc; ac_word=$2
868 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
869 echo "configure:870: checking for $ac_word" >&5
870 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
871 echo $ac_n "(cached) $ac_c" 1>&6
872 else
873 if test -n "$CC"; then
874 ac_cv_prog_CC="$CC" # Let the user override the test.
875 else
876 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
877 ac_prog_rejected=no
878 for ac_dir in $PATH; do
879 test -z "$ac_dir" && ac_dir=.
880 if test -f $ac_dir/$ac_word; then
881 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
882 ac_prog_rejected=yes
883 continue
884 fi
885 ac_cv_prog_CC="cc"
886 break
887 fi
888 done
889 IFS="$ac_save_ifs"
890 if test $ac_prog_rejected = yes; then
891 # We found a bogon in the path, so make sure we never use it.
892 set dummy $ac_cv_prog_CC
893 shift
894 if test $# -gt 0; then
895 # We chose a different compiler from the bogus one.
896 # However, it has the same basename, so the bogon will be chosen
897 # first if we set CC to just the basename; use the full file name.
898 shift
899 set dummy "$ac_dir/$ac_word" "$@"
900 shift
901 ac_cv_prog_CC="$@"
902 fi
903 fi
904 fi
905 fi
906 CC="$ac_cv_prog_CC"
907 if test -n "$CC"; then
908 echo "$ac_t""$CC" 1>&6
909 else
910 echo "$ac_t""no" 1>&6
911 fi
912
913 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
914 fi
915
916 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
917 echo "configure:918: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
918
919 ac_ext=c
920 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
921 ac_cpp='$CPP $CPPFLAGS'
922 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
923 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
924 cross_compiling=$ac_cv_prog_cc_cross
925
926 cat > conftest.$ac_ext <<EOF
927 #line 928 "configure"
928 #include "confdefs.h"
929 main(){return(0);}
930 EOF
931 if { (eval echo configure:932: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
932 ac_cv_prog_cc_works=yes
933 # If we can't run a trivial program, we are probably using a cross compiler.
934 if (./conftest; exit) 2>/dev/null; then
935 ac_cv_prog_cc_cross=no
936 else
937 ac_cv_prog_cc_cross=yes
938 fi
939 else
940 echo "configure: failed program was:" >&5
941 cat conftest.$ac_ext >&5
942 ac_cv_prog_cc_works=no
943 fi
944 rm -fr conftest*
945
946 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
947 if test $ac_cv_prog_cc_works = no; then
948 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
949 fi
950 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
951 echo "configure:952: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
952 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
953 cross_compiling=$ac_cv_prog_cc_cross
954
955 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
956 echo "configure:957: checking whether we are using GNU C" >&5
957 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
958 echo $ac_n "(cached) $ac_c" 1>&6
959 else
960 cat > conftest.c <<EOF
961 #ifdef __GNUC__
962 yes;
963 #endif
964 EOF
965 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:966: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
966 ac_cv_prog_gcc=yes
967 else
968 ac_cv_prog_gcc=no
969 fi
970 fi
971
972 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
973
974 if test $ac_cv_prog_gcc = yes; then
975 GCC=yes
976 ac_test_CFLAGS="${CFLAGS+set}"
977 ac_save_CFLAGS="$CFLAGS"
978 CFLAGS=
979 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
980 echo "configure:981: checking whether ${CC-cc} accepts -g" >&5
981 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
982 echo $ac_n "(cached) $ac_c" 1>&6
983 else
984 echo 'void f(){}' > conftest.c
985 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
986 ac_cv_prog_cc_g=yes
987 else
988 ac_cv_prog_cc_g=no
989 fi
990 rm -f conftest*
991
992 fi
993
994 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
995 if test "$ac_test_CFLAGS" = set; then
996 CFLAGS="$ac_save_CFLAGS"
997 elif test $ac_cv_prog_cc_g = yes; then
998 CFLAGS="-g -O2"
999 else
1000 CFLAGS="-O2"
1001 fi
1002 else
1003 GCC=
1004 test "${CFLAGS+set}" = set || CFLAGS="-g"
1005 fi
1006
1007 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1008 echo "configure:1009: checking how to run the C preprocessor" >&5
1009 # On Suns, sometimes $CPP names a directory.
1010 if test -n "$CPP" && test -d "$CPP"; then
1011 CPP=
1012 fi
1013 if test -z "$CPP"; then
1014 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1015 echo $ac_n "(cached) $ac_c" 1>&6
1016 else
1017 # This must be in double quotes, not single quotes, because CPP may get
1018 # substituted into the Makefile and "${CC-cc}" will confuse make.
1019 CPP="${CC-cc} -E"
1020 # On the NeXT, cc -E runs the code through the compiler's parser,
1021 # not just through cpp.
1022 cat > conftest.$ac_ext <<EOF
1023 #line 1024 "configure"
1024 #include "confdefs.h"
1025 #include <assert.h>
1026 Syntax Error
1027 EOF
1028 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1029 { (eval echo configure:1030: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1030 ac_err=`grep -v '^ *+' conftest.out`
1031 if test -z "$ac_err"; then
1032 :
1033 else
1034 echo "$ac_err" >&5
1035 echo "configure: failed program was:" >&5
1036 cat conftest.$ac_ext >&5
1037 rm -rf conftest*
1038 CPP="${CC-cc} -E -traditional-cpp"
1039 cat > conftest.$ac_ext <<EOF
1040 #line 1041 "configure"
1041 #include "confdefs.h"
1042 #include <assert.h>
1043 Syntax Error
1044 EOF
1045 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1046 { (eval echo configure:1047: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1047 ac_err=`grep -v '^ *+' conftest.out`
1048 if test -z "$ac_err"; then
1049 :
1050 else
1051 echo "$ac_err" >&5
1052 echo "configure: failed program was:" >&5
1053 cat conftest.$ac_ext >&5
1054 rm -rf conftest*
1055 CPP=/lib/cpp
1056 fi
1057 rm -f conftest*
1058 fi
1059 rm -f conftest*
1060 ac_cv_prog_CPP="$CPP"
1061 fi
1062 CPP="$ac_cv_prog_CPP"
1063 else
1064 ac_cv_prog_CPP="$CPP"
1065 fi
1066 echo "$ac_t""$CPP" 1>&6
1067
1068
1069 # Make sure we can run config.sub.
1070 if $ac_config_sub sun4 >/dev/null 2>&1; then :
1071 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
1072 fi
1073
1074 echo $ac_n "checking host system type""... $ac_c" 1>&6
1075 echo "configure:1076: checking host system type" >&5
1076
1077 host_alias=$host
1078 case "$host_alias" in
1079 NONE)
1080 case $nonopt in
1081 NONE)
1082 if host_alias=`$ac_config_guess`; then :
1083 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
1084 fi ;;
1085 *) host_alias=$nonopt ;;
1086 esac ;;
1087 esac
1088
1089 host=`$ac_config_sub $host_alias`
1090 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1091 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1092 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1093 echo "$ac_t""$host" 1>&6
1094
1095 # Extract the first word of "ranlib", so it can be a program name with args.
1096 set dummy ranlib; ac_word=$2
1097 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1098 echo "configure:1099: checking for $ac_word" >&5
1099 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1100 echo $ac_n "(cached) $ac_c" 1>&6
1101 else
1102 if test -n "$RANLIB"; then
1103 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1104 else
1105 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1106 for ac_dir in $PATH; do
1107 test -z "$ac_dir" && ac_dir=.
1108 if test -f $ac_dir/$ac_word; then
1109 ac_cv_prog_RANLIB="ranlib"
1110 break
1111 fi
1112 done
1113 IFS="$ac_save_ifs"
1114 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1115 fi
1116 fi
1117 RANLIB="$ac_cv_prog_RANLIB"
1118 if test -n "$RANLIB"; then
1119 echo "$ac_t""$RANLIB" 1>&6
1120 else
1121 echo "$ac_t""no" 1>&6
1122 fi
1123
1124 # Check whether --with-gnu-ld or --without-gnu-ld was given.
1125 if test "${with_gnu_ld+set}" = set; then
1126 withval="$with_gnu_ld"
1127 test "$withval" = no || with_gnu_ld=yes
1128 else
1129 with_gnu_ld=no
1130 fi
1131
1132 if test "$with_gnu_ld" = yes; then
1133 echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
1134 echo "configure:1135: checking for GNU ld" >&5
1135 else
1136 echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
1137 echo "configure:1138: checking for non-GNU ld" >&5
1138 fi
1139 if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then
1140 echo $ac_n "(cached) $ac_c" 1>&6
1141 else
1142 case "$LD" in
1143 /*)
1144 ac_cv_path_LD="$LD" # Let the user override the test with a path.
1145 ;;
1146 *)
1147 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1148 for ac_dir in $PATH; do
1149 test -z "$ac_dir" && ac_dir=.
1150 if test -f "$ac_dir/ld"; then
1151 ac_cv_path_LD="$ac_dir/ld"
1152 # Check to see if the program is GNU ld. I'd rather use --version,
1153 # but apparently some GNU ld's only accept -v.
1154 # Break only if it was the GNU/non-GNU ld that we prefer.
1155 if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU ld|with BFD)' > /dev/null; then
1156 test "$with_gnu_ld" = yes && break
1157 else
1158 test "$with_gnu_ld" != yes && break
1159 fi
1160 fi
1161 done
1162 IFS="$ac_save_ifs"
1163 ;;
1164 esac
1165 fi
1166
1167 LD="$ac_cv_path_LD"
1168 if test -n "$LD"; then
1169 echo "$ac_t""$LD" 1>&6
1170 else
1171 echo "$ac_t""no" 1>&6
1172 fi
1173 test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
1174
1175 echo $ac_n "checking whether we are using GNU ld""... $ac_c" 1>&6
1176 echo "configure:1177: checking whether we are using GNU ld" >&5
1177 if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then
1178 echo $ac_n "(cached) $ac_c" 1>&6
1179 else
1180 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
1181 if $LD -v 2>&1 </dev/null | egrep '(GNU ld|with BFD)' > /dev/null; then
1182 ac_cv_prog_gnu_ld=yes
1183 else
1184 ac_cv_prog_gnu_ld=no
1185 fi
1186 fi
1187
1188 echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6
1189
1190
1191 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
1192 echo "configure:1193: checking whether ln -s works" >&5
1193 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
1194 echo $ac_n "(cached) $ac_c" 1>&6
1195 else
1196 rm -f conftestdata
1197 if ln -s X conftestdata 2>/dev/null
1198 then
1199 rm -f conftestdata
1200 ac_cv_prog_LN_S="ln -s"
1201 else
1202 ac_cv_prog_LN_S=ln
1203 fi
1204 fi
1205 LN_S="$ac_cv_prog_LN_S"
1206 if test "$ac_cv_prog_LN_S" = "ln -s"; then
1207 echo "$ac_t""yes" 1>&6
1208 else
1209 echo "$ac_t""no" 1>&6
1210 fi
1211
1212
1213
1214
1215
1216
1217
1218 # Always use our own libtool.
1219 LIBTOOL='$(top_builddir)/libtool'
1220
1221
1222 # Check whether --enable-shared or --disable-shared was given.
1223 if test "${enable_shared+set}" = set; then
1224 enableval="$enable_shared"
1225 test "$enableval" = no && libtool_shared=" --disable-shared"
1226 else
1227 libtool_shared=
1228 fi
1229
1230
1231 # Check whether --enable-static or --disable-static was given.
1232 if test "${enable_static+set}" = set; then
1233 enableval="$enable_static"
1234 test "$enableval" = no && libtool_static=" --disable-static"
1235 else
1236 libtool_static=
1237 fi
1238
1239
1240 libtool_flags="$libtool_shared$libtool_static"
1241 test "$silent" = yes && libtool_flags="$libtool_flags --silent"
1242 test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc"
1243 test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
1244
1245 # Some flags need to be propagated to the compiler or linker for good
1246 # libtool support.
1247 case "$host" in
1248 *-*-irix6*)
1249 for f in '-32' '-64' '-cckr' '-n32' '-mips1' '-mips2' '-mips3' '-mips4'; do
1250 if echo " $CC $CFLAGS " | egrep -e "[ ]$f[ ]" > /dev/null; then
1251 LD="${LD-ld} $f"
1252 fi
1253 done
1254 ;;
1255
1256 *-*-sco3.2v5*)
1257 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1258 CFLAGS="$CFLAGS -belf"
1259 ;;
1260 esac
1261
1262 # Actually configure libtool. ac_aux_dir is where install-sh is found.
1263 CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
1264 LD="$LD" RANLIB="$RANLIB" LN_S="$LN_S" \
1265 ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig \
1266 $libtool_flags --no-verify $ac_aux_dir/ltmain.sh $host \
1267 || { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
1268
1269
1270 echo $ac_n "checking for AIX""... $ac_c" 1>&6
1271 echo "configure:1272: checking for AIX" >&5
1272 cat > conftest.$ac_ext <<EOF
1273 #line 1274 "configure"
1274 #include "confdefs.h"
1275 #ifdef _AIX
1276 yes
1277 #endif
1278
1279 EOF
1280 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1281 egrep "yes" >/dev/null 2>&1; then
1282 rm -rf conftest*
1283 echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF
1284 #define _ALL_SOURCE 1
1285 EOF
1286
1287 else
1288 rm -rf conftest*
1289 echo "$ac_t""no" 1>&6
1290 fi
1291 rm -f conftest*
1292
1293
1294 echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
1295 echo "configure:1296: checking for POSIXized ISC" >&5
1296 if test -d /etc/conf/kconfig.d &&
1297 grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
1298 then
1299 echo "$ac_t""yes" 1>&6
1300 ISC=yes # If later tests want to check for ISC.
1301 cat >> confdefs.h <<\EOF
1302 #define _POSIX_SOURCE 1
1303 EOF
1304
1305 if test "$GCC" = yes; then
1306 CC="$CC -posix"
1307 else
1308 CC="$CC -Xp"
1309 fi
1310 else
1311 echo "$ac_t""no" 1>&6
1312 ISC=
1313 fi
1314
1315 ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'`
1316 echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6
1317 echo "configure:1318: checking for minix/config.h" >&5
1318 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1319 echo $ac_n "(cached) $ac_c" 1>&6
1320 else
1321 cat > conftest.$ac_ext <<EOF
1322 #line 1323 "configure"
1323 #include "confdefs.h"
1324 #include <minix/config.h>
1325 EOF
1326 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1327 { (eval echo configure:1328: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1328 ac_err=`grep -v '^ *+' conftest.out`
1329 if test -z "$ac_err"; then
1330 rm -rf conftest*
1331 eval "ac_cv_header_$ac_safe=yes"
1332 else
1333 echo "$ac_err" >&5
1334 echo "configure: failed program was:" >&5
1335 cat conftest.$ac_ext >&5
1336 rm -rf conftest*
1337 eval "ac_cv_header_$ac_safe=no"
1338 fi
1339 rm -f conftest*
1340 fi
1341 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1342 echo "$ac_t""yes" 1>&6
1343 MINIX=yes
1344 else
1345 echo "$ac_t""no" 1>&6
1346 MINIX=
1347 fi
1348
1349 if test "$MINIX" = yes; then
1350 cat >> confdefs.h <<\EOF
1351 #define _POSIX_SOURCE 1
1352 EOF
1353
1354 cat >> confdefs.h <<\EOF
1355 #define _POSIX_1_SOURCE 2
1356 EOF
1357
1358 cat >> confdefs.h <<\EOF
1359 #define _MINIX 1
1360 EOF
1361
1362 fi
1363
1364
1365 echo $ac_n "checking for working const""... $ac_c" 1>&6
1366 echo "configure:1367: checking for working const" >&5
1367 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
1368 echo $ac_n "(cached) $ac_c" 1>&6
1369 else
1370 cat > conftest.$ac_ext <<EOF
1371 #line 1372 "configure"
1372 #include "confdefs.h"
1373
1374 int main() {
1375
1376 /* Ultrix mips cc rejects this. */
1377 typedef int charset[2]; const charset x;
1378 /* SunOS 4.1.1 cc rejects this. */
1379 char const *const *ccp;
1380 char **p;
1381 /* NEC SVR4.0.2 mips cc rejects this. */
1382 struct point {int x, y;};
1383 static struct point const zero = {0,0};
1384 /* AIX XL C 1.02.0.0 rejects this.
1385 It does not let you subtract one const X* pointer from another in an arm
1386 of an if-expression whose if-part is not a constant expression */
1387 const char *g = "string";
1388 ccp = &g + (g ? g-g : 0);
1389 /* HPUX 7.0 cc rejects these. */
1390 ++ccp;
1391 p = (char**) ccp;
1392 ccp = (char const *const *) p;
1393 { /* SCO 3.2v4 cc rejects this. */
1394 char *t;
1395 char const *s = 0 ? (char *) 0 : (char const *) 0;
1396
1397 *t++ = 0;
1398 }
1399 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
1400 int x[] = {25, 17};
1401 const int *foo = &x[0];
1402 ++foo;
1403 }
1404 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
1405 typedef const int *iptr;
1406 iptr p = 0;
1407 ++p;
1408 }
1409 { /* AIX XL C 1.02.0.0 rejects this saying
1410 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
1411 struct s { int j; const int *ap[3]; };
1412 struct s *b; b->j = 5;
1413 }
1414 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
1415 const int foo = 10;
1416 }
1417
1418 ; return 0; }
1419 EOF
1420 if { (eval echo configure:1421: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1421 rm -rf conftest*
1422 ac_cv_c_const=yes
1423 else
1424 echo "configure: failed program was:" >&5
1425 cat conftest.$ac_ext >&5
1426 rm -rf conftest*
1427 ac_cv_c_const=no
1428 fi
1429 rm -f conftest*
1430 fi
1431
1432 echo "$ac_t""$ac_cv_c_const" 1>&6
1433 if test $ac_cv_c_const = no; then
1434 cat >> confdefs.h <<\EOF
1435 #define const
1436 EOF
1437
1438 fi
1439
1440
1441 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1442 echo "configure:1443: checking for ANSI C header files" >&5
1443 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1444 echo $ac_n "(cached) $ac_c" 1>&6
1445 else
1446 cat > conftest.$ac_ext <<EOF
1447 #line 1448 "configure"
1448 #include "confdefs.h"
1449 #include <stdlib.h>
1450 #include <stdarg.h>
1451 #include <string.h>
1452 #include <float.h>
1453 EOF
1454 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1455 { (eval echo configure:1456: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1456 ac_err=`grep -v '^ *+' conftest.out`
1457 if test -z "$ac_err"; then
1458 rm -rf conftest*
1459 ac_cv_header_stdc=yes
1460 else
1461 echo "$ac_err" >&5
1462 echo "configure: failed program was:" >&5
1463 cat conftest.$ac_ext >&5
1464 rm -rf conftest*
1465 ac_cv_header_stdc=no
1466 fi
1467 rm -f conftest*
1468
1469 if test $ac_cv_header_stdc = yes; then
1470 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1471 cat > conftest.$ac_ext <<EOF
1472 #line 1473 "configure"
1473 #include "confdefs.h"
1474 #include <string.h>
1475 EOF
1476 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1477 egrep "memchr" >/dev/null 2>&1; then
1478 :
1479 else
1480 rm -rf conftest*
1481 ac_cv_header_stdc=no
1482 fi
1483 rm -f conftest*
1484
1485 fi
1486
1487 if test $ac_cv_header_stdc = yes; then
1488 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1489 cat > conftest.$ac_ext <<EOF
1490 #line 1491 "configure"
1491 #include "confdefs.h"
1492 #include <stdlib.h>
1493 EOF
1494 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1495 egrep "free" >/dev/null 2>&1; then
1496 :
1497 else
1498 rm -rf conftest*
1499 ac_cv_header_stdc=no
1500 fi
1501 rm -f conftest*
1502
1503 fi
1504
1505 if test $ac_cv_header_stdc = yes; then
1506 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1507 if test "$cross_compiling" = yes; then
1508 :
1509 else
1510 cat > conftest.$ac_ext <<EOF
1511 #line 1512 "configure"
1512 #include "confdefs.h"
1513 #include <ctype.h>
1514 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1515 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1516 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1517 int main () { int i; for (i = 0; i < 256; i++)
1518 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1519 exit (0); }
1520
1521 EOF
1522 if { (eval echo configure:1523: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
1523 then
1524 :
1525 else
1526 echo "configure: failed program was:" >&5
1527 cat conftest.$ac_ext >&5
1528 rm -fr conftest*
1529 ac_cv_header_stdc=no
1530 fi
1531 rm -fr conftest*
1532 fi
1533
1534 fi
1535 fi
1536
1537 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1538 if test $ac_cv_header_stdc = yes; then
1539 cat >> confdefs.h <<\EOF
1540 #define STDC_HEADERS 1
1541 EOF
1542
1543 fi
1544
1545 ac_header_dirent=no
1546 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
1547 do
1548 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1549 echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
1550 echo "configure:1551: checking for $ac_hdr that defines DIR" >&5
1551 if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
1552 echo $ac_n "(cached) $ac_c" 1>&6
1553 else
1554 cat > conftest.$ac_ext <<EOF
1555 #line 1556 "configure"
1556 #include "confdefs.h"
1557 #include <sys/types.h>
1558 #include <$ac_hdr>
1559 int main() {
1560 DIR *dirp = 0;
1561 ; return 0; }
1562 EOF
1563 if { (eval echo configure:1564: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1564 rm -rf conftest*
1565 eval "ac_cv_header_dirent_$ac_safe=yes"
1566 else
1567 echo "configure: failed program was:" >&5
1568 cat conftest.$ac_ext >&5
1569 rm -rf conftest*
1570 eval "ac_cv_header_dirent_$ac_safe=no"
1571 fi
1572 rm -f conftest*
1573 fi
1574 if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
1575 echo "$ac_t""yes" 1>&6
1576 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1577 cat >> confdefs.h <<EOF
1578 #define $ac_tr_hdr 1
1579 EOF
1580 ac_header_dirent=$ac_hdr; break
1581 else
1582 echo "$ac_t""no" 1>&6
1583 fi
1584 done
1585 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
1586 if test $ac_header_dirent = dirent.h; then
1587 echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
1588 echo "configure:1589: checking for opendir in -ldir" >&5
1589 ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
1590 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1591 echo $ac_n "(cached) $ac_c" 1>&6
1592 else
1593 ac_save_LIBS="$LIBS"
1594 LIBS="-ldir $LIBS"
1595 cat > conftest.$ac_ext <<EOF
1596 #line 1597 "configure"
1597 #include "confdefs.h"
1598 /* Override any gcc2 internal prototype to avoid an error. */
1599 /* We use char because int might match the return type of a gcc2
1600 builtin and then its argument prototype would still apply. */
1601 char opendir();
1602
1603 int main() {
1604 opendir()
1605 ; return 0; }
1606 EOF
1607 if { (eval echo configure:1608: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1608 rm -rf conftest*
1609 eval "ac_cv_lib_$ac_lib_var=yes"
1610 else
1611 echo "configure: failed program was:" >&5
1612 cat conftest.$ac_ext >&5
1613 rm -rf conftest*
1614 eval "ac_cv_lib_$ac_lib_var=no"
1615 fi
1616 rm -f conftest*
1617 LIBS="$ac_save_LIBS"
1618
1619 fi
1620 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1621 echo "$ac_t""yes" 1>&6
1622 LIBS="$LIBS -ldir"
1623 else
1624 echo "$ac_t""no" 1>&6
1625 fi
1626
1627 else
1628 echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
1629 echo "configure:1630: checking for opendir in -lx" >&5
1630 ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
1631 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1632 echo $ac_n "(cached) $ac_c" 1>&6
1633 else
1634 ac_save_LIBS="$LIBS"
1635 LIBS="-lx $LIBS"
1636 cat > conftest.$ac_ext <<EOF
1637 #line 1638 "configure"
1638 #include "confdefs.h"
1639 /* Override any gcc2 internal prototype to avoid an error. */
1640 /* We use char because int might match the return type of a gcc2
1641 builtin and then its argument prototype would still apply. */
1642 char opendir();
1643
1644 int main() {
1645 opendir()
1646 ; return 0; }
1647 EOF
1648 if { (eval echo configure:1649: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1649 rm -rf conftest*
1650 eval "ac_cv_lib_$ac_lib_var=yes"
1651 else
1652 echo "configure: failed program was:" >&5
1653 cat conftest.$ac_ext >&5
1654 rm -rf conftest*
1655 eval "ac_cv_lib_$ac_lib_var=no"
1656 fi
1657 rm -f conftest*
1658 LIBS="$ac_save_LIBS"
1659
1660 fi
1661 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1662 echo "$ac_t""yes" 1>&6
1663 LIBS="$LIBS -lx"
1664 else
1665 echo "$ac_t""no" 1>&6
1666 fi
1667
1668 fi
1669
1670 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
1671 echo "configure:1672: checking whether time.h and sys/time.h may both be included" >&5
1672 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
1673 echo $ac_n "(cached) $ac_c" 1>&6
1674 else
1675 cat > conftest.$ac_ext <<EOF
1676 #line 1677 "configure"
1677 #include "confdefs.h"
1678 #include <sys/types.h>
1679 #include <sys/time.h>
1680 #include <time.h>
1681 int main() {
1682 struct tm *tp;
1683 ; return 0; }
1684 EOF
1685 if { (eval echo configure:1686: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1686 rm -rf conftest*
1687 ac_cv_header_time=yes
1688 else
1689 echo "configure: failed program was:" >&5
1690 cat conftest.$ac_ext >&5
1691 rm -rf conftest*
1692 ac_cv_header_time=no
1693 fi
1694 rm -f conftest*
1695 fi
1696
1697 echo "$ac_t""$ac_cv_header_time" 1>&6
1698 if test $ac_cv_header_time = yes; then
1699 cat >> confdefs.h <<\EOF
1700 #define TIME_WITH_SYS_TIME 1
1701 EOF
1702
1703 fi
1704
1705 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
1706 echo "configure:1707: checking for sys/wait.h that is POSIX.1 compatible" >&5
1707 if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
1708 echo $ac_n "(cached) $ac_c" 1>&6
1709 else
1710 cat > conftest.$ac_ext <<EOF
1711 #line 1712 "configure"
1712 #include "confdefs.h"
1713 #include <sys/types.h>
1714 #include <sys/wait.h>
1715 #ifndef WEXITSTATUS
1716 #define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
1717 #endif
1718 #ifndef WIFEXITED
1719 #define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
1720 #endif
1721 int main() {
1722 int s;
1723 wait (&s);
1724 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
1725 ; return 0; }
1726 EOF
1727 if { (eval echo configure:1728: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1728 rm -rf conftest*
1729 ac_cv_header_sys_wait_h=yes
1730 else
1731 echo "configure: failed program was:" >&5
1732 cat conftest.$ac_ext >&5
1733 rm -rf conftest*
1734 ac_cv_header_sys_wait_h=no
1735 fi
1736 rm -f conftest*
1737 fi
1738
1739 echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
1740 if test $ac_cv_header_sys_wait_h = yes; then
1741 cat >> confdefs.h <<\EOF
1742 #define HAVE_SYS_WAIT_H 1
1743 EOF
1744
1745 fi
1746
1747 for ac_hdr in libc.h limits.h malloc.h memory.h string.h regex.h sys/ioctl.h sys/select.h sys/time.h sys/timeb.h sys/times.h sys/types.h sys/utime.h time.h unistd.h utime.h
1748 do
1749 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1750 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1751 echo "configure:1752: checking for $ac_hdr" >&5
1752 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1753 echo $ac_n "(cached) $ac_c" 1>&6
1754 else
1755 cat > conftest.$ac_ext <<EOF
1756 #line 1757 "configure"
1757 #include "confdefs.h"
1758 #include <$ac_hdr>
1759 EOF
1760 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1761 { (eval echo configure:1762: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1762 ac_err=`grep -v '^ *+' conftest.out`
1763 if test -z "$ac_err"; then
1764 rm -rf conftest*
1765 eval "ac_cv_header_$ac_safe=yes"
1766 else
1767 echo "$ac_err" >&5
1768 echo "configure: failed program was:" >&5
1769 cat conftest.$ac_ext >&5
1770 rm -rf conftest*
1771 eval "ac_cv_header_$ac_safe=no"
1772 fi
1773 rm -f conftest*
1774 fi
1775 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1776 echo "$ac_t""yes" 1>&6
1777 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1778 cat >> confdefs.h <<EOF
1779 #define $ac_tr_hdr 1
1780 EOF
1781
1782 else
1783 echo "$ac_t""no" 1>&6
1784 fi
1785 done
1786
1787
1788 for ac_hdr in libc.h unistd.h
1789 do
1790 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1791 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1792 echo "configure:1793: checking for $ac_hdr" >&5
1793 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1794 echo $ac_n "(cached) $ac_c" 1>&6
1795 else
1796 cat > conftest.$ac_ext <<EOF
1797 #line 1798 "configure"
1798 #include "confdefs.h"
1799 #include <$ac_hdr>
1800 EOF
1801 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1802 { (eval echo configure:1803: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1803 ac_err=`grep -v '^ *+' conftest.out`
1804 if test -z "$ac_err"; then
1805 rm -rf conftest*
1806 eval "ac_cv_header_$ac_safe=yes"
1807 else
1808 echo "$ac_err" >&5
1809 echo "configure: failed program was:" >&5
1810 cat conftest.$ac_ext >&5
1811 rm -rf conftest*
1812 eval "ac_cv_header_$ac_safe=no"
1813 fi
1814 rm -f conftest*
1815 fi
1816 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1817 echo "$ac_t""yes" 1>&6
1818 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1819 cat >> confdefs.h <<EOF
1820 #define $ac_tr_hdr 1
1821 EOF
1822
1823 else
1824 echo "$ac_t""no" 1>&6
1825 fi
1826 done
1827
1828 echo $ac_n "checking "whether libc.h and unistd.h can be included together"""... $ac_c" 1>&6
1829 echo "configure:1830: checking "whether libc.h and unistd.h can be included together"" >&5
1830 if eval "test \"`echo '$''{'guile_cv_header_libc_with_unistd'+set}'`\" = set"; then
1831 echo $ac_n "(cached) $ac_c" 1>&6
1832 else
1833
1834 if test "$ac_cv_header_libc_h" = "no"; then
1835 guile_cv_header_libc_with_unistd="no"
1836 elif test "$ac_cv_header_unistd.h" = "no"; then
1837 guile_cv_header_libc_with_unistd="yes"
1838 else
1839 cat > conftest.$ac_ext <<EOF
1840 #line 1841 "configure"
1841 #include "confdefs.h"
1842
1843 # include <libc.h>
1844 # include <unistd.h>
1845
1846 int main() {
1847
1848 ; return 0; }
1849 EOF
1850 if { (eval echo configure:1851: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1851 rm -rf conftest*
1852 guile_cv_header_libc_with_unistd=yes
1853 else
1854 echo "configure: failed program was:" >&5
1855 cat conftest.$ac_ext >&5
1856 rm -rf conftest*
1857 guile_cv_header_libc_with_unistd=no
1858
1859 fi
1860 rm -f conftest*
1861 fi
1862
1863
1864 fi
1865
1866 echo "$ac_t""$guile_cv_header_libc_with_unistd" 1>&6
1867 if test "$guile_cv_header_libc_with_unistd" = yes; then
1868 cat >> confdefs.h <<\EOF
1869 #define LIBC_H_WITH_UNISTD_H 1
1870 EOF
1871
1872 fi
1873
1874
1875
1876 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
1877 echo "configure:1878: checking for uid_t in sys/types.h" >&5
1878 if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
1879 echo $ac_n "(cached) $ac_c" 1>&6
1880 else
1881 cat > conftest.$ac_ext <<EOF
1882 #line 1883 "configure"
1883 #include "confdefs.h"
1884 #include <sys/types.h>
1885 EOF
1886 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1887 egrep "uid_t" >/dev/null 2>&1; then
1888 rm -rf conftest*
1889 ac_cv_type_uid_t=yes
1890 else
1891 rm -rf conftest*
1892 ac_cv_type_uid_t=no
1893 fi
1894 rm -f conftest*
1895
1896 fi
1897
1898 echo "$ac_t""$ac_cv_type_uid_t" 1>&6
1899 if test $ac_cv_type_uid_t = no; then
1900 cat >> confdefs.h <<\EOF
1901 #define uid_t int
1902 EOF
1903
1904 cat >> confdefs.h <<\EOF
1905 #define gid_t int
1906 EOF
1907
1908 fi
1909
1910 echo $ac_n "checking type of array argument to getgroups""... $ac_c" 1>&6
1911 echo "configure:1912: checking type of array argument to getgroups" >&5
1912 if eval "test \"`echo '$''{'ac_cv_type_getgroups'+set}'`\" = set"; then
1913 echo $ac_n "(cached) $ac_c" 1>&6
1914 else
1915 if test "$cross_compiling" = yes; then
1916 ac_cv_type_getgroups=cross
1917 else
1918 cat > conftest.$ac_ext <<EOF
1919 #line 1920 "configure"
1920 #include "confdefs.h"
1921
1922 /* Thanks to Mike Rendell for this test. */
1923 #include <sys/types.h>
1924 #define NGID 256
1925 #undef MAX
1926 #define MAX(x, y) ((x) > (y) ? (x) : (y))
1927 main()
1928 {
1929 gid_t gidset[NGID];
1930 int i, n;
1931 union { gid_t gval; long lval; } val;
1932
1933 val.lval = -1;
1934 for (i = 0; i < NGID; i++)
1935 gidset[i] = val.gval;
1936 n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
1937 gidset);
1938 /* Exit non-zero if getgroups seems to require an array of ints. This
1939 happens when gid_t is short but getgroups modifies an array of ints. */
1940 exit ((n > 0 && gidset[n] != val.gval) ? 1 : 0);
1941 }
1942
1943 EOF
1944 if { (eval echo configure:1945: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
1945 then
1946 ac_cv_type_getgroups=gid_t
1947 else
1948 echo "configure: failed program was:" >&5
1949 cat conftest.$ac_ext >&5
1950 rm -fr conftest*
1951 ac_cv_type_getgroups=int
1952 fi
1953 rm -fr conftest*
1954 fi
1955
1956 if test $ac_cv_type_getgroups = cross; then
1957 cat > conftest.$ac_ext <<EOF
1958 #line 1959 "configure"
1959 #include "confdefs.h"
1960 #include <unistd.h>
1961 EOF
1962 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1963 egrep "getgroups.*int.*gid_t" >/dev/null 2>&1; then
1964 rm -rf conftest*
1965 ac_cv_type_getgroups=gid_t
1966 else
1967 rm -rf conftest*
1968 ac_cv_type_getgroups=int
1969 fi
1970 rm -f conftest*
1971
1972 fi
1973 fi
1974
1975 echo "$ac_t""$ac_cv_type_getgroups" 1>&6
1976 cat >> confdefs.h <<EOF
1977 #define GETGROUPS_T $ac_cv_type_getgroups
1978 EOF
1979
1980
1981 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
1982 echo "configure:1983: checking return type of signal handlers" >&5
1983 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
1984 echo $ac_n "(cached) $ac_c" 1>&6
1985 else
1986 cat > conftest.$ac_ext <<EOF
1987 #line 1988 "configure"
1988 #include "confdefs.h"
1989 #include <sys/types.h>
1990 #include <signal.h>
1991 #ifdef signal
1992 #undef signal
1993 #endif
1994 #ifdef __cplusplus
1995 extern "C" void (*signal (int, void (*)(int)))(int);
1996 #else
1997 void (*signal ()) ();
1998 #endif
1999
2000 int main() {
2001 int i;
2002 ; return 0; }
2003 EOF
2004 if { (eval echo configure:2005: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2005 rm -rf conftest*
2006 ac_cv_type_signal=void
2007 else
2008 echo "configure: failed program was:" >&5
2009 cat conftest.$ac_ext >&5
2010 rm -rf conftest*
2011 ac_cv_type_signal=int
2012 fi
2013 rm -f conftest*
2014 fi
2015
2016 echo "$ac_t""$ac_cv_type_signal" 1>&6
2017 cat >> confdefs.h <<EOF
2018 #define RETSIGTYPE $ac_cv_type_signal
2019 EOF
2020
2021
2022 echo $ac_n "checking for mode_t""... $ac_c" 1>&6
2023 echo "configure:2024: checking for mode_t" >&5
2024 if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
2025 echo $ac_n "(cached) $ac_c" 1>&6
2026 else
2027 cat > conftest.$ac_ext <<EOF
2028 #line 2029 "configure"
2029 #include "confdefs.h"
2030 #include <sys/types.h>
2031 #if STDC_HEADERS
2032 #include <stdlib.h>
2033 #include <stddef.h>
2034 #endif
2035 EOF
2036 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2037 egrep "mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2038 rm -rf conftest*
2039 ac_cv_type_mode_t=yes
2040 else
2041 rm -rf conftest*
2042 ac_cv_type_mode_t=no
2043 fi
2044 rm -f conftest*
2045
2046 fi
2047 echo "$ac_t""$ac_cv_type_mode_t" 1>&6
2048 if test $ac_cv_type_mode_t = no; then
2049 cat >> confdefs.h <<\EOF
2050 #define mode_t int
2051 EOF
2052
2053 fi
2054
2055
2056 echo $ac_n "checking for main in -lm""... $ac_c" 1>&6
2057 echo "configure:2058: checking for main in -lm" >&5
2058 ac_lib_var=`echo m'_'main | sed 'y%./+-%__p_%'`
2059 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2060 echo $ac_n "(cached) $ac_c" 1>&6
2061 else
2062 ac_save_LIBS="$LIBS"
2063 LIBS="-lm $LIBS"
2064 cat > conftest.$ac_ext <<EOF
2065 #line 2066 "configure"
2066 #include "confdefs.h"
2067
2068 int main() {
2069 main()
2070 ; return 0; }
2071 EOF
2072 if { (eval echo configure:2073: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2073 rm -rf conftest*
2074 eval "ac_cv_lib_$ac_lib_var=yes"
2075 else
2076 echo "configure: failed program was:" >&5
2077 cat conftest.$ac_ext >&5
2078 rm -rf conftest*
2079 eval "ac_cv_lib_$ac_lib_var=no"
2080 fi
2081 rm -f conftest*
2082 LIBS="$ac_save_LIBS"
2083
2084 fi
2085 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2086 echo "$ac_t""yes" 1>&6
2087 ac_tr_lib=HAVE_LIB`echo m | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2088 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2089 cat >> confdefs.h <<EOF
2090 #define $ac_tr_lib 1
2091 EOF
2092
2093 LIBS="-lm $LIBS"
2094
2095 else
2096 echo "$ac_t""no" 1>&6
2097 fi
2098
2099 echo $ac_n "checking for main in -lrx""... $ac_c" 1>&6
2100 echo "configure:2101: checking for main in -lrx" >&5
2101 ac_lib_var=`echo rx'_'main | sed 'y%./+-%__p_%'`
2102 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2103 echo $ac_n "(cached) $ac_c" 1>&6
2104 else
2105 ac_save_LIBS="$LIBS"
2106 LIBS="-lrx $LIBS"
2107 cat > conftest.$ac_ext <<EOF
2108 #line 2109 "configure"
2109 #include "confdefs.h"
2110
2111 int main() {
2112 main()
2113 ; return 0; }
2114 EOF
2115 if { (eval echo configure:2116: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2116 rm -rf conftest*
2117 eval "ac_cv_lib_$ac_lib_var=yes"
2118 else
2119 echo "configure: failed program was:" >&5
2120 cat conftest.$ac_ext >&5
2121 rm -rf conftest*
2122 eval "ac_cv_lib_$ac_lib_var=no"
2123 fi
2124 rm -f conftest*
2125 LIBS="$ac_save_LIBS"
2126
2127 fi
2128 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2129 echo "$ac_t""yes" 1>&6
2130 ac_tr_lib=HAVE_LIB`echo rx | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2131 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2132 cat >> confdefs.h <<EOF
2133 #define $ac_tr_lib 1
2134 EOF
2135
2136 LIBS="-lrx $LIBS"
2137
2138 else
2139 echo "$ac_t""no" 1>&6
2140 fi
2141
2142 echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
2143 echo "configure:2144: checking for gethostbyname" >&5
2144 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
2145 echo $ac_n "(cached) $ac_c" 1>&6
2146 else
2147 cat > conftest.$ac_ext <<EOF
2148 #line 2149 "configure"
2149 #include "confdefs.h"
2150 /* System header to define __stub macros and hopefully few prototypes,
2151 which can conflict with char gethostbyname(); below. */
2152 #include <assert.h>
2153 /* Override any gcc2 internal prototype to avoid an error. */
2154 /* We use char because int might match the return type of a gcc2
2155 builtin and then its argument prototype would still apply. */
2156 char gethostbyname();
2157
2158 int main() {
2159
2160 /* The GNU C library defines this for functions which it implements
2161 to always fail with ENOSYS. Some functions are actually named
2162 something starting with __ and the normal name is an alias. */
2163 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
2164 choke me
2165 #else
2166 gethostbyname();
2167 #endif
2168
2169 ; return 0; }
2170 EOF
2171 if { (eval echo configure:2172: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2172 rm -rf conftest*
2173 eval "ac_cv_func_gethostbyname=yes"
2174 else
2175 echo "configure: failed program was:" >&5
2176 cat conftest.$ac_ext >&5
2177 rm -rf conftest*
2178 eval "ac_cv_func_gethostbyname=no"
2179 fi
2180 rm -f conftest*
2181 fi
2182
2183 if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
2184 echo "$ac_t""yes" 1>&6
2185 :
2186 else
2187 echo "$ac_t""no" 1>&6
2188 fi
2189
2190 if test $ac_cv_func_gethostbyname = no; then
2191 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
2192 echo "configure:2193: checking for gethostbyname in -lnsl" >&5
2193 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
2194 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2195 echo $ac_n "(cached) $ac_c" 1>&6
2196 else
2197 ac_save_LIBS="$LIBS"
2198 LIBS="-lnsl $LIBS"
2199 cat > conftest.$ac_ext <<EOF
2200 #line 2201 "configure"
2201 #include "confdefs.h"
2202 /* Override any gcc2 internal prototype to avoid an error. */
2203 /* We use char because int might match the return type of a gcc2
2204 builtin and then its argument prototype would still apply. */
2205 char gethostbyname();
2206
2207 int main() {
2208 gethostbyname()
2209 ; return 0; }
2210 EOF
2211 if { (eval echo configure:2212: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2212 rm -rf conftest*
2213 eval "ac_cv_lib_$ac_lib_var=yes"
2214 else
2215 echo "configure: failed program was:" >&5
2216 cat conftest.$ac_ext >&5
2217 rm -rf conftest*
2218 eval "ac_cv_lib_$ac_lib_var=no"
2219 fi
2220 rm -f conftest*
2221 LIBS="$ac_save_LIBS"
2222
2223 fi
2224 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2225 echo "$ac_t""yes" 1>&6
2226 ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2227 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2228 cat >> confdefs.h <<EOF
2229 #define $ac_tr_lib 1
2230 EOF
2231
2232 LIBS="-lnsl $LIBS"
2233
2234 else
2235 echo "$ac_t""no" 1>&6
2236 fi
2237
2238 fi
2239 echo $ac_n "checking for connect""... $ac_c" 1>&6
2240 echo "configure:2241: checking for connect" >&5
2241 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
2242 echo $ac_n "(cached) $ac_c" 1>&6
2243 else
2244 cat > conftest.$ac_ext <<EOF
2245 #line 2246 "configure"
2246 #include "confdefs.h"
2247 /* System header to define __stub macros and hopefully few prototypes,
2248 which can conflict with char connect(); below. */
2249 #include <assert.h>
2250 /* Override any gcc2 internal prototype to avoid an error. */
2251 /* We use char because int might match the return type of a gcc2
2252 builtin and then its argument prototype would still apply. */
2253 char connect();
2254
2255 int main() {
2256
2257 /* The GNU C library defines this for functions which it implements
2258 to always fail with ENOSYS. Some functions are actually named
2259 something starting with __ and the normal name is an alias. */
2260 #if defined (__stub_connect) || defined (__stub___connect)
2261 choke me
2262 #else
2263 connect();
2264 #endif
2265
2266 ; return 0; }
2267 EOF
2268 if { (eval echo configure:2269: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2269 rm -rf conftest*
2270 eval "ac_cv_func_connect=yes"
2271 else
2272 echo "configure: failed program was:" >&5
2273 cat conftest.$ac_ext >&5
2274 rm -rf conftest*
2275 eval "ac_cv_func_connect=no"
2276 fi
2277 rm -f conftest*
2278 fi
2279
2280 if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
2281 echo "$ac_t""yes" 1>&6
2282 :
2283 else
2284 echo "$ac_t""no" 1>&6
2285 fi
2286
2287 if test $ac_cv_func_connect = no; then
2288 echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
2289 echo "configure:2290: checking for connect in -lsocket" >&5
2290 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
2291 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2292 echo $ac_n "(cached) $ac_c" 1>&6
2293 else
2294 ac_save_LIBS="$LIBS"
2295 LIBS="-lsocket $LIBS"
2296 cat > conftest.$ac_ext <<EOF
2297 #line 2298 "configure"
2298 #include "confdefs.h"
2299 /* Override any gcc2 internal prototype to avoid an error. */
2300 /* We use char because int might match the return type of a gcc2
2301 builtin and then its argument prototype would still apply. */
2302 char connect();
2303
2304 int main() {
2305 connect()
2306 ; return 0; }
2307 EOF
2308 if { (eval echo configure:2309: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2309 rm -rf conftest*
2310 eval "ac_cv_lib_$ac_lib_var=yes"
2311 else
2312 echo "configure: failed program was:" >&5
2313 cat conftest.$ac_ext >&5
2314 rm -rf conftest*
2315 eval "ac_cv_lib_$ac_lib_var=no"
2316 fi
2317 rm -f conftest*
2318 LIBS="$ac_save_LIBS"
2319
2320 fi
2321 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2322 echo "$ac_t""yes" 1>&6
2323 ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2324 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2325 cat >> confdefs.h <<EOF
2326 #define $ac_tr_lib 1
2327 EOF
2328
2329 LIBS="-lsocket $LIBS"
2330
2331 else
2332 echo "$ac_t""no" 1>&6
2333 fi
2334
2335 fi
2336
2337 # Checks for dynamic linking
2338
2339 if test "$enable_dynamic_linking" = "yes"; then
2340
2341 echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
2342 echo "configure:2343: checking for dlopen in -ldl" >&5
2343 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
2344 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2345 echo $ac_n "(cached) $ac_c" 1>&6
2346 else
2347 ac_save_LIBS="$LIBS"
2348 LIBS="-ldl $LIBS"
2349 cat > conftest.$ac_ext <<EOF
2350 #line 2351 "configure"
2351 #include "confdefs.h"
2352 /* Override any gcc2 internal prototype to avoid an error. */
2353 /* We use char because int might match the return type of a gcc2
2354 builtin and then its argument prototype would still apply. */
2355 char dlopen();
2356
2357 int main() {
2358 dlopen()
2359 ; return 0; }
2360 EOF
2361 if { (eval echo configure:2362: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2362 rm -rf conftest*
2363 eval "ac_cv_lib_$ac_lib_var=yes"
2364 else
2365 echo "configure: failed program was:" >&5
2366 cat conftest.$ac_ext >&5
2367 rm -rf conftest*
2368 eval "ac_cv_lib_$ac_lib_var=no"
2369 fi
2370 rm -f conftest*
2371 LIBS="$ac_save_LIBS"
2372
2373 fi
2374 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2375 echo "$ac_t""yes" 1>&6
2376 ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2377 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2378 cat >> confdefs.h <<EOF
2379 #define $ac_tr_lib 1
2380 EOF
2381
2382 LIBS="-ldl $LIBS"
2383
2384 else
2385 echo "$ac_t""no" 1>&6
2386 fi
2387
2388 if test "$ac_cv_lib_dl_dlopen" = "yes"; then
2389 cat >> confdefs.h <<\EOF
2390 #define DYNAMIC_LINKING 1
2391 EOF
2392
2393 else
2394 echo $ac_n "checking for dld_link in -ldld""... $ac_c" 1>&6
2395 echo "configure:2396: checking for dld_link in -ldld" >&5
2396 ac_lib_var=`echo dld'_'dld_link | sed 'y%./+-%__p_%'`
2397 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2398 echo $ac_n "(cached) $ac_c" 1>&6
2399 else
2400 ac_save_LIBS="$LIBS"
2401 LIBS="-ldld $LIBS"
2402 cat > conftest.$ac_ext <<EOF
2403 #line 2404 "configure"
2404 #include "confdefs.h"
2405 /* Override any gcc2 internal prototype to avoid an error. */
2406 /* We use char because int might match the return type of a gcc2
2407 builtin and then its argument prototype would still apply. */
2408 char dld_link();
2409
2410 int main() {
2411 dld_link()
2412 ; return 0; }
2413 EOF
2414 if { (eval echo configure:2415: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2415 rm -rf conftest*
2416 eval "ac_cv_lib_$ac_lib_var=yes"
2417 else
2418 echo "configure: failed program was:" >&5
2419 cat conftest.$ac_ext >&5
2420 rm -rf conftest*
2421 eval "ac_cv_lib_$ac_lib_var=no"
2422 fi
2423 rm -f conftest*
2424 LIBS="$ac_save_LIBS"
2425
2426 fi
2427 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2428 echo "$ac_t""yes" 1>&6
2429 ac_tr_lib=HAVE_LIB`echo dld | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2430 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2431 cat >> confdefs.h <<EOF
2432 #define $ac_tr_lib 1
2433 EOF
2434
2435 LIBS="-ldld $LIBS"
2436
2437 else
2438 echo "$ac_t""no" 1>&6
2439 fi
2440
2441 if test "$ac_cv_lib_dld_dld_link" = "yes"; then
2442 cat >> confdefs.h <<\EOF
2443 #define DYNAMIC_LINKING 1
2444 EOF
2445
2446 else
2447 for ac_func in shl_load
2448 do
2449 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2450 echo "configure:2451: checking for $ac_func" >&5
2451 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2452 echo $ac_n "(cached) $ac_c" 1>&6
2453 else
2454 cat > conftest.$ac_ext <<EOF
2455 #line 2456 "configure"
2456 #include "confdefs.h"
2457 /* System header to define __stub macros and hopefully few prototypes,
2458 which can conflict with char $ac_func(); below. */
2459 #include <assert.h>
2460 /* Override any gcc2 internal prototype to avoid an error. */
2461 /* We use char because int might match the return type of a gcc2
2462 builtin and then its argument prototype would still apply. */
2463 char $ac_func();
2464
2465 int main() {
2466
2467 /* The GNU C library defines this for functions which it implements
2468 to always fail with ENOSYS. Some functions are actually named
2469 something starting with __ and the normal name is an alias. */
2470 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2471 choke me
2472 #else
2473 $ac_func();
2474 #endif
2475
2476 ; return 0; }
2477 EOF
2478 if { (eval echo configure:2479: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2479 rm -rf conftest*
2480 eval "ac_cv_func_$ac_func=yes"
2481 else
2482 echo "configure: failed program was:" >&5
2483 cat conftest.$ac_ext >&5
2484 rm -rf conftest*
2485 eval "ac_cv_func_$ac_func=no"
2486 fi
2487 rm -f conftest*
2488 fi
2489
2490 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2491 echo "$ac_t""yes" 1>&6
2492 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2493 cat >> confdefs.h <<EOF
2494 #define $ac_tr_func 1
2495 EOF
2496
2497 else
2498 echo "$ac_t""no" 1>&6
2499 fi
2500 done
2501
2502 if test "$ac_cv_func_shl_load" = "yes"; then
2503 cat >> confdefs.h <<\EOF
2504 #define DYNAMIC_LINKING 1
2505 EOF
2506
2507 fi
2508 fi
2509 fi
2510
2511 fi
2512
2513
2514 for ac_func in ctermid ftime getcwd geteuid gethostent gettimeofday lstat mkdir mknod nice readlink rename rmdir select setegid seteuid setlocale setpgid setsid sigaction strftime strptime symlink sync tcgetpgrp tcsetpgrp times uname waitpid
2515 do
2516 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2517 echo "configure:2518: checking for $ac_func" >&5
2518 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2519 echo $ac_n "(cached) $ac_c" 1>&6
2520 else
2521 cat > conftest.$ac_ext <<EOF
2522 #line 2523 "configure"
2523 #include "confdefs.h"
2524 /* System header to define __stub macros and hopefully few prototypes,
2525 which can conflict with char $ac_func(); below. */
2526 #include <assert.h>
2527 /* Override any gcc2 internal prototype to avoid an error. */
2528 /* We use char because int might match the return type of a gcc2
2529 builtin and then its argument prototype would still apply. */
2530 char $ac_func();
2531
2532 int main() {
2533
2534 /* The GNU C library defines this for functions which it implements
2535 to always fail with ENOSYS. Some functions are actually named
2536 something starting with __ and the normal name is an alias. */
2537 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2538 choke me
2539 #else
2540 $ac_func();
2541 #endif
2542
2543 ; return 0; }
2544 EOF
2545 if { (eval echo configure:2546: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2546 rm -rf conftest*
2547 eval "ac_cv_func_$ac_func=yes"
2548 else
2549 echo "configure: failed program was:" >&5
2550 cat conftest.$ac_ext >&5
2551 rm -rf conftest*
2552 eval "ac_cv_func_$ac_func=no"
2553 fi
2554 rm -f conftest*
2555 fi
2556
2557 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2558 echo "$ac_t""yes" 1>&6
2559 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2560 cat >> confdefs.h <<EOF
2561 #define $ac_tr_func 1
2562 EOF
2563
2564 else
2565 echo "$ac_t""no" 1>&6
2566 fi
2567 done
2568
2569
2570
2571 ac_safe=`echo "sys/un.h" | sed 'y%./+-%__p_%'`
2572 echo $ac_n "checking for sys/un.h""... $ac_c" 1>&6
2573 echo "configure:2574: checking for sys/un.h" >&5
2574 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2575 echo $ac_n "(cached) $ac_c" 1>&6
2576 else
2577 cat > conftest.$ac_ext <<EOF
2578 #line 2579 "configure"
2579 #include "confdefs.h"
2580 #include <sys/un.h>
2581 EOF
2582 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2583 { (eval echo configure:2584: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2584 ac_err=`grep -v '^ *+' conftest.out`
2585 if test -z "$ac_err"; then
2586 rm -rf conftest*
2587 eval "ac_cv_header_$ac_safe=yes"
2588 else
2589 echo "$ac_err" >&5
2590 echo "configure: failed program was:" >&5
2591 cat conftest.$ac_ext >&5
2592 rm -rf conftest*
2593 eval "ac_cv_header_$ac_safe=no"
2594 fi
2595 rm -f conftest*
2596 fi
2597 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2598 echo "$ac_t""yes" 1>&6
2599 have_sys_un_h=1
2600 else
2601 echo "$ac_t""no" 1>&6
2602 fi
2603
2604 if test -n "$have_sys_un_h" ; then
2605 cat >> confdefs.h <<\EOF
2606 #define HAVE_UNIX_DOMAIN_SOCKETS 1
2607 EOF
2608
2609 fi
2610
2611 for ac_func in socketpair getgroups setpwent pause tzset
2612 do
2613 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2614 echo "configure:2615: checking for $ac_func" >&5
2615 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2616 echo $ac_n "(cached) $ac_c" 1>&6
2617 else
2618 cat > conftest.$ac_ext <<EOF
2619 #line 2620 "configure"
2620 #include "confdefs.h"
2621 /* System header to define __stub macros and hopefully few prototypes,
2622 which can conflict with char $ac_func(); below. */
2623 #include <assert.h>
2624 /* Override any gcc2 internal prototype to avoid an error. */
2625 /* We use char because int might match the return type of a gcc2
2626 builtin and then its argument prototype would still apply. */
2627 char $ac_func();
2628
2629 int main() {
2630
2631 /* The GNU C library defines this for functions which it implements
2632 to always fail with ENOSYS. Some functions are actually named
2633 something starting with __ and the normal name is an alias. */
2634 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2635 choke me
2636 #else
2637 $ac_func();
2638 #endif
2639
2640 ; return 0; }
2641 EOF
2642 if { (eval echo configure:2643: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2643 rm -rf conftest*
2644 eval "ac_cv_func_$ac_func=yes"
2645 else
2646 echo "configure: failed program was:" >&5
2647 cat conftest.$ac_ext >&5
2648 rm -rf conftest*
2649 eval "ac_cv_func_$ac_func=no"
2650 fi
2651 rm -f conftest*
2652 fi
2653
2654 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2655 echo "$ac_t""yes" 1>&6
2656 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2657 cat >> confdefs.h <<EOF
2658 #define $ac_tr_func 1
2659 EOF
2660
2661 else
2662 echo "$ac_t""no" 1>&6
2663 fi
2664 done
2665
2666
2667
2668
2669
2670 for ac_func in sethostent endhostent getnetent setnetent endnetent getprotoent endprotoent getservent endservent getnetbyaddr getnetbyname inet_lnaof inet_makeaddr inet_netof
2671 do
2672 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2673 echo "configure:2674: checking for $ac_func" >&5
2674 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2675 echo $ac_n "(cached) $ac_c" 1>&6
2676 else
2677 cat > conftest.$ac_ext <<EOF
2678 #line 2679 "configure"
2679 #include "confdefs.h"
2680 /* System header to define __stub macros and hopefully few prototypes,
2681 which can conflict with char $ac_func(); below. */
2682 #include <assert.h>
2683 /* Override any gcc2 internal prototype to avoid an error. */
2684 /* We use char because int might match the return type of a gcc2
2685 builtin and then its argument prototype would still apply. */
2686 char $ac_func();
2687
2688 int main() {
2689
2690 /* The GNU C library defines this for functions which it implements
2691 to always fail with ENOSYS. Some functions are actually named
2692 something starting with __ and the normal name is an alias. */
2693 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2694 choke me
2695 #else
2696 $ac_func();
2697 #endif
2698
2699 ; return 0; }
2700 EOF
2701 if { (eval echo configure:2702: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2702 rm -rf conftest*
2703 eval "ac_cv_func_$ac_func=yes"
2704 else
2705 echo "configure: failed program was:" >&5
2706 cat conftest.$ac_ext >&5
2707 rm -rf conftest*
2708 eval "ac_cv_func_$ac_func=no"
2709 fi
2710 rm -f conftest*
2711 fi
2712
2713 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2714 echo "$ac_t""yes" 1>&6
2715 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2716 cat >> confdefs.h <<EOF
2717 #define $ac_tr_func 1
2718 EOF
2719
2720 else
2721 echo "$ac_t""no" 1>&6
2722 fi
2723 done
2724
2725
2726
2727 echo $ac_n "checking for restartable system calls""... $ac_c" 1>&6
2728 echo "configure:2729: checking for restartable system calls" >&5
2729 if eval "test \"`echo '$''{'scm_cv_restarts'+set}'`\" = set"; then
2730 echo $ac_n "(cached) $ac_c" 1>&6
2731 else
2732 if test $ac_cv_func_sigaction = yes; then
2733 cat > conftest.$ac_ext <<EOF
2734 #line 2735 "configure"
2735 #include "confdefs.h"
2736 #include <signal.h>
2737 int main() {
2738 int a = SA_RESTART
2739 ; return 0; }
2740 EOF
2741 if { (eval echo configure:2742: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2742 rm -rf conftest*
2743 scm_cv_restarts=yes
2744 else
2745 echo "configure: failed program was:" >&5
2746 cat conftest.$ac_ext >&5
2747 rm -rf conftest*
2748 scm_cv_restarts=no
2749 fi
2750 rm -f conftest*
2751 else
2752 scm_cv_restarts=no
2753 fi
2754 fi
2755
2756 echo "$ac_t""$scm_cv_restarts" 1>&6
2757 if test $scm_cv_restarts = yes; then
2758 cat >> confdefs.h <<\EOF
2759 #define HAVE_RESTARTS 1
2760 EOF
2761
2762 fi
2763
2764 if test "$ac_cv_header_regex_h" = yes; then
2765 for ac_func in regcomp
2766 do
2767 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2768 echo "configure:2769: checking for $ac_func" >&5
2769 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2770 echo $ac_n "(cached) $ac_c" 1>&6
2771 else
2772 cat > conftest.$ac_ext <<EOF
2773 #line 2774 "configure"
2774 #include "confdefs.h"
2775 /* System header to define __stub macros and hopefully few prototypes,
2776 which can conflict with char $ac_func(); below. */
2777 #include <assert.h>
2778 /* Override any gcc2 internal prototype to avoid an error. */
2779 /* We use char because int might match the return type of a gcc2
2780 builtin and then its argument prototype would still apply. */
2781 char $ac_func();
2782
2783 int main() {
2784
2785 /* The GNU C library defines this for functions which it implements
2786 to always fail with ENOSYS. Some functions are actually named
2787 something starting with __ and the normal name is an alias. */
2788 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2789 choke me
2790 #else
2791 $ac_func();
2792 #endif
2793
2794 ; return 0; }
2795 EOF
2796 if { (eval echo configure:2797: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2797 rm -rf conftest*
2798 eval "ac_cv_func_$ac_func=yes"
2799 else
2800 echo "configure: failed program was:" >&5
2801 cat conftest.$ac_ext >&5
2802 rm -rf conftest*
2803 eval "ac_cv_func_$ac_func=no"
2804 fi
2805 rm -f conftest*
2806 fi
2807
2808 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2809 echo "$ac_t""yes" 1>&6
2810 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2811 cat >> confdefs.h <<EOF
2812 #define $ac_tr_func 1
2813 EOF
2814 LIBOBJS="regex-posix.o $LIBOBJS"
2815 else
2816 echo "$ac_t""no" 1>&6
2817 fi
2818 done
2819
2820 fi
2821
2822 for ac_func in inet_aton putenv strerror
2823 do
2824 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2825 echo "configure:2826: checking for $ac_func" >&5
2826 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2827 echo $ac_n "(cached) $ac_c" 1>&6
2828 else
2829 cat > conftest.$ac_ext <<EOF
2830 #line 2831 "configure"
2831 #include "confdefs.h"
2832 /* System header to define __stub macros and hopefully few prototypes,
2833 which can conflict with char $ac_func(); below. */
2834 #include <assert.h>
2835 /* Override any gcc2 internal prototype to avoid an error. */
2836 /* We use char because int might match the return type of a gcc2
2837 builtin and then its argument prototype would still apply. */
2838 char $ac_func();
2839
2840 int main() {
2841
2842 /* The GNU C library defines this for functions which it implements
2843 to always fail with ENOSYS. Some functions are actually named
2844 something starting with __ and the normal name is an alias. */
2845 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2846 choke me
2847 #else
2848 $ac_func();
2849 #endif
2850
2851 ; return 0; }
2852 EOF
2853 if { (eval echo configure:2854: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2854 rm -rf conftest*
2855 eval "ac_cv_func_$ac_func=yes"
2856 else
2857 echo "configure: failed program was:" >&5
2858 cat conftest.$ac_ext >&5
2859 rm -rf conftest*
2860 eval "ac_cv_func_$ac_func=no"
2861 fi
2862 rm -f conftest*
2863 fi
2864
2865 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2866 echo "$ac_t""yes" 1>&6
2867 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2868 cat >> confdefs.h <<EOF
2869 #define $ac_tr_func 1
2870 EOF
2871
2872 else
2873 echo "$ac_t""no" 1>&6
2874 LIBOBJS="$LIBOBJS ${ac_func}.o"
2875 fi
2876 done
2877
2878
2879
2880 # When testing for the presence of alloca, we need to add alloca.o
2881 # explicitly to LIBOBJS to make sure that it is translated to
2882 # `alloca.lo' for libtool later on. This can and should be done more cleanly.
2883 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
2884 # for constant arguments. Useless!
2885 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
2886 echo "configure:2887: checking for working alloca.h" >&5
2887 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
2888 echo $ac_n "(cached) $ac_c" 1>&6
2889 else
2890 cat > conftest.$ac_ext <<EOF
2891 #line 2892 "configure"
2892 #include "confdefs.h"
2893 #include <alloca.h>
2894 int main() {
2895 char *p = alloca(2 * sizeof(int));
2896 ; return 0; }
2897 EOF
2898 if { (eval echo configure:2899: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2899 rm -rf conftest*
2900 ac_cv_header_alloca_h=yes
2901 else
2902 echo "configure: failed program was:" >&5
2903 cat conftest.$ac_ext >&5
2904 rm -rf conftest*
2905 ac_cv_header_alloca_h=no
2906 fi
2907 rm -f conftest*
2908 fi
2909
2910 echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
2911 if test $ac_cv_header_alloca_h = yes; then
2912 cat >> confdefs.h <<\EOF
2913 #define HAVE_ALLOCA_H 1
2914 EOF
2915
2916 fi
2917
2918 echo $ac_n "checking for alloca""... $ac_c" 1>&6
2919 echo "configure:2920: checking for alloca" >&5
2920 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
2921 echo $ac_n "(cached) $ac_c" 1>&6
2922 else
2923 cat > conftest.$ac_ext <<EOF
2924 #line 2925 "configure"
2925 #include "confdefs.h"
2926
2927 #ifdef __GNUC__
2928 # define alloca __builtin_alloca
2929 #else
2930 # if HAVE_ALLOCA_H
2931 # include <alloca.h>
2932 # else
2933 # ifdef _AIX
2934 #pragma alloca
2935 # else
2936 # ifndef alloca /* predefined by HP cc +Olibcalls */
2937 char *alloca ();
2938 # endif
2939 # endif
2940 # endif
2941 #endif
2942
2943 int main() {
2944 char *p = (char *) alloca(1);
2945 ; return 0; }
2946 EOF
2947 if { (eval echo configure:2948: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2948 rm -rf conftest*
2949 ac_cv_func_alloca_works=yes
2950 else
2951 echo "configure: failed program was:" >&5
2952 cat conftest.$ac_ext >&5
2953 rm -rf conftest*
2954 ac_cv_func_alloca_works=no
2955 fi
2956 rm -f conftest*
2957 fi
2958
2959 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
2960 if test $ac_cv_func_alloca_works = yes; then
2961 cat >> confdefs.h <<\EOF
2962 #define HAVE_ALLOCA 1
2963 EOF
2964
2965 fi
2966
2967 if test $ac_cv_func_alloca_works = no; then
2968 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
2969 # that cause trouble. Some versions do not even contain alloca or
2970 # contain a buggy version. If you still want to use their alloca,
2971 # use ar to extract alloca.o from them instead of compiling alloca.c.
2972 ALLOCA=alloca.o
2973 cat >> confdefs.h <<\EOF
2974 #define C_ALLOCA 1
2975 EOF
2976
2977
2978 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
2979 echo "configure:2980: checking whether alloca needs Cray hooks" >&5
2980 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
2981 echo $ac_n "(cached) $ac_c" 1>&6
2982 else
2983 cat > conftest.$ac_ext <<EOF
2984 #line 2985 "configure"
2985 #include "confdefs.h"
2986 #if defined(CRAY) && ! defined(CRAY2)
2987 webecray
2988 #else
2989 wenotbecray
2990 #endif
2991
2992 EOF
2993 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2994 egrep "webecray" >/dev/null 2>&1; then
2995 rm -rf conftest*
2996 ac_cv_os_cray=yes
2997 else
2998 rm -rf conftest*
2999 ac_cv_os_cray=no
3000 fi
3001 rm -f conftest*
3002
3003 fi
3004
3005 echo "$ac_t""$ac_cv_os_cray" 1>&6
3006 if test $ac_cv_os_cray = yes; then
3007 for ac_func in _getb67 GETB67 getb67; do
3008 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3009 echo "configure:3010: checking for $ac_func" >&5
3010 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3011 echo $ac_n "(cached) $ac_c" 1>&6
3012 else
3013 cat > conftest.$ac_ext <<EOF
3014 #line 3015 "configure"
3015 #include "confdefs.h"
3016 /* System header to define __stub macros and hopefully few prototypes,
3017 which can conflict with char $ac_func(); below. */
3018 #include <assert.h>
3019 /* Override any gcc2 internal prototype to avoid an error. */
3020 /* We use char because int might match the return type of a gcc2
3021 builtin and then its argument prototype would still apply. */
3022 char $ac_func();
3023
3024 int main() {
3025
3026 /* The GNU C library defines this for functions which it implements
3027 to always fail with ENOSYS. Some functions are actually named
3028 something starting with __ and the normal name is an alias. */
3029 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3030 choke me
3031 #else
3032 $ac_func();
3033 #endif
3034
3035 ; return 0; }
3036 EOF
3037 if { (eval echo configure:3038: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
3038 rm -rf conftest*
3039 eval "ac_cv_func_$ac_func=yes"
3040 else
3041 echo "configure: failed program was:" >&5
3042 cat conftest.$ac_ext >&5
3043 rm -rf conftest*
3044 eval "ac_cv_func_$ac_func=no"
3045 fi
3046 rm -f conftest*
3047 fi
3048
3049 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3050 echo "$ac_t""yes" 1>&6
3051 cat >> confdefs.h <<EOF
3052 #define CRAY_STACKSEG_END $ac_func
3053 EOF
3054
3055 break
3056 else
3057 echo "$ac_t""no" 1>&6
3058 fi
3059
3060 done
3061 fi
3062
3063 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
3064 echo "configure:3065: checking stack direction for C alloca" >&5
3065 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
3066 echo $ac_n "(cached) $ac_c" 1>&6
3067 else
3068 if test "$cross_compiling" = yes; then
3069 ac_cv_c_stack_direction=0
3070 else
3071 cat > conftest.$ac_ext <<EOF
3072 #line 3073 "configure"
3073 #include "confdefs.h"
3074 find_stack_direction ()
3075 {
3076 static char *addr = 0;
3077 auto char dummy;
3078 if (addr == 0)
3079 {
3080 addr = &dummy;
3081 return find_stack_direction ();
3082 }
3083 else
3084 return (&dummy > addr) ? 1 : -1;
3085 }
3086 main ()
3087 {
3088 exit (find_stack_direction() < 0);
3089 }
3090 EOF
3091 if { (eval echo configure:3092: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
3092 then
3093 ac_cv_c_stack_direction=1
3094 else
3095 echo "configure: failed program was:" >&5
3096 cat conftest.$ac_ext >&5
3097 rm -fr conftest*
3098 ac_cv_c_stack_direction=-1
3099 fi
3100 rm -fr conftest*
3101 fi
3102
3103 fi
3104
3105 echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
3106 cat >> confdefs.h <<EOF
3107 #define STACK_DIRECTION $ac_cv_c_stack_direction
3108 EOF
3109
3110 fi
3111
3112 if test "$ALLOCA" = "alloca.o"; then LIBOBJS="alloca.o $LIBOBJS"; fi
3113
3114 echo $ac_n "checking for st_rdev in struct stat""... $ac_c" 1>&6
3115 echo "configure:3116: checking for st_rdev in struct stat" >&5
3116 if eval "test \"`echo '$''{'ac_cv_struct_st_rdev'+set}'`\" = set"; then
3117 echo $ac_n "(cached) $ac_c" 1>&6
3118 else
3119 cat > conftest.$ac_ext <<EOF
3120 #line 3121 "configure"
3121 #include "confdefs.h"
3122 #include <sys/types.h>
3123 #include <sys/stat.h>
3124 int main() {
3125 struct stat s; s.st_rdev;
3126 ; return 0; }
3127 EOF
3128 if { (eval echo configure:3129: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3129 rm -rf conftest*
3130 ac_cv_struct_st_rdev=yes
3131 else
3132 echo "configure: failed program was:" >&5
3133 cat conftest.$ac_ext >&5
3134 rm -rf conftest*
3135 ac_cv_struct_st_rdev=no
3136 fi
3137 rm -f conftest*
3138 fi
3139
3140 echo "$ac_t""$ac_cv_struct_st_rdev" 1>&6
3141 if test $ac_cv_struct_st_rdev = yes; then
3142 cat >> confdefs.h <<\EOF
3143 #define HAVE_ST_RDEV 1
3144 EOF
3145
3146 fi
3147
3148 echo $ac_n "checking for st_blksize in struct stat""... $ac_c" 1>&6
3149 echo "configure:3150: checking for st_blksize in struct stat" >&5
3150 if eval "test \"`echo '$''{'ac_cv_struct_st_blksize'+set}'`\" = set"; then
3151 echo $ac_n "(cached) $ac_c" 1>&6
3152 else
3153 cat > conftest.$ac_ext <<EOF
3154 #line 3155 "configure"
3155 #include "confdefs.h"
3156 #include <sys/types.h>
3157 #include <sys/stat.h>
3158 int main() {
3159 struct stat s; s.st_blksize;
3160 ; return 0; }
3161 EOF
3162 if { (eval echo configure:3163: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3163 rm -rf conftest*
3164 ac_cv_struct_st_blksize=yes
3165 else
3166 echo "configure: failed program was:" >&5
3167 cat conftest.$ac_ext >&5
3168 rm -rf conftest*
3169 ac_cv_struct_st_blksize=no
3170 fi
3171 rm -f conftest*
3172 fi
3173
3174 echo "$ac_t""$ac_cv_struct_st_blksize" 1>&6
3175 if test $ac_cv_struct_st_blksize = yes; then
3176 cat >> confdefs.h <<\EOF
3177 #define HAVE_ST_BLKSIZE 1
3178 EOF
3179
3180 fi
3181
3182
3183 # We could use AC_STRUCT_ST_BLOCKS here, but that adds fileblocks.o to
3184 # LIBOBJS, which we don't need. This seems more direct.
3185 echo $ac_n "checking for st_blocks in struct stat""... $ac_c" 1>&6
3186 echo "configure:3187: checking for st_blocks in struct stat" >&5
3187 if eval "test \"`echo '$''{'ac_cv_struct_st_blocks'+set}'`\" = set"; then
3188 echo $ac_n "(cached) $ac_c" 1>&6
3189 else
3190 cat > conftest.$ac_ext <<EOF
3191 #line 3192 "configure"
3192 #include "confdefs.h"
3193 #include <sys/types.h>
3194 #include <sys/stat.h>
3195 int main() {
3196 struct stat s; s.st_blocks;
3197 ; return 0; }
3198 EOF
3199 if { (eval echo configure:3200: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3200 rm -rf conftest*
3201 ac_cv_struct_st_blocks=yes
3202 else
3203 echo "configure: failed program was:" >&5
3204 cat conftest.$ac_ext >&5
3205 rm -rf conftest*
3206 ac_cv_struct_st_blocks=no
3207 fi
3208 rm -f conftest*
3209 fi
3210
3211 echo "$ac_t""$ac_cv_struct_st_blocks" 1>&6
3212 if test $ac_cv_struct_st_blocks = yes; then
3213 cat >> confdefs.h <<\EOF
3214 #define HAVE_ST_BLOCKS 1
3215 EOF
3216
3217 fi
3218
3219 echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
3220 echo "configure:3221: checking whether struct tm is in sys/time.h or time.h" >&5
3221 if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
3222 echo $ac_n "(cached) $ac_c" 1>&6
3223 else
3224 cat > conftest.$ac_ext <<EOF
3225 #line 3226 "configure"
3226 #include "confdefs.h"
3227 #include <sys/types.h>
3228 #include <time.h>
3229 int main() {
3230 struct tm *tp; tp->tm_sec;
3231 ; return 0; }
3232 EOF
3233 if { (eval echo configure:3234: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3234 rm -rf conftest*
3235 ac_cv_struct_tm=time.h
3236 else
3237 echo "configure: failed program was:" >&5
3238 cat conftest.$ac_ext >&5
3239 rm -rf conftest*
3240 ac_cv_struct_tm=sys/time.h
3241 fi
3242 rm -f conftest*
3243 fi
3244
3245 echo "$ac_t""$ac_cv_struct_tm" 1>&6
3246 if test $ac_cv_struct_tm = sys/time.h; then
3247 cat >> confdefs.h <<\EOF
3248 #define TM_IN_SYS_TIME 1
3249 EOF
3250
3251 fi
3252
3253 echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6
3254 echo "configure:3255: checking for tm_zone in struct tm" >&5
3255 if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then
3256 echo $ac_n "(cached) $ac_c" 1>&6
3257 else
3258 cat > conftest.$ac_ext <<EOF
3259 #line 3260 "configure"
3260 #include "confdefs.h"
3261 #include <sys/types.h>
3262 #include <$ac_cv_struct_tm>
3263 int main() {
3264 struct tm tm; tm.tm_zone;
3265 ; return 0; }
3266 EOF
3267 if { (eval echo configure:3268: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3268 rm -rf conftest*
3269 ac_cv_struct_tm_zone=yes
3270 else
3271 echo "configure: failed program was:" >&5
3272 cat conftest.$ac_ext >&5
3273 rm -rf conftest*
3274 ac_cv_struct_tm_zone=no
3275 fi
3276 rm -f conftest*
3277 fi
3278
3279 echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6
3280 if test "$ac_cv_struct_tm_zone" = yes; then
3281 cat >> confdefs.h <<\EOF
3282 #define HAVE_TM_ZONE 1
3283 EOF
3284
3285 else
3286 echo $ac_n "checking for tzname""... $ac_c" 1>&6
3287 echo "configure:3288: checking for tzname" >&5
3288 if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then
3289 echo $ac_n "(cached) $ac_c" 1>&6
3290 else
3291 cat > conftest.$ac_ext <<EOF
3292 #line 3293 "configure"
3293 #include "confdefs.h"
3294 #include <time.h>
3295 #ifndef tzname /* For SGI. */
3296 extern char *tzname[]; /* RS6000 and others reject char **tzname. */
3297 #endif
3298 int main() {
3299 atoi(*tzname);
3300 ; return 0; }
3301 EOF
3302 if { (eval echo configure:3303: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
3303 rm -rf conftest*
3304 ac_cv_var_tzname=yes
3305 else
3306 echo "configure: failed program was:" >&5
3307 cat conftest.$ac_ext >&5
3308 rm -rf conftest*
3309 ac_cv_var_tzname=no
3310 fi
3311 rm -f conftest*
3312 fi
3313
3314 echo "$ac_t""$ac_cv_var_tzname" 1>&6
3315 if test $ac_cv_var_tzname = yes; then
3316 cat >> confdefs.h <<\EOF
3317 #define HAVE_TZNAME 1
3318 EOF
3319
3320 fi
3321 fi
3322
3323
3324 echo $ac_n "checking whether we need POSIX to get struct utimbuf""... $ac_c" 1>&6
3325 echo "configure:3326: checking whether we need POSIX to get struct utimbuf" >&5
3326 if eval "test \"`echo '$''{'guile_cv_struct_utimbuf_needs_posix'+set}'`\" = set"; then
3327 echo $ac_n "(cached) $ac_c" 1>&6
3328 else
3329 cat > conftest.$ac_ext <<EOF
3330 #line 3331 "configure"
3331 #include "confdefs.h"
3332
3333 #ifdef __EMX__
3334 #include <sys/utime.h>
3335 #else
3336 #include <utime.h>
3337 #endif
3338 struct utime blah;
3339
3340 EOF
3341 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3342 { (eval echo configure:3343: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3343 ac_err=`grep -v '^ *+' conftest.out`
3344 if test -z "$ac_err"; then
3345 rm -rf conftest*
3346 guile_cv_struct_utimbuf_needs_posix=no
3347 else
3348 echo "$ac_err" >&5
3349 echo "configure: failed program was:" >&5
3350 cat conftest.$ac_ext >&5
3351 rm -rf conftest*
3352 guile_cv_struct_utimbuf_needs_posix=yes
3353 fi
3354 rm -f conftest*
3355 fi
3356
3357 echo "$ac_t""$guile_cv_struct_utimbuf_needs_posix" 1>&6
3358 if test "$guile_cv_struct_utimbuf_needs_posix" = yes; then
3359 cat >> confdefs.h <<\EOF
3360 #define UTIMBUF_NEEDS_POSIX 1
3361 EOF
3362
3363 fi
3364
3365 #--------------------------------------------------------------------
3366 #
3367 # Which way does the stack grow?
3368 #
3369 #--------------------------------------------------------------------
3370
3371 if test "$cross_compiling" = yes; then
3372 echo "configure: warning: Guessing that stack grows down -- see scmconfig.h.in" 1>&2
3373 else
3374 cat > conftest.$ac_ext <<EOF
3375 #line 3376 "configure"
3376 #include "confdefs.h"
3377 aux (l) unsigned long l;
3378 { int x; exit (l >= ((unsigned long)&x)); }
3379 main () { int q; aux((unsigned long)&q); }
3380 EOF
3381 if { (eval echo configure:3382: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
3382 then
3383 cat >> confdefs.h <<\EOF
3384 #define SCM_STACK_GROWS_UP 1
3385 EOF
3386
3387 else
3388 echo "configure: failed program was:" >&5
3389 cat conftest.$ac_ext >&5
3390 fi
3391 rm -fr conftest*
3392 fi
3393
3394
3395
3396 if test "$cross_compiling" = yes; then
3397 cat >> confdefs.h <<\EOF
3398 #define SCM_SINGLES 1
3399 EOF
3400
3401 echo "configure: warning: Guessing that sizeof(long) == sizeof(float) -- see scmconfig.h.in" 1>&2
3402 else
3403 cat > conftest.$ac_ext <<EOF
3404 #line 3405 "configure"
3405 #include "confdefs.h"
3406 main () { exit (sizeof(float) != sizeof(long)); }
3407 EOF
3408 if { (eval echo configure:3409: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
3409 then
3410 cat >> confdefs.h <<\EOF
3411 #define SCM_SINGLES 1
3412 EOF
3413
3414 else
3415 echo "configure: failed program was:" >&5
3416 cat conftest.$ac_ext >&5
3417 fi
3418 rm -fr conftest*
3419 fi
3420
3421
3422 echo $ac_n "checking for struct linger""... $ac_c" 1>&6
3423 echo "configure:3424: checking for struct linger" >&5
3424 if eval "test \"`echo '$''{'scm_cv_struct_linger'+set}'`\" = set"; then
3425 echo $ac_n "(cached) $ac_c" 1>&6
3426 else
3427 cat > conftest.$ac_ext <<EOF
3428 #line 3429 "configure"
3429 #include "confdefs.h"
3430
3431 #include <sys/types.h>
3432 #include <sys/socket.h>
3433 int main() {
3434 struct linger lgr; lgr.l_linger = 100
3435 ; return 0; }
3436 EOF
3437 if { (eval echo configure:3438: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3438 rm -rf conftest*
3439 scm_cv_struct_linger="yes"
3440 else
3441 echo "configure: failed program was:" >&5
3442 cat conftest.$ac_ext >&5
3443 rm -rf conftest*
3444 scm_cv_struct_linger="no"
3445 fi
3446 rm -f conftest*
3447 fi
3448
3449 echo "$ac_t""$scm_cv_struct_linger" 1>&6
3450 if test $scm_cv_struct_linger = yes; then
3451 cat >> confdefs.h <<\EOF
3452 #define HAVE_STRUCT_LINGER 1
3453 EOF
3454
3455 fi
3456
3457 #--------------------------------------------------------------------
3458 #
3459 # How can you violate a stdio abstraction by setting a stream's fd?
3460 #
3461 #--------------------------------------------------------------------
3462
3463 echo $ac_n "checking how to set a stream file descriptor""... $ac_c" 1>&6
3464 echo "configure:3465: checking how to set a stream file descriptor" >&5
3465 if eval "test \"`echo '$''{'scm_cv_fd_setter'+set}'`\" = set"; then
3466 echo $ac_n "(cached) $ac_c" 1>&6
3467 else
3468 cat > conftest.$ac_ext <<EOF
3469 #line 3470 "configure"
3470 #include "confdefs.h"
3471 #include <stdio.h>
3472 int main() {
3473 stdout->_file = 1
3474 ; return 0; }
3475 EOF
3476 if { (eval echo configure:3477: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3477 rm -rf conftest*
3478 scm_cv_fd_setter="_file"
3479 else
3480 echo "configure: failed program was:" >&5
3481 cat conftest.$ac_ext >&5
3482 rm -rf conftest*
3483 cat > conftest.$ac_ext <<EOF
3484 #line 3485 "configure"
3485 #include "confdefs.h"
3486 #include <stdio.h>
3487 int main() {
3488 stdout->_fileno = 1
3489 ; return 0; }
3490 EOF
3491 if { (eval echo configure:3492: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3492 rm -rf conftest*
3493 scm_cv_fd_setter="_fileno"
3494 else
3495 echo "configure: failed program was:" >&5
3496 cat conftest.$ac_ext >&5
3497 rm -rf conftest*
3498 scm_cv_fd_setter=""
3499 fi
3500 rm -f conftest*
3501 fi
3502 rm -f conftest*
3503 fi
3504
3505
3506 if test "$scm_cv_fd_setter"; then
3507 echo "$ac_t""$scm_cv_fd_setter" 1>&6
3508 cat >> confdefs.h <<EOF
3509 #define FD_SETTER $scm_cv_fd_setter
3510 EOF
3511
3512 else
3513 echo "$ac_t""we couldn't do it!" 1>&6
3514 fi
3515
3516 #--------------------------------------------------------------------
3517 # How to find out whether a FILE structure contains buffered data.
3518 # From Tk we have the following list:
3519 # _cnt: Most UNIX systems
3520 # __cnt: HPUX
3521 # _r: BSD
3522 # readCount: Sprite
3523 # Or, in GNU libc there are two fields, _gptr and _egptr, which
3524 # have to be compared.
3525 # These can also be known as _IO_read_ptr and _IO_read_end.
3526 #--------------------------------------------------------------------
3527
3528 echo $ac_n "checking how to get buffer char count from FILE structure""... $ac_c" 1>&6
3529 echo "configure:3530: checking how to get buffer char count from FILE structure" >&5
3530 if eval "test \"`echo '$''{'scm_cv_struct_file_count'+set}'`\" = set"; then
3531 echo $ac_n "(cached) $ac_c" 1>&6
3532 else
3533 cat > conftest.$ac_ext <<EOF
3534 #line 3535 "configure"
3535 #include "confdefs.h"
3536 #include <stdio.h>
3537 int main() {
3538 FILE *f = stdin; f->_cnt = 0
3539 ; return 0; }
3540 EOF
3541 if { (eval echo configure:3542: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3542 rm -rf conftest*
3543 scm_cv_struct_file_count="_cnt"
3544 else
3545 echo "configure: failed program was:" >&5
3546 cat conftest.$ac_ext >&5
3547 rm -rf conftest*
3548 cat > conftest.$ac_ext <<EOF
3549 #line 3550 "configure"
3550 #include "confdefs.h"
3551 #include <stdio.h>
3552 int main() {
3553 FILE *f = stdin; f->_r = 0
3554 ; return 0; }
3555 EOF
3556 if { (eval echo configure:3557: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3557 rm -rf conftest*
3558 scm_cv_struct_file_count="_r"
3559 else
3560 echo "configure: failed program was:" >&5
3561 cat conftest.$ac_ext >&5
3562 rm -rf conftest*
3563 cat > conftest.$ac_ext <<EOF
3564 #line 3565 "configure"
3565 #include "confdefs.h"
3566 #include <stdio.h>
3567 int main() {
3568 FILE *f = stdin; f->readCount = 0
3569 ; return 0; }
3570 EOF
3571 if { (eval echo configure:3572: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3572 rm -rf conftest*
3573 scm_cv_struct_file_count="readCount"
3574 else
3575 echo "configure: failed program was:" >&5
3576 cat conftest.$ac_ext >&5
3577 rm -rf conftest*
3578 scm_cv_struct_file_count=""
3579 fi
3580 rm -f conftest*
3581 fi
3582 rm -f conftest*
3583 fi
3584 rm -f conftest*
3585 fi
3586
3587 if test "$scm_cv_struct_file_count"; then
3588 echo "$ac_t""$scm_cv_struct_file_count" 1>&6
3589 cat >> confdefs.h <<EOF
3590 #define FILE_CNT_FIELD $scm_cv_struct_file_count
3591 EOF
3592
3593 else
3594 if eval "test \"`echo '$''{'scm_cv_struct_file_gptr'+set}'`\" = set"; then
3595 echo $ac_n "(cached) $ac_c" 1>&6
3596 else
3597 cat > conftest.$ac_ext <<EOF
3598 #line 3599 "configure"
3599 #include "confdefs.h"
3600 #include <stdio.h>
3601 int main() {
3602 FILE *f = stdin; f->_gptr = f->egptr;
3603 ; return 0; }
3604 EOF
3605 if { (eval echo configure:3606: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3606 rm -rf conftest*
3607 scm_cv_struct_file_gptr=1
3608 else
3609 echo "configure: failed program was:" >&5
3610 cat conftest.$ac_ext >&5
3611 rm -rf conftest*
3612 scm_cv_struct_file_gptr=""
3613 fi
3614 rm -f conftest*
3615 fi
3616
3617 if test "$scm_cv_struct_gptr"; then
3618 echo "$ac_t""gptr" 1>&6
3619 cat >> confdefs.h <<EOF
3620 #define FILE_CNT_GPTR $scm_cv_struct_file_gptr
3621 EOF
3622
3623 else
3624 if eval "test \"`echo '$''{'scm_cv_struct_file_readptr'+set}'`\" = set"; then
3625 echo $ac_n "(cached) $ac_c" 1>&6
3626 else
3627 cat > conftest.$ac_ext <<EOF
3628 #line 3629 "configure"
3629 #include "confdefs.h"
3630 #include <stdio.h>
3631 int main() {
3632 FILE *f = stdin; f->_IO_read_ptr = f->_IO_read_end;
3633 ; return 0; }
3634 EOF
3635 if { (eval echo configure:3636: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3636 rm -rf conftest*
3637 scm_cv_struct_file_readptr=1
3638 else
3639 echo "configure: failed program was:" >&5
3640 cat conftest.$ac_ext >&5
3641 fi
3642 rm -f conftest*
3643 fi
3644
3645 if test "$scm_cv_struct_file_readptr"; then
3646 echo "$ac_t""read_ptr" 1>&6
3647 cat >> confdefs.h <<EOF
3648 #define FILE_CNT_READPTR $scm_cv_struct_file_readptr
3649 EOF
3650
3651 else
3652 echo "$ac_t""we couldn't do it!" 1>&6
3653 fi
3654 fi
3655 fi
3656
3657 #--------------------------------------------------------------------
3658 #
3659 # Flags for thread support
3660 #
3661 #--------------------------------------------------------------------
3662
3663 CY_AC_WITH_THREADS
3664 CFLAGS="$CFLAGS $cy_cv_threads_cflags"
3665 THREAD_LIBS="$cy_cv_threads_libs"
3666
3667
3668 if test "$cy_cv_threads_package" = FSU; then
3669 cat >> confdefs.h <<\EOF
3670 #define USE_FSU_PTHREADS 1
3671 EOF
3672
3673 else if test "$cy_cv_threads_package" = COOP; then
3674 cat >> confdefs.h <<\EOF
3675 #define USE_COOP_THREADS 1
3676 EOF
3677
3678 else if test "$cy_cv_threads_package" = MIT; then
3679 cat >> confdefs.h <<\EOF
3680 #define USE_MIT_PTHREADS 1
3681 EOF
3682
3683 else if test "$cy_cv_threads_package" = PCthreads; then
3684 cat >> confdefs.h <<\EOF
3685 #define USE_PCTHREADS_PTHREADS 1
3686 EOF
3687
3688 else if test "$cy_cv_threads_package" = unknown; then
3689 { echo "configure: error: "cannot find threads installation"" 1>&2; exit 1; }
3690 fi
3691 fi
3692 fi
3693 fi
3694 fi
3695
3696 if test "$cy_cv_threads_package" != ""; then
3697 cat >> confdefs.h <<\EOF
3698 #define USE_THREADS 1
3699 EOF
3700
3701 LIBOBJS="$LIBOBJS threads.o"
3702 fi
3703
3704 ## If we're using GCC, ask for aggressive warnings.
3705 case "$GCC" in
3706 yes ) CFLAGS="$CFLAGS -Wall -Wpointer-arith" ;;
3707 esac
3708
3709 for ac_prog in mawk gawk nawk awk
3710 do
3711 # Extract the first word of "$ac_prog", so it can be a program name with args.
3712 set dummy $ac_prog; ac_word=$2
3713 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3714 echo "configure:3715: checking for $ac_word" >&5
3715 if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
3716 echo $ac_n "(cached) $ac_c" 1>&6
3717 else
3718 if test -n "$AWK"; then
3719 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3720 else
3721 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
3722 for ac_dir in $PATH; do
3723 test -z "$ac_dir" && ac_dir=.
3724 if test -f $ac_dir/$ac_word; then
3725 ac_cv_prog_AWK="$ac_prog"
3726 break
3727 fi
3728 done
3729 IFS="$ac_save_ifs"
3730 fi
3731 fi
3732 AWK="$ac_cv_prog_AWK"
3733 if test -n "$AWK"; then
3734 echo "$ac_t""$AWK" 1>&6
3735 else
3736 echo "$ac_t""no" 1>&6
3737 fi
3738
3739 test -n "$AWK" && break
3740 done
3741
3742
3743 ## If we're creating a shared library (using libtool!), then we'll
3744 ## need to generate a list of .lo files corresponding to the .o files
3745 ## given in LIBOBJS. We'll call it LIBLOBJS.
3746 LIBLOBJS="`echo ${LIBOBJS} | sed 's/\.o/.lo/g'`"
3747
3748
3749
3750
3751
3752 GUILE_STAMP="`date`"
3753
3754
3755
3756
3757
3758
3759
3760 threads_enabled=false
3761 if test "$cy_cv_threads_package" = COOP; then
3762 threads_enabled=true
3763 fi
3764
3765 # Determine the host we are working on
3766
3767 # Make sure we can run config.sub.
3768 if $ac_config_sub sun4 >/dev/null 2>&1; then :
3769 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
3770 fi
3771
3772 echo $ac_n "checking host system type""... $ac_c" 1>&6
3773 echo "configure:3774: checking host system type" >&5
3774
3775 host_alias=$host
3776 case "$host_alias" in
3777 NONE)
3778 case $nonopt in
3779 NONE)
3780 if host_alias=`$ac_config_guess`; then :
3781 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
3782 fi ;;
3783 *) host_alias=$nonopt ;;
3784 esac ;;
3785 esac
3786
3787 host=`$ac_config_sub $host_alias`
3788 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
3789 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
3790 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
3791 echo "$ac_t""$host" 1>&6
3792
3793
3794 # How can we refer to the qt source directory from within the qt build
3795 # directory? For headers, we can rely on the fact that the qt src
3796 # directory appears in the #include path.
3797
3798 qtsrcdir="`(cd $srcdir; pwd)`/qt"
3799
3800 case "$host" in
3801 i[3456]86-*-*)
3802 qtmds_s=$qtsrcdir/md/i386.s
3803 qtmd_h=md/i386.h
3804 qtmdc_c=$qtsrcdir/md/null.c
3805 ;;
3806 mips-sgi-irix5*)
3807 qtmds_s=$qtsrcdir/md/mips-irix5.s
3808 qtmd_h=md/mips.h
3809 qtmdc_c=$qtsrcdir/md/null.c
3810 qtdmdb_s=$qtsrcdir/md/mips_b.s
3811 ;;
3812 mips-*-*)
3813 qtmds_s=$qtsrcdir/md/mips.s
3814 qtmd_h=md/mips.h
3815 qtmdc_c=$qtsrcdir/md/null.c
3816 qtdmdb_s=$qtsrcdir/md/mips_b.s
3817 ;;
3818 sparc-*-sunos*)
3819 qtmd_h=md/sparc.h
3820 qtmdc_c=$qtsrcdir/md/null.c
3821 qtmds_s=$qtsrcdir/md/_sparc.s
3822 qtdmdb_s=$qtsrcdir/md/_sparc_b.s
3823 ;;
3824 sparc-*-*)
3825 qtmd_h=md/sparc.h
3826 qtmdc_c=$qtsrcdir/md/null.c
3827 qtmds_s=$qtsrcdir/md/sparc.s
3828 qtdmdb_s=$qtsrcdir/md/sparc_b.s
3829 ;;
3830 alpha-*-*)
3831 qtmd_h=md/axp.h
3832 qtmdc_c=$qtsrcdir/md/null.c
3833 qtmds_s=$qtsrcdir/md/axp.s
3834 qtdmdb_s=$qtsrcdir/md/axp_b.s
3835 ;;
3836 *)
3837 echo "Unknown configuration; threads package disabled"
3838 threads_enabled=false
3839 ;;
3840 esac
3841
3842
3843
3844 if $threads_enabled; then
3845 target_libs=libqt.a
3846 else
3847 target_libs=
3848 fi
3849
3850 # Give the Makefile the names of the object files that will be
3851 # generated by compiling $qtmdc_c and $qtmds_s.
3852 qtmdc_o="`echo ${qtmdc_c} | sed -e 's:^.*/::' | sed -e 's:\.c$:\.o:'`"
3853 qtmds_o="`echo ${qtmds_s} | sed -e 's:^.*/::' | sed -e 's:\.s$:\.o:'`"
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863 trap '' 1 2 15
3864 cat > confcache <<\EOF
3865 # This file is a shell script that caches the results of configure
3866 # tests run on this system so they can be shared between configure
3867 # scripts and configure runs. It is not useful on other systems.
3868 # If it contains results you don't want to keep, you may remove or edit it.
3869 #
3870 # By default, configure uses ./config.cache as the cache file,
3871 # creating it if it does not exist already. You can give configure
3872 # the --cache-file=FILE option to use a different cache file; that is
3873 # what configure does when it calls configure scripts in
3874 # subdirectories, so they share the cache.
3875 # Giving --cache-file=/dev/null disables caching, for debugging configure.
3876 # config.status only pays attention to the cache file if you give it the
3877 # --recheck option to rerun configure.
3878 #
3879 EOF
3880 # The following way of writing the cache mishandles newlines in values,
3881 # but we know of no workaround that is simple, portable, and efficient.
3882 # So, don't put newlines in cache variables' values.
3883 # Ultrix sh set writes to stderr and can't be redirected directly,
3884 # and sets the high bit in the cache file unless we assign to the vars.
3885 (set) 2>&1 |
3886 case `(ac_space=' '; set) 2>&1` in
3887 *ac_space=\ *)
3888 # `set' does not quote correctly, so add quotes (double-quote substitution
3889 # turns \\\\ into \\, and sed turns \\ into \).
3890 sed -n \
3891 -e "s/'/'\\\\''/g" \
3892 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
3893 ;;
3894 *)
3895 # `set' quotes correctly as required by POSIX, so do not add quotes.
3896 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
3897 ;;
3898 esac >> confcache
3899 if cmp -s $cache_file confcache; then
3900 :
3901 else
3902 if test -w $cache_file; then
3903 echo "updating cache $cache_file"
3904 cat confcache > $cache_file
3905 else
3906 echo "not updating unwritable cache $cache_file"
3907 fi
3908 fi
3909 rm -f confcache
3910
3911 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
3912
3913 test "x$prefix" = xNONE && prefix=$ac_default_prefix
3914 # Let make expand exec_prefix.
3915 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
3916
3917 # Any assignment to VPATH causes Sun make to only execute
3918 # the first set of double-colon rules, so remove it if not needed.
3919 # If there is a colon in the path, we need to keep it.
3920 if test "x$srcdir" = x.; then
3921 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
3922 fi
3923
3924 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
3925
3926 DEFS=-DHAVE_CONFIG_H
3927
3928 # Without the "./", some shells look in PATH for config.status.
3929 : ${CONFIG_STATUS=./config.status}
3930
3931 echo creating $CONFIG_STATUS
3932 rm -f $CONFIG_STATUS
3933 cat > $CONFIG_STATUS <<EOF
3934 #! /bin/sh
3935 # Generated automatically by configure.
3936 # Run this file to recreate the current configuration.
3937 # This directory was configured as follows,
3938 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3939 #
3940 # $0 $ac_configure_args
3941 #
3942 # Compiler output produced by configure, useful for debugging
3943 # configure, is in ./config.log if it exists.
3944
3945 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
3946 for ac_option
3947 do
3948 case "\$ac_option" in
3949 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
3950 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
3951 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
3952 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
3953 echo "$CONFIG_STATUS generated by autoconf version 2.12"
3954 exit 0 ;;
3955 -help | --help | --hel | --he | --h)
3956 echo "\$ac_cs_usage"; exit 0 ;;
3957 *) echo "\$ac_cs_usage"; exit 1 ;;
3958 esac
3959 done
3960
3961 ac_given_srcdir=$srcdir
3962 ac_given_INSTALL="$INSTALL"
3963
3964 trap 'rm -fr `echo "Makefile libguile/Makefile libguile/guile-snarf ice-9/Makefile ice-9/version.scm qt/Makefile qt/qt.h qt/md/Makefile qt/time/Makefile libguile/scmconfig.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
3965 EOF
3966 cat >> $CONFIG_STATUS <<EOF
3967
3968 # Protect against being on the right side of a sed subst in config.status.
3969 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
3970 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
3971 $ac_vpsub
3972 $extrasub
3973 s%@CFLAGS@%$CFLAGS%g
3974 s%@CPPFLAGS@%$CPPFLAGS%g
3975 s%@CXXFLAGS@%$CXXFLAGS%g
3976 s%@DEFS@%$DEFS%g
3977 s%@LDFLAGS@%$LDFLAGS%g
3978 s%@LIBS@%$LIBS%g
3979 s%@exec_prefix@%$exec_prefix%g
3980 s%@prefix@%$prefix%g
3981 s%@program_transform_name@%$program_transform_name%g
3982 s%@bindir@%$bindir%g
3983 s%@sbindir@%$sbindir%g
3984 s%@libexecdir@%$libexecdir%g
3985 s%@datadir@%$datadir%g
3986 s%@sysconfdir@%$sysconfdir%g
3987 s%@sharedstatedir@%$sharedstatedir%g
3988 s%@localstatedir@%$localstatedir%g
3989 s%@libdir@%$libdir%g
3990 s%@includedir@%$includedir%g
3991 s%@oldincludedir@%$oldincludedir%g
3992 s%@infodir@%$infodir%g
3993 s%@mandir@%$mandir%g
3994 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
3995 s%@INSTALL_DATA@%$INSTALL_DATA%g
3996 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
3997 s%@PACKAGE@%$PACKAGE%g
3998 s%@VERSION@%$VERSION%g
3999 s%@ACLOCAL@%$ACLOCAL%g
4000 s%@AUTOCONF@%$AUTOCONF%g
4001 s%@AUTOMAKE@%$AUTOMAKE%g
4002 s%@AUTOHEADER@%$AUTOHEADER%g
4003 s%@MAKEINFO@%$MAKEINFO%g
4004 s%@SET_MAKE@%$SET_MAKE%g
4005 s%@MAINT@%$MAINT%g
4006 s%@CC@%$CC%g
4007 s%@CPP@%$CPP%g
4008 s%@host@%$host%g
4009 s%@host_alias@%$host_alias%g
4010 s%@host_cpu@%$host_cpu%g
4011 s%@host_vendor@%$host_vendor%g
4012 s%@host_os@%$host_os%g
4013 s%@RANLIB@%$RANLIB%g
4014 s%@LD@%$LD%g
4015 s%@LN_S@%$LN_S%g
4016 s%@LIBTOOL@%$LIBTOOL%g
4017 s%@LIBOBJS@%$LIBOBJS%g
4018 s%@ALLOCA@%$ALLOCA%g
4019 s%@THREAD_LIBS@%$THREAD_LIBS%g
4020 s%@AWK@%$AWK%g
4021 s%@GUILE_MAJOR_VERSION@%$GUILE_MAJOR_VERSION%g
4022 s%@GUILE_MINOR_VERSION@%$GUILE_MINOR_VERSION%g
4023 s%@GUILE_VERSION@%$GUILE_VERSION%g
4024 s%@GUILE_STAMP@%$GUILE_STAMP%g
4025 s%@LIBLOBJS@%$LIBLOBJS%g
4026 s%@target_libs@%$target_libs%g
4027 s%@qtmd_h@%$qtmd_h%g
4028 s%@qtmdc_c@%$qtmdc_c%g
4029 s%@qtmdc_o@%$qtmdc_o%g
4030 s%@qtmds_s@%$qtmds_s%g
4031 s%@qtmds_o@%$qtmds_o%g
4032 s%@qtmdb_s@%$qtmdb_s%g
4033
4034 CEOF
4035 EOF
4036
4037 cat >> $CONFIG_STATUS <<\EOF
4038
4039 # Split the substitutions into bite-sized pieces for seds with
4040 # small command number limits, like on Digital OSF/1 and HP-UX.
4041 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
4042 ac_file=1 # Number of current file.
4043 ac_beg=1 # First line for current file.
4044 ac_end=$ac_max_sed_cmds # Line after last line for current file.
4045 ac_more_lines=:
4046 ac_sed_cmds=""
4047 while $ac_more_lines; do
4048 if test $ac_beg -gt 1; then
4049 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
4050 else
4051 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
4052 fi
4053 if test ! -s conftest.s$ac_file; then
4054 ac_more_lines=false
4055 rm -f conftest.s$ac_file
4056 else
4057 if test -z "$ac_sed_cmds"; then
4058 ac_sed_cmds="sed -f conftest.s$ac_file"
4059 else
4060 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
4061 fi
4062 ac_file=`expr $ac_file + 1`
4063 ac_beg=$ac_end
4064 ac_end=`expr $ac_end + $ac_max_sed_cmds`
4065 fi
4066 done
4067 if test -z "$ac_sed_cmds"; then
4068 ac_sed_cmds=cat
4069 fi
4070 EOF
4071
4072 cat >> $CONFIG_STATUS <<EOF
4073
4074 CONFIG_FILES=\${CONFIG_FILES-"Makefile libguile/Makefile libguile/guile-snarf ice-9/Makefile ice-9/version.scm qt/Makefile qt/qt.h qt/md/Makefile qt/time/Makefile"}
4075 EOF
4076 cat >> $CONFIG_STATUS <<\EOF
4077 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
4078 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
4079 case "$ac_file" in
4080 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
4081 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
4082 *) ac_file_in="${ac_file}.in" ;;
4083 esac
4084
4085 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
4086
4087 # Remove last slash and all that follows it. Not all systems have dirname.
4088 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4089 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4090 # The file is in a subdirectory.
4091 test ! -d "$ac_dir" && mkdir "$ac_dir"
4092 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
4093 # A "../" for each directory in $ac_dir_suffix.
4094 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
4095 else
4096 ac_dir_suffix= ac_dots=
4097 fi
4098
4099 case "$ac_given_srcdir" in
4100 .) srcdir=.
4101 if test -z "$ac_dots"; then top_srcdir=.
4102 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
4103 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
4104 *) # Relative path.
4105 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
4106 top_srcdir="$ac_dots$ac_given_srcdir" ;;
4107 esac
4108
4109 case "$ac_given_INSTALL" in
4110 [/$]*) INSTALL="$ac_given_INSTALL" ;;
4111 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
4112 esac
4113
4114 echo creating "$ac_file"
4115 rm -f "$ac_file"
4116 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
4117 case "$ac_file" in
4118 *Makefile*) ac_comsub="1i\\
4119 # $configure_input" ;;
4120 *) ac_comsub= ;;
4121 esac
4122
4123 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4124 sed -e "$ac_comsub
4125 s%@configure_input@%$configure_input%g
4126 s%@srcdir@%$srcdir%g
4127 s%@top_srcdir@%$top_srcdir%g
4128 s%@INSTALL@%$INSTALL%g
4129 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
4130 fi; done
4131 rm -f conftest.s*
4132
4133 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
4134 # NAME is the cpp macro being defined and VALUE is the value it is being given.
4135 #
4136 # ac_d sets the value in "#define NAME VALUE" lines.
4137 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
4138 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
4139 ac_dC='\3'
4140 ac_dD='%g'
4141 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
4142 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
4143 ac_uB='\([ ]\)%\1#\2define\3'
4144 ac_uC=' '
4145 ac_uD='\4%g'
4146 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
4147 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
4148 ac_eB='$%\1#\2define\3'
4149 ac_eC=' '
4150 ac_eD='%g'
4151
4152 if test "${CONFIG_HEADERS+set}" != set; then
4153 EOF
4154 cat >> $CONFIG_STATUS <<EOF
4155 CONFIG_HEADERS="libguile/scmconfig.h"
4156 EOF
4157 cat >> $CONFIG_STATUS <<\EOF
4158 fi
4159 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
4160 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
4161 case "$ac_file" in
4162 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
4163 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
4164 *) ac_file_in="${ac_file}.in" ;;
4165 esac
4166
4167 echo creating $ac_file
4168
4169 rm -f conftest.frag conftest.in conftest.out
4170 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4171 cat $ac_file_inputs > conftest.in
4172
4173 EOF
4174
4175 # Transform confdefs.h into a sed script conftest.vals that substitutes
4176 # the proper values into config.h.in to produce config.h. And first:
4177 # Protect against being on the right side of a sed subst in config.status.
4178 # Protect against being in an unquoted here document in config.status.
4179 rm -f conftest.vals
4180 cat > conftest.hdr <<\EOF
4181 s/[\\&%]/\\&/g
4182 s%[\\$`]%\\&%g
4183 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
4184 s%ac_d%ac_u%gp
4185 s%ac_u%ac_e%gp
4186 EOF
4187 sed -n -f conftest.hdr confdefs.h > conftest.vals
4188 rm -f conftest.hdr
4189
4190 # This sed command replaces #undef with comments. This is necessary, for
4191 # example, in the case of _POSIX_SOURCE, which is predefined and required
4192 # on some systems where configure will not decide to define it.
4193 cat >> conftest.vals <<\EOF
4194 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
4195 EOF
4196
4197 # Break up conftest.vals because some shells have a limit on
4198 # the size of here documents, and old seds have small limits too.
4199
4200 rm -f conftest.tail
4201 while :
4202 do
4203 ac_lines=`grep -c . conftest.vals`
4204 # grep -c gives empty output for an empty file on some AIX systems.
4205 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
4206 # Write a limited-size here document to conftest.frag.
4207 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
4208 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
4209 echo 'CEOF
4210 sed -f conftest.frag conftest.in > conftest.out
4211 rm -f conftest.in
4212 mv conftest.out conftest.in
4213 ' >> $CONFIG_STATUS
4214 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
4215 rm -f conftest.vals
4216 mv conftest.tail conftest.vals
4217 done
4218 rm -f conftest.vals
4219
4220 cat >> $CONFIG_STATUS <<\EOF
4221 rm -f conftest.frag conftest.h
4222 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
4223 cat conftest.in >> conftest.h
4224 rm -f conftest.in
4225 if cmp -s $ac_file conftest.h 2>/dev/null; then
4226 echo "$ac_file is unchanged"
4227 rm -f conftest.h
4228 else
4229 # Remove last slash and all that follows it. Not all systems have dirname.
4230 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4231 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4232 # The file is in a subdirectory.
4233 test ! -d "$ac_dir" && mkdir "$ac_dir"
4234 fi
4235 rm -f $ac_file
4236 mv conftest.h $ac_file
4237 fi
4238 fi; done
4239
4240 EOF
4241 cat >> $CONFIG_STATUS <<EOF
4242
4243
4244 EOF
4245 cat >> $CONFIG_STATUS <<\EOF
4246 test -z "$CONFIG_HEADERS" || echo timestamp > libguile/stamp-h
4247 chmod +x libguile/guile-snarf
4248 exit 0
4249 EOF
4250 chmod +x $CONFIG_STATUS
4251 rm -fr confdefs* $ac_clean_files
4252 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
4253
4254