Debian Codegraph @

configure

raw
1 #! /bin/sh
2
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.13
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 --with-aalib-prefix=PFX Prefix where AALIB is installed (optional)"
16 ac_help="$ac_help
17 --with-aalib-exec-prefix=PFX Exec prefix where AALIB is installed (optional)"
18 ac_help="$ac_help
19 --disable-aalibtest Do not try to compile and run a test AALIB program"
20 ac_help="$ac_help
21 --with-libmikmod-prefix=PFX Prefix where libmikmod is installed (optional)"
22 ac_help="$ac_help
23 --with-libmikmod-exec-prefix=PFX Exec prefix where libmikmod is installed (optional)"
24 ac_help="$ac_help
25 --disable-libmikmodtest Do not try to compile and run a test libmikmod program"
26
27 # Initialize some variables set by options.
28 # The variables have the same names as the options, with
29 # dashes changed to underlines.
30 build=NONE
31 cache_file=./config.cache
32 exec_prefix=NONE
33 host=NONE
34 no_create=
35 nonopt=NONE
36 no_recursion=
37 prefix=NONE
38 program_prefix=NONE
39 program_suffix=NONE
40 program_transform_name=s,x,x,
41 silent=
42 site=
43 srcdir=
44 target=NONE
45 verbose=
46 x_includes=NONE
47 x_libraries=NONE
48 bindir='${exec_prefix}/bin'
49 sbindir='${exec_prefix}/sbin'
50 libexecdir='${exec_prefix}/libexec'
51 datadir='${prefix}/share'
52 sysconfdir='${prefix}/etc'
53 sharedstatedir='${prefix}/com'
54 localstatedir='${prefix}/var'
55 libdir='${exec_prefix}/lib'
56 includedir='${prefix}/include'
57 oldincludedir='/usr/include'
58 infodir='${prefix}/info'
59 mandir='${prefix}/man'
60
61 # Initialize some other variables.
62 subdirs=
63 MFLAGS= MAKEFLAGS=
64 SHELL=${CONFIG_SHELL-/bin/sh}
65 # Maximum number of lines to put in a shell here document.
66 ac_max_here_lines=12
67
68 ac_prev=
69 for ac_option
70 do
71
72 # If the previous option needs an argument, assign it.
73 if test -n "$ac_prev"; then
74 eval "$ac_prev=\$ac_option"
75 ac_prev=
76 continue
77 fi
78
79 case "$ac_option" in
80 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
81 *) ac_optarg= ;;
82 esac
83
84 # Accept the important Cygnus configure options, so we can diagnose typos.
85
86 case "$ac_option" in
87
88 -bindir | --bindir | --bindi | --bind | --bin | --bi)
89 ac_prev=bindir ;;
90 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
91 bindir="$ac_optarg" ;;
92
93 -build | --build | --buil | --bui | --bu)
94 ac_prev=build ;;
95 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
96 build="$ac_optarg" ;;
97
98 -cache-file | --cache-file | --cache-fil | --cache-fi \
99 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
100 ac_prev=cache_file ;;
101 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
102 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
103 cache_file="$ac_optarg" ;;
104
105 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
106 ac_prev=datadir ;;
107 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
108 | --da=*)
109 datadir="$ac_optarg" ;;
110
111 -disable-* | --disable-*)
112 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
113 # Reject names that are not valid shell variable names.
114 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
115 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
116 fi
117 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
118 eval "enable_${ac_feature}=no" ;;
119
120 -enable-* | --enable-*)
121 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
122 # Reject names that are not valid shell variable names.
123 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
124 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
125 fi
126 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
127 case "$ac_option" in
128 *=*) ;;
129 *) ac_optarg=yes ;;
130 esac
131 eval "enable_${ac_feature}='$ac_optarg'" ;;
132
133 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
134 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
135 | --exec | --exe | --ex)
136 ac_prev=exec_prefix ;;
137 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
138 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
139 | --exec=* | --exe=* | --ex=*)
140 exec_prefix="$ac_optarg" ;;
141
142 -gas | --gas | --ga | --g)
143 # Obsolete; use --with-gas.
144 with_gas=yes ;;
145
146 -help | --help | --hel | --he)
147 # Omit some internal or obsolete options to make the list less imposing.
148 # This message is too long to be a string in the A/UX 3.1 sh.
149 cat << EOF
150 Usage: configure [options] [host]
151 Options: [defaults in brackets after descriptions]
152 Configuration:
153 --cache-file=FILE cache test results in FILE
154 --help print this message
155 --no-create do not create output files
156 --quiet, --silent do not print \`checking...' messages
157 --version print the version of autoconf that created configure
158 Directory and file names:
159 --prefix=PREFIX install architecture-independent files in PREFIX
160 [$ac_default_prefix]
161 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
162 [same as prefix]
163 --bindir=DIR user executables in DIR [EPREFIX/bin]
164 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
165 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
166 --datadir=DIR read-only architecture-independent data in DIR
167 [PREFIX/share]
168 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
169 --sharedstatedir=DIR modifiable architecture-independent data in DIR
170 [PREFIX/com]
171 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
172 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
173 --includedir=DIR C header files in DIR [PREFIX/include]
174 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
175 --infodir=DIR info documentation in DIR [PREFIX/info]
176 --mandir=DIR man documentation in DIR [PREFIX/man]
177 --srcdir=DIR find the sources in DIR [configure dir or ..]
178 --program-prefix=PREFIX prepend PREFIX to installed program names
179 --program-suffix=SUFFIX append SUFFIX to installed program names
180 --program-transform-name=PROGRAM
181 run sed PROGRAM on installed program names
182 EOF
183 cat << EOF
184 Host type:
185 --build=BUILD configure for building on BUILD [BUILD=HOST]
186 --host=HOST configure for HOST [guessed]
187 --target=TARGET configure for TARGET [TARGET=HOST]
188 Features and packages:
189 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
190 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
191 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
192 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
193 --x-includes=DIR X include files are in DIR
194 --x-libraries=DIR X library files are in DIR
195 EOF
196 if test -n "$ac_help"; then
197 echo "--enable and --with options recognized:$ac_help"
198 fi
199 exit 0 ;;
200
201 -host | --host | --hos | --ho)
202 ac_prev=host ;;
203 -host=* | --host=* | --hos=* | --ho=*)
204 host="$ac_optarg" ;;
205
206 -includedir | --includedir | --includedi | --included | --include \
207 | --includ | --inclu | --incl | --inc)
208 ac_prev=includedir ;;
209 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
210 | --includ=* | --inclu=* | --incl=* | --inc=*)
211 includedir="$ac_optarg" ;;
212
213 -infodir | --infodir | --infodi | --infod | --info | --inf)
214 ac_prev=infodir ;;
215 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
216 infodir="$ac_optarg" ;;
217
218 -libdir | --libdir | --libdi | --libd)
219 ac_prev=libdir ;;
220 -libdir=* | --libdir=* | --libdi=* | --libd=*)
221 libdir="$ac_optarg" ;;
222
223 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
224 | --libexe | --libex | --libe)
225 ac_prev=libexecdir ;;
226 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
227 | --libexe=* | --libex=* | --libe=*)
228 libexecdir="$ac_optarg" ;;
229
230 -localstatedir | --localstatedir | --localstatedi | --localstated \
231 | --localstate | --localstat | --localsta | --localst \
232 | --locals | --local | --loca | --loc | --lo)
233 ac_prev=localstatedir ;;
234 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
235 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
236 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
237 localstatedir="$ac_optarg" ;;
238
239 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
240 ac_prev=mandir ;;
241 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
242 mandir="$ac_optarg" ;;
243
244 -nfp | --nfp | --nf)
245 # Obsolete; use --without-fp.
246 with_fp=no ;;
247
248 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
249 | --no-cr | --no-c)
250 no_create=yes ;;
251
252 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
253 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
254 no_recursion=yes ;;
255
256 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
257 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
258 | --oldin | --oldi | --old | --ol | --o)
259 ac_prev=oldincludedir ;;
260 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
261 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
262 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
263 oldincludedir="$ac_optarg" ;;
264
265 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
266 ac_prev=prefix ;;
267 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
268 prefix="$ac_optarg" ;;
269
270 -program-prefix | --program-prefix | --program-prefi | --program-pref \
271 | --program-pre | --program-pr | --program-p)
272 ac_prev=program_prefix ;;
273 -program-prefix=* | --program-prefix=* | --program-prefi=* \
274 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
275 program_prefix="$ac_optarg" ;;
276
277 -program-suffix | --program-suffix | --program-suffi | --program-suff \
278 | --program-suf | --program-su | --program-s)
279 ac_prev=program_suffix ;;
280 -program-suffix=* | --program-suffix=* | --program-suffi=* \
281 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
282 program_suffix="$ac_optarg" ;;
283
284 -program-transform-name | --program-transform-name \
285 | --program-transform-nam | --program-transform-na \
286 | --program-transform-n | --program-transform- \
287 | --program-transform | --program-transfor \
288 | --program-transfo | --program-transf \
289 | --program-trans | --program-tran \
290 | --progr-tra | --program-tr | --program-t)
291 ac_prev=program_transform_name ;;
292 -program-transform-name=* | --program-transform-name=* \
293 | --program-transform-nam=* | --program-transform-na=* \
294 | --program-transform-n=* | --program-transform-=* \
295 | --program-transform=* | --program-transfor=* \
296 | --program-transfo=* | --program-transf=* \
297 | --program-trans=* | --program-tran=* \
298 | --progr-tra=* | --program-tr=* | --program-t=*)
299 program_transform_name="$ac_optarg" ;;
300
301 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
302 | -silent | --silent | --silen | --sile | --sil)
303 silent=yes ;;
304
305 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
306 ac_prev=sbindir ;;
307 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
308 | --sbi=* | --sb=*)
309 sbindir="$ac_optarg" ;;
310
311 -sharedstatedir | --sharedstatedir | --sharedstatedi \
312 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
313 | --sharedst | --shareds | --shared | --share | --shar \
314 | --sha | --sh)
315 ac_prev=sharedstatedir ;;
316 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
317 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
318 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
319 | --sha=* | --sh=*)
320 sharedstatedir="$ac_optarg" ;;
321
322 -site | --site | --sit)
323 ac_prev=site ;;
324 -site=* | --site=* | --sit=*)
325 site="$ac_optarg" ;;
326
327 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
328 ac_prev=srcdir ;;
329 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
330 srcdir="$ac_optarg" ;;
331
332 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
333 | --syscon | --sysco | --sysc | --sys | --sy)
334 ac_prev=sysconfdir ;;
335 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
336 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
337 sysconfdir="$ac_optarg" ;;
338
339 -target | --target | --targe | --targ | --tar | --ta | --t)
340 ac_prev=target ;;
341 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
342 target="$ac_optarg" ;;
343
344 -v | -verbose | --verbose | --verbos | --verbo | --verb)
345 verbose=yes ;;
346
347 -version | --version | --versio | --versi | --vers)
348 echo "configure generated by autoconf version 2.13"
349 exit 0 ;;
350
351 -with-* | --with-*)
352 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
353 # Reject names that are not valid shell variable names.
354 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
355 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
356 fi
357 ac_package=`echo $ac_package| sed 's/-/_/g'`
358 case "$ac_option" in
359 *=*) ;;
360 *) ac_optarg=yes ;;
361 esac
362 eval "with_${ac_package}='$ac_optarg'" ;;
363
364 -without-* | --without-*)
365 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
366 # Reject names that are not valid shell variable names.
367 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
368 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
369 fi
370 ac_package=`echo $ac_package| sed 's/-/_/g'`
371 eval "with_${ac_package}=no" ;;
372
373 --x)
374 # Obsolete; use --with-x.
375 with_x=yes ;;
376
377 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
378 | --x-incl | --x-inc | --x-in | --x-i)
379 ac_prev=x_includes ;;
380 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
381 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
382 x_includes="$ac_optarg" ;;
383
384 -x-libraries | --x-libraries | --x-librarie | --x-librari \
385 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
386 ac_prev=x_libraries ;;
387 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
388 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
389 x_libraries="$ac_optarg" ;;
390
391 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
392 ;;
393
394 *)
395 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
396 echo "configure: warning: $ac_option: invalid host type" 1>&2
397 fi
398 if test "x$nonopt" != xNONE; then
399 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
400 fi
401 nonopt="$ac_option"
402 ;;
403
404 esac
405 done
406
407 if test -n "$ac_prev"; then
408 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
409 fi
410
411 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
412
413 # File descriptor usage:
414 # 0 standard input
415 # 1 file creation
416 # 2 errors and warnings
417 # 3 some systems may open it to /dev/tty
418 # 4 used on the Kubota Titan
419 # 6 checking for... messages and results
420 # 5 compiler messages saved in config.log
421 if test "$silent" = yes; then
422 exec 6>/dev/null
423 else
424 exec 6>&1
425 fi
426 exec 5>./config.log
427
428 echo "\
429 This file contains any messages produced by compilers while
430 running configure, to aid debugging if configure makes a mistake.
431 " 1>&5
432
433 # Strip out --no-create and --no-recursion so they do not pile up.
434 # Also quote any args containing shell metacharacters.
435 ac_configure_args=
436 for ac_arg
437 do
438 case "$ac_arg" in
439 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
440 | --no-cr | --no-c) ;;
441 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
442 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
443 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
444 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
445 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
446 esac
447 done
448
449 # NLS nuisances.
450 # Only set these to C if already set. These must not be set unconditionally
451 # because not all systems understand e.g. LANG=C (notably SCO).
452 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
453 # Non-C LC_CTYPE values break the ctype check.
454 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
455 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
456 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
457 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
458
459 # confdefs.h avoids OS command line length limits that DEFS can exceed.
460 rm -rf conftest* confdefs.h
461 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
462 echo > confdefs.h
463
464 # A filename unique to this package, relative to the directory that
465 # configure is in, which we can look for to find out if srcdir is correct.
466 ac_unique_file=main.c
467
468 # Find the source files, if location was not specified.
469 if test -z "$srcdir"; then
470 ac_srcdir_defaulted=yes
471 # Try the directory containing this script, then its parent.
472 ac_prog=$0
473 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
474 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
475 srcdir=$ac_confdir
476 if test ! -r $srcdir/$ac_unique_file; then
477 srcdir=..
478 fi
479 else
480 ac_srcdir_defaulted=no
481 fi
482 if test ! -r $srcdir/$ac_unique_file; then
483 if test "$ac_srcdir_defaulted" = yes; then
484 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
485 else
486 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
487 fi
488 fi
489 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
490
491 # Prefer explicitly selected file to automatically selected ones.
492 if test -z "$CONFIG_SITE"; then
493 if test "x$prefix" != xNONE; then
494 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
495 else
496 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
497 fi
498 fi
499 for ac_site_file in $CONFIG_SITE; do
500 if test -r "$ac_site_file"; then
501 echo "loading site script $ac_site_file"
502 . "$ac_site_file"
503 fi
504 done
505
506 if test -r "$cache_file"; then
507 echo "loading cache $cache_file"
508 . $cache_file
509 else
510 echo "creating cache $cache_file"
511 > $cache_file
512 fi
513
514 ac_ext=c
515 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
516 ac_cpp='$CPP $CPPFLAGS'
517 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
518 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
519 cross_compiling=$ac_cv_prog_cc_cross
520
521 ac_exeext=
522 ac_objext=o
523 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
524 # Stardent Vistra SVR4 grep lacks -e, says [email protected].
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 ac_aux_dir=
537 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
538 if test -f $ac_dir/install-sh; then
539 ac_aux_dir=$ac_dir
540 ac_install_sh="$ac_aux_dir/install-sh -c"
541 break
542 elif test -f $ac_dir/install.sh; then
543 ac_aux_dir=$ac_dir
544 ac_install_sh="$ac_aux_dir/install.sh -c"
545 break
546 fi
547 done
548 if test -z "$ac_aux_dir"; then
549 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
550 fi
551 ac_config_guess=$ac_aux_dir/config.guess
552 ac_config_sub=$ac_aux_dir/config.sub
553 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
554
555 # Find a good install program. We prefer a C program (faster),
556 # so one script is as good as another. But avoid the broken or
557 # incompatible versions:
558 # SysV /etc/install, /usr/sbin/install
559 # SunOS /usr/etc/install
560 # IRIX /sbin/install
561 # AIX /bin/install
562 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
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=":"
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 # Don't use installbsd from OSF since it installs stuff as root
580 # by default.
581 for ac_prog in ginstall scoinst install; do
582 if test -f $ac_dir/$ac_prog; then
583 if test $ac_prog = install &&
584 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
585 # AIX install. It has an incompatible calling convention.
586 :
587 else
588 ac_cv_path_install="$ac_dir/$ac_prog -c"
589 break 2
590 fi
591 fi
592 done
593 ;;
594 esac
595 done
596 IFS="$ac_save_IFS"
597
598 fi
599 if test "${ac_cv_path_install+set}" = set; then
600 INSTALL="$ac_cv_path_install"
601 else
602 # As a last resort, use the slow shell script. We don't cache a
603 # path for INSTALL within a source directory, because that will
604 # break other packages using the cache if that directory is
605 # removed, or if the path is relative.
606 INSTALL="$ac_install_sh"
607 fi
608 fi
609 echo "$ac_t""$INSTALL" 1>&6
610
611 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
612 # It thinks the first close brace ends the variable substitution.
613 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
614
615 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
616
617 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
618
619 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
620 echo "configure:621: checking whether build environment is sane" >&5
621 # Just in case
622 sleep 1
623 echo timestamp > conftestfile
624 # Do `set' in a subshell so we don't clobber the current shell's
625 # arguments. Must try -L first in case configure is actually a
626 # symlink; some systems play weird games with the mod time of symlinks
627 # (eg FreeBSD returns the mod time of the symlink's containing
628 # directory).
629 if (
630 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
631 if test "$*" = "X"; then
632 # -L didn't work.
633 set X `ls -t $srcdir/configure conftestfile`
634 fi
635 if test "$*" != "X $srcdir/configure conftestfile" \
636 && test "$*" != "X conftestfile $srcdir/configure"; then
637
638 # If neither matched, then we have a broken ls. This can happen
639 # if, for instance, CONFIG_SHELL is bash and it inherits a
640 # broken ls alias from the environment. This has actually
641 # happened. Such a system could not be considered "sane".
642 { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
643 alias in your environment" 1>&2; exit 1; }
644 fi
645
646 test "$2" = conftestfile
647 )
648 then
649 # Ok.
650 :
651 else
652 { echo "configure: error: newly created file is older than distributed files!
653 Check your system clock" 1>&2; exit 1; }
654 fi
655 rm -f conftest*
656 echo "$ac_t""yes" 1>&6
657 if test "$program_transform_name" = s,x,x,; then
658 program_transform_name=
659 else
660 # Double any \ or $. echo might interpret backslashes.
661 cat <<\EOF_SED > conftestsed
662 s,\\,\\\\,g; s,\$,$$,g
663 EOF_SED
664 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
665 rm -f conftestsed
666 fi
667 test "$program_prefix" != NONE &&
668 program_transform_name="s,^,${program_prefix},; $program_transform_name"
669 # Use a double $ so make ignores it.
670 test "$program_suffix" != NONE &&
671 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
672
673 # sed with no file args requires a program.
674 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
675
676 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
677 echo "configure:678: checking whether ${MAKE-make} sets \${MAKE}" >&5
678 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
679 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
680 echo $ac_n "(cached) $ac_c" 1>&6
681 else
682 cat > conftestmake <<\EOF
683 all:
684 @echo 'ac_maketemp="${MAKE}"'
685 EOF
686 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
687 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
688 if test -n "$ac_maketemp"; then
689 eval ac_cv_prog_make_${ac_make}_set=yes
690 else
691 eval ac_cv_prog_make_${ac_make}_set=no
692 fi
693 rm -f conftestmake
694 fi
695 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
696 echo "$ac_t""yes" 1>&6
697 SET_MAKE=
698 else
699 echo "$ac_t""no" 1>&6
700 SET_MAKE="MAKE=${MAKE-make}"
701 fi
702
703
704 PACKAGE=bb
705
706 VERSION=1.3.0
707
708 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
709 { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
710 fi
711 cat >> confdefs.h <<EOF
712 #define PACKAGE "$PACKAGE"
713 EOF
714
715 cat >> confdefs.h <<EOF
716 #define VERSION "$VERSION"
717 EOF
718
719
720
721 missing_dir=`cd $ac_aux_dir && pwd`
722 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
723 echo "configure:724: checking for working aclocal" >&5
724 # Run test in a subshell; some versions of sh will print an error if
725 # an executable is not found, even if stderr is redirected.
726 # Redirect stdin to placate older versions of autoconf. Sigh.
727 if (aclocal --version) < /dev/null > /dev/null 2>&1; then
728 ACLOCAL=aclocal
729 echo "$ac_t""found" 1>&6
730 else
731 ACLOCAL="$missing_dir/missing aclocal"
732 echo "$ac_t""missing" 1>&6
733 fi
734
735 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
736 echo "configure:737: checking for working autoconf" >&5
737 # Run test in a subshell; some versions of sh will print an error if
738 # an executable is not found, even if stderr is redirected.
739 # Redirect stdin to placate older versions of autoconf. Sigh.
740 if (autoconf --version) < /dev/null > /dev/null 2>&1; then
741 AUTOCONF=autoconf
742 echo "$ac_t""found" 1>&6
743 else
744 AUTOCONF="$missing_dir/missing autoconf"
745 echo "$ac_t""missing" 1>&6
746 fi
747
748 echo $ac_n "checking for working automake""... $ac_c" 1>&6
749 echo "configure:750: checking for working automake" >&5
750 # Run test in a subshell; some versions of sh will print an error if
751 # an executable is not found, even if stderr is redirected.
752 # Redirect stdin to placate older versions of autoconf. Sigh.
753 if (automake --version) < /dev/null > /dev/null 2>&1; then
754 AUTOMAKE=automake
755 echo "$ac_t""found" 1>&6
756 else
757 AUTOMAKE="$missing_dir/missing automake"
758 echo "$ac_t""missing" 1>&6
759 fi
760
761 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
762 echo "configure:763: checking for working autoheader" >&5
763 # Run test in a subshell; some versions of sh will print an error if
764 # an executable is not found, even if stderr is redirected.
765 # Redirect stdin to placate older versions of autoconf. Sigh.
766 if (autoheader --version) < /dev/null > /dev/null 2>&1; then
767 AUTOHEADER=autoheader
768 echo "$ac_t""found" 1>&6
769 else
770 AUTOHEADER="$missing_dir/missing autoheader"
771 echo "$ac_t""missing" 1>&6
772 fi
773
774 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
775 echo "configure:776: checking for working makeinfo" >&5
776 # Run test in a subshell; some versions of sh will print an error if
777 # an executable is not found, even if stderr is redirected.
778 # Redirect stdin to placate older versions of autoconf. Sigh.
779 if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
780 MAKEINFO=makeinfo
781 echo "$ac_t""found" 1>&6
782 else
783 MAKEINFO="$missing_dir/missing makeinfo"
784 echo "$ac_t""missing" 1>&6
785 fi
786
787
788
789
790
791
792 use_cc_g_flag=no
793 # Extract the first word of "gcc", so it can be a program name with args.
794 set dummy gcc; ac_word=$2
795 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
796 echo "configure:797: checking for $ac_word" >&5
797 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
798 echo $ac_n "(cached) $ac_c" 1>&6
799 else
800 if test -n "$CC"; then
801 ac_cv_prog_CC="$CC" # Let the user override the test.
802 else
803 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
804 ac_dummy="$PATH"
805 for ac_dir in $ac_dummy; do
806 test -z "$ac_dir" && ac_dir=.
807 if test -f $ac_dir/$ac_word; then
808 ac_cv_prog_CC="gcc"
809 break
810 fi
811 done
812 IFS="$ac_save_ifs"
813 fi
814 fi
815 CC="$ac_cv_prog_CC"
816 if test -n "$CC"; then
817 echo "$ac_t""$CC" 1>&6
818 else
819 echo "$ac_t""no" 1>&6
820 fi
821
822 if test -z "$CC"; then
823 # Extract the first word of "cc", so it can be a program name with args.
824 set dummy cc; ac_word=$2
825 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
826 echo "configure:827: checking for $ac_word" >&5
827 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
828 echo $ac_n "(cached) $ac_c" 1>&6
829 else
830 if test -n "$CC"; then
831 ac_cv_prog_CC="$CC" # Let the user override the test.
832 else
833 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
834 ac_prog_rejected=no
835 ac_dummy="$PATH"
836 for ac_dir in $ac_dummy; do
837 test -z "$ac_dir" && ac_dir=.
838 if test -f $ac_dir/$ac_word; then
839 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
840 ac_prog_rejected=yes
841 continue
842 fi
843 ac_cv_prog_CC="cc"
844 break
845 fi
846 done
847 IFS="$ac_save_ifs"
848 if test $ac_prog_rejected = yes; then
849 # We found a bogon in the path, so make sure we never use it.
850 set dummy $ac_cv_prog_CC
851 shift
852 if test $# -gt 0; then
853 # We chose a different compiler from the bogus one.
854 # However, it has the same basename, so the bogon will be chosen
855 # first if we set CC to just the basename; use the full file name.
856 shift
857 set dummy "$ac_dir/$ac_word" "$@"
858 shift
859 ac_cv_prog_CC="$@"
860 fi
861 fi
862 fi
863 fi
864 CC="$ac_cv_prog_CC"
865 if test -n "$CC"; then
866 echo "$ac_t""$CC" 1>&6
867 else
868 echo "$ac_t""no" 1>&6
869 fi
870
871 if test -z "$CC"; then
872 case "`uname -s`" in
873 *win32* | *WIN32*)
874 # Extract the first word of "cl", so it can be a program name with args.
875 set dummy cl; ac_word=$2
876 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
877 echo "configure:878: checking for $ac_word" >&5
878 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
879 echo $ac_n "(cached) $ac_c" 1>&6
880 else
881 if test -n "$CC"; then
882 ac_cv_prog_CC="$CC" # Let the user override the test.
883 else
884 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
885 ac_dummy="$PATH"
886 for ac_dir in $ac_dummy; do
887 test -z "$ac_dir" && ac_dir=.
888 if test -f $ac_dir/$ac_word; then
889 ac_cv_prog_CC="cl"
890 break
891 fi
892 done
893 IFS="$ac_save_ifs"
894 fi
895 fi
896 CC="$ac_cv_prog_CC"
897 if test -n "$CC"; then
898 echo "$ac_t""$CC" 1>&6
899 else
900 echo "$ac_t""no" 1>&6
901 fi
902 ;;
903 esac
904 fi
905 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
906 fi
907
908 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
909 echo "configure:910: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
910
911 ac_ext=c
912 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
913 ac_cpp='$CPP $CPPFLAGS'
914 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
915 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
916 cross_compiling=$ac_cv_prog_cc_cross
917
918 cat > conftest.$ac_ext << EOF
919
920 #line 921 "configure"
921 #include "confdefs.h"
922
923 main(){return(0);}
924 EOF
925 if { (eval echo configure:926: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
926 ac_cv_prog_cc_works=yes
927 # If we can't run a trivial program, we are probably using a cross compiler.
928 if (./conftest; exit) 2>/dev/null; then
929 ac_cv_prog_cc_cross=no
930 else
931 ac_cv_prog_cc_cross=yes
932 fi
933 else
934 echo "configure: failed program was:" >&5
935 cat conftest.$ac_ext >&5
936 ac_cv_prog_cc_works=no
937 fi
938 rm -fr conftest*
939 ac_ext=c
940 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
941 ac_cpp='$CPP $CPPFLAGS'
942 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
943 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
944 cross_compiling=$ac_cv_prog_cc_cross
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 else
977 GCC=
978 fi
979
980 ac_test_CFLAGS="${CFLAGS+set}"
981 ac_save_CFLAGS="$CFLAGS"
982 CFLAGS=
983 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
984 echo "configure:985: checking whether ${CC-cc} accepts -g" >&5
985 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
986 echo $ac_n "(cached) $ac_c" 1>&6
987 else
988 echo 'void f(){}' > conftest.c
989 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
990 ac_cv_prog_cc_g=yes
991 else
992 ac_cv_prog_cc_g=no
993 fi
994 rm -f conftest*
995
996 fi
997
998 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
999 if test "$ac_test_CFLAGS" = set; then
1000 CFLAGS="$ac_save_CFLAGS"
1001 elif test $ac_cv_prog_cc_g = yes; then
1002 if test "$GCC" = yes; then
1003 CFLAGS="-g -O2"
1004 else
1005 CFLAGS="-g"
1006 fi
1007 else
1008 if test "$GCC" = yes; then
1009 CFLAGS="-O2"
1010 else
1011 CFLAGS=
1012 fi
1013 fi
1014
1015 # Find a good install program. We prefer a C program (faster),
1016 # so one script is as good as another. But avoid the broken or
1017 # incompatible versions:
1018 # SysV /etc/install, /usr/sbin/install
1019 # SunOS /usr/etc/install
1020 # IRIX /sbin/install
1021 # AIX /bin/install
1022 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1023 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1024 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1025 # ./install, which can be erroneously created by make from ./install.sh.
1026 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1027 echo "configure:1028: checking for a BSD compatible install" >&5
1028 if test -z "$INSTALL"; then
1029 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1030 echo $ac_n "(cached) $ac_c" 1>&6
1031 else
1032 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
1033 for ac_dir in $PATH; do
1034 # Account for people who put trailing slashes in PATH elements.
1035 case "$ac_dir/" in
1036 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1037 *)
1038 # OSF1 and SCO ODT 3.0 have their own names for install.
1039 # Don't use installbsd from OSF since it installs stuff as root
1040 # by default.
1041 for ac_prog in ginstall scoinst install; do
1042 if test -f $ac_dir/$ac_prog; then
1043 if test $ac_prog = install &&
1044 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1045 # AIX install. It has an incompatible calling convention.
1046 :
1047 else
1048 ac_cv_path_install="$ac_dir/$ac_prog -c"
1049 break 2
1050 fi
1051 fi
1052 done
1053 ;;
1054 esac
1055 done
1056 IFS="$ac_save_IFS"
1057
1058 fi
1059 if test "${ac_cv_path_install+set}" = set; then
1060 INSTALL="$ac_cv_path_install"
1061 else
1062 # As a last resort, use the slow shell script. We don't cache a
1063 # path for INSTALL within a source directory, because that will
1064 # break other packages using the cache if that directory is
1065 # removed, or if the path is relative.
1066 INSTALL="$ac_install_sh"
1067 fi
1068 fi
1069 echo "$ac_t""$INSTALL" 1>&6
1070
1071 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1072 # It thinks the first close brace ends the variable substitution.
1073 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1074
1075 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1076
1077 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1078
1079 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1080 echo "configure:1081: checking how to run the C preprocessor" >&5
1081 # On Suns, sometimes $CPP names a directory.
1082 if test -n "$CPP" && test -d "$CPP"; then
1083 CPP=
1084 fi
1085 if test -z "$CPP"; then
1086 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1087 echo $ac_n "(cached) $ac_c" 1>&6
1088 else
1089 # This must be in double quotes, not single quotes, because CPP may get
1090 # substituted into the Makefile and "${CC-cc}" will confuse make.
1091 CPP="${CC-cc} -E"
1092 # On the NeXT, cc -E runs the code through the compiler's parser,
1093 # not just through cpp.
1094 cat > conftest.$ac_ext <<EOF
1095 #line 1096 "configure"
1096 #include "confdefs.h"
1097 #include <assert.h>
1098 Syntax Error
1099 EOF
1100 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1101 { (eval echo configure:1102: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1102 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1103 if test -z "$ac_err"; then
1104 :
1105 else
1106 echo "$ac_err" >&5
1107 echo "configure: failed program was:" >&5
1108 cat conftest.$ac_ext >&5
1109 rm -rf conftest*
1110 CPP="${CC-cc} -E -traditional-cpp"
1111 cat > conftest.$ac_ext <<EOF
1112 #line 1113 "configure"
1113 #include "confdefs.h"
1114 #include <assert.h>
1115 Syntax Error
1116 EOF
1117 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1118 { (eval echo configure:1119: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1119 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1120 if test -z "$ac_err"; then
1121 :
1122 else
1123 echo "$ac_err" >&5
1124 echo "configure: failed program was:" >&5
1125 cat conftest.$ac_ext >&5
1126 rm -rf conftest*
1127 CPP="${CC-cc} -nologo -E"
1128 cat > conftest.$ac_ext <<EOF
1129 #line 1130 "configure"
1130 #include "confdefs.h"
1131 #include <assert.h>
1132 Syntax Error
1133 EOF
1134 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1135 { (eval echo configure:1136: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1136 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1137 if test -z "$ac_err"; then
1138 :
1139 else
1140 echo "$ac_err" >&5
1141 echo "configure: failed program was:" >&5
1142 cat conftest.$ac_ext >&5
1143 rm -rf conftest*
1144 CPP=/lib/cpp
1145 fi
1146 rm -f conftest*
1147 fi
1148 rm -f conftest*
1149 fi
1150 rm -f conftest*
1151 ac_cv_prog_CPP="$CPP"
1152 fi
1153 CPP="$ac_cv_prog_CPP"
1154 else
1155 ac_cv_prog_CPP="$CPP"
1156 fi
1157 echo "$ac_t""$CPP" 1>&6
1158
1159 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1160 echo "configure:1161: checking for ANSI C header files" >&5
1161 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1162 echo $ac_n "(cached) $ac_c" 1>&6
1163 else
1164 cat > conftest.$ac_ext <<EOF
1165 #line 1166 "configure"
1166 #include "confdefs.h"
1167 #include <stdlib.h>
1168 #include <stdarg.h>
1169 #include <string.h>
1170 #include <float.h>
1171 EOF
1172 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1173 { (eval echo configure:1174: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1174 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1175 if test -z "$ac_err"; then
1176 rm -rf conftest*
1177 ac_cv_header_stdc=yes
1178 else
1179 echo "$ac_err" >&5
1180 echo "configure: failed program was:" >&5
1181 cat conftest.$ac_ext >&5
1182 rm -rf conftest*
1183 ac_cv_header_stdc=no
1184 fi
1185 rm -f conftest*
1186
1187 if test $ac_cv_header_stdc = yes; then
1188 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1189 cat > conftest.$ac_ext <<EOF
1190 #line 1191 "configure"
1191 #include "confdefs.h"
1192 #include <string.h>
1193 EOF
1194 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1195 egrep "memchr" >/dev/null 2>&1; then
1196 :
1197 else
1198 rm -rf conftest*
1199 ac_cv_header_stdc=no
1200 fi
1201 rm -f conftest*
1202
1203 fi
1204
1205 if test $ac_cv_header_stdc = yes; then
1206 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1207 cat > conftest.$ac_ext <<EOF
1208 #line 1209 "configure"
1209 #include "confdefs.h"
1210 #include <stdlib.h>
1211 EOF
1212 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1213 egrep "free" >/dev/null 2>&1; then
1214 :
1215 else
1216 rm -rf conftest*
1217 ac_cv_header_stdc=no
1218 fi
1219 rm -f conftest*
1220
1221 fi
1222
1223 if test $ac_cv_header_stdc = yes; then
1224 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1225 if test "$cross_compiling" = yes; then
1226 :
1227 else
1228 cat > conftest.$ac_ext <<EOF
1229 #line 1230 "configure"
1230 #include "confdefs.h"
1231 #include <ctype.h>
1232 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1233 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1234 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1235 int main () { int i; for (i = 0; i < 256; i++)
1236 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1237 exit (0); }
1238
1239 EOF
1240 if { (eval echo configure:1241: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1241 then
1242 :
1243 else
1244 echo "configure: failed program was:" >&5
1245 cat conftest.$ac_ext >&5
1246 rm -fr conftest*
1247 ac_cv_header_stdc=no
1248 fi
1249 rm -fr conftest*
1250 fi
1251
1252 fi
1253 fi
1254
1255 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1256 if test $ac_cv_header_stdc = yes; then
1257 cat >> confdefs.h <<\EOF
1258 #define STDC_HEADERS 1
1259 EOF
1260
1261 fi
1262
1263
1264 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
1265 echo "configure:1266: checking whether ${MAKE-make} sets \${MAKE}" >&5
1266 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1267 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1268 echo $ac_n "(cached) $ac_c" 1>&6
1269 else
1270 cat > conftestmake <<\EOF
1271 all:
1272 @echo 'ac_maketemp="${MAKE}"'
1273 EOF
1274 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1275 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1276 if test -n "$ac_maketemp"; then
1277 eval ac_cv_prog_make_${ac_make}_set=yes
1278 else
1279 eval ac_cv_prog_make_${ac_make}_set=no
1280 fi
1281 rm -f conftestmake
1282 fi
1283 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1284 echo "$ac_t""yes" 1>&6
1285 SET_MAKE=
1286 else
1287 echo "$ac_t""no" 1>&6
1288 SET_MAKE="MAKE=${MAKE-make}"
1289 fi
1290
1291
1292 for ac_hdr in fcntl.h limits.h malloc.h sys/ioctl.h sys/time.h unistd.h
1293 do
1294 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1295 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1296 echo "configure:1297: checking for $ac_hdr" >&5
1297 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1298 echo $ac_n "(cached) $ac_c" 1>&6
1299 else
1300 cat > conftest.$ac_ext <<EOF
1301 #line 1302 "configure"
1302 #include "confdefs.h"
1303 #include <$ac_hdr>
1304 EOF
1305 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1306 { (eval echo configure:1307: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1307 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1308 if test -z "$ac_err"; then
1309 rm -rf conftest*
1310 eval "ac_cv_header_$ac_safe=yes"
1311 else
1312 echo "$ac_err" >&5
1313 echo "configure: failed program was:" >&5
1314 cat conftest.$ac_ext >&5
1315 rm -rf conftest*
1316 eval "ac_cv_header_$ac_safe=no"
1317 fi
1318 rm -f conftest*
1319 fi
1320 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1321 echo "$ac_t""yes" 1>&6
1322 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1323 cat >> confdefs.h <<EOF
1324 #define $ac_tr_hdr 1
1325 EOF
1326
1327 else
1328 echo "$ac_t""no" 1>&6
1329 fi
1330 done
1331
1332
1333 echo $ac_n "checking for working const""... $ac_c" 1>&6
1334 echo "configure:1335: checking for working const" >&5
1335 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
1336 echo $ac_n "(cached) $ac_c" 1>&6
1337 else
1338 cat > conftest.$ac_ext <<EOF
1339 #line 1340 "configure"
1340 #include "confdefs.h"
1341
1342 int main() {
1343
1344 /* Ultrix mips cc rejects this. */
1345 typedef int charset[2]; const charset x;
1346 /* SunOS 4.1.1 cc rejects this. */
1347 char const *const *ccp;
1348 char **p;
1349 /* NEC SVR4.0.2 mips cc rejects this. */
1350 struct point {int x, y;};
1351 static struct point const zero = {0,0};
1352 /* AIX XL C 1.02.0.0 rejects this.
1353 It does not let you subtract one const X* pointer from another in an arm
1354 of an if-expression whose if-part is not a constant expression */
1355 const char *g = "string";
1356 ccp = &g + (g ? g-g : 0);
1357 /* HPUX 7.0 cc rejects these. */
1358 ++ccp;
1359 p = (char**) ccp;
1360 ccp = (char const *const *) p;
1361 { /* SCO 3.2v4 cc rejects this. */
1362 char *t;
1363 char const *s = 0 ? (char *) 0 : (char const *) 0;
1364
1365 *t++ = 0;
1366 }
1367 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
1368 int x[] = {25, 17};
1369 const int *foo = &x[0];
1370 ++foo;
1371 }
1372 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
1373 typedef const int *iptr;
1374 iptr p = 0;
1375 ++p;
1376 }
1377 { /* AIX XL C 1.02.0.0 rejects this saying
1378 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
1379 struct s { int j; const int *ap[3]; };
1380 struct s *b; b->j = 5;
1381 }
1382 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
1383 const int foo = 10;
1384 }
1385
1386 ; return 0; }
1387 EOF
1388 if { (eval echo configure:1389: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1389 rm -rf conftest*
1390 ac_cv_c_const=yes
1391 else
1392 echo "configure: failed program was:" >&5
1393 cat conftest.$ac_ext >&5
1394 rm -rf conftest*
1395 ac_cv_c_const=no
1396 fi
1397 rm -f conftest*
1398 fi
1399
1400 echo "$ac_t""$ac_cv_c_const" 1>&6
1401 if test $ac_cv_c_const = no; then
1402 cat >> confdefs.h <<\EOF
1403 #define const
1404 EOF
1405
1406 fi
1407
1408 echo $ac_n "checking for inline""... $ac_c" 1>&6
1409 echo "configure:1410: checking for inline" >&5
1410 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
1411 echo $ac_n "(cached) $ac_c" 1>&6
1412 else
1413 ac_cv_c_inline=no
1414 for ac_kw in inline __inline__ __inline; do
1415 cat > conftest.$ac_ext <<EOF
1416 #line 1417 "configure"
1417 #include "confdefs.h"
1418
1419 int main() {
1420 } $ac_kw foo() {
1421 ; return 0; }
1422 EOF
1423 if { (eval echo configure:1424: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1424 rm -rf conftest*
1425 ac_cv_c_inline=$ac_kw; break
1426 else
1427 echo "configure: failed program was:" >&5
1428 cat conftest.$ac_ext >&5
1429 fi
1430 rm -f conftest*
1431 done
1432
1433 fi
1434
1435 echo "$ac_t""$ac_cv_c_inline" 1>&6
1436 case "$ac_cv_c_inline" in
1437 inline | yes) ;;
1438 no) cat >> confdefs.h <<\EOF
1439 #define inline
1440 EOF
1441 ;;
1442 *) cat >> confdefs.h <<EOF
1443 #define inline $ac_cv_c_inline
1444 EOF
1445 ;;
1446 esac
1447
1448 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
1449 echo "configure:1450: checking for pid_t" >&5
1450 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
1451 echo $ac_n "(cached) $ac_c" 1>&6
1452 else
1453 cat > conftest.$ac_ext <<EOF
1454 #line 1455 "configure"
1455 #include "confdefs.h"
1456 #include <sys/types.h>
1457 #if STDC_HEADERS
1458 #include <stdlib.h>
1459 #include <stddef.h>
1460 #endif
1461 EOF
1462 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1463 egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1464 rm -rf conftest*
1465 ac_cv_type_pid_t=yes
1466 else
1467 rm -rf conftest*
1468 ac_cv_type_pid_t=no
1469 fi
1470 rm -f conftest*
1471
1472 fi
1473 echo "$ac_t""$ac_cv_type_pid_t" 1>&6
1474 if test $ac_cv_type_pid_t = no; then
1475 cat >> confdefs.h <<\EOF
1476 #define pid_t int
1477 EOF
1478
1479 fi
1480
1481 echo $ac_n "checking for size_t""... $ac_c" 1>&6
1482 echo "configure:1483: checking for size_t" >&5
1483 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
1484 echo $ac_n "(cached) $ac_c" 1>&6
1485 else
1486 cat > conftest.$ac_ext <<EOF
1487 #line 1488 "configure"
1488 #include "confdefs.h"
1489 #include <sys/types.h>
1490 #if STDC_HEADERS
1491 #include <stdlib.h>
1492 #include <stddef.h>
1493 #endif
1494 EOF
1495 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1496 egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1497 rm -rf conftest*
1498 ac_cv_type_size_t=yes
1499 else
1500 rm -rf conftest*
1501 ac_cv_type_size_t=no
1502 fi
1503 rm -f conftest*
1504
1505 fi
1506 echo "$ac_t""$ac_cv_type_size_t" 1>&6
1507 if test $ac_cv_type_size_t = no; then
1508 cat >> confdefs.h <<\EOF
1509 #define size_t unsigned
1510 EOF
1511
1512 fi
1513
1514 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
1515 echo "configure:1516: checking whether time.h and sys/time.h may both be included" >&5
1516 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
1517 echo $ac_n "(cached) $ac_c" 1>&6
1518 else
1519 cat > conftest.$ac_ext <<EOF
1520 #line 1521 "configure"
1521 #include "confdefs.h"
1522 #include <sys/types.h>
1523 #include <sys/time.h>
1524 #include <time.h>
1525 int main() {
1526 struct tm *tp;
1527 ; return 0; }
1528 EOF
1529 if { (eval echo configure:1530: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1530 rm -rf conftest*
1531 ac_cv_header_time=yes
1532 else
1533 echo "configure: failed program was:" >&5
1534 cat conftest.$ac_ext >&5
1535 rm -rf conftest*
1536 ac_cv_header_time=no
1537 fi
1538 rm -f conftest*
1539 fi
1540
1541 echo "$ac_t""$ac_cv_header_time" 1>&6
1542 if test $ac_cv_header_time = yes; then
1543 cat >> confdefs.h <<\EOF
1544 #define TIME_WITH_SYS_TIME 1
1545 EOF
1546
1547 fi
1548
1549
1550 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
1551 # for constant arguments. Useless!
1552 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
1553 echo "configure:1554: checking for working alloca.h" >&5
1554 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
1555 echo $ac_n "(cached) $ac_c" 1>&6
1556 else
1557 cat > conftest.$ac_ext <<EOF
1558 #line 1559 "configure"
1559 #include "confdefs.h"
1560 #include <alloca.h>
1561 int main() {
1562 char *p = alloca(2 * sizeof(int));
1563 ; return 0; }
1564 EOF
1565 if { (eval echo configure:1566: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1566 rm -rf conftest*
1567 ac_cv_header_alloca_h=yes
1568 else
1569 echo "configure: failed program was:" >&5
1570 cat conftest.$ac_ext >&5
1571 rm -rf conftest*
1572 ac_cv_header_alloca_h=no
1573 fi
1574 rm -f conftest*
1575 fi
1576
1577 echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
1578 if test $ac_cv_header_alloca_h = yes; then
1579 cat >> confdefs.h <<\EOF
1580 #define HAVE_ALLOCA_H 1
1581 EOF
1582
1583 fi
1584
1585 echo $ac_n "checking for alloca""... $ac_c" 1>&6
1586 echo "configure:1587: checking for alloca" >&5
1587 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
1588 echo $ac_n "(cached) $ac_c" 1>&6
1589 else
1590 cat > conftest.$ac_ext <<EOF
1591 #line 1592 "configure"
1592 #include "confdefs.h"
1593
1594 #ifdef __GNUC__
1595 # define alloca __builtin_alloca
1596 #else
1597 # ifdef _MSC_VER
1598 # include <malloc.h>
1599 # define alloca _alloca
1600 # else
1601 # if HAVE_ALLOCA_H
1602 # include <alloca.h>
1603 # else
1604 # ifdef _AIX
1605 #pragma alloca
1606 # else
1607 # ifndef alloca /* predefined by HP cc +Olibcalls */
1608 char *alloca ();
1609 # endif
1610 # endif
1611 # endif
1612 # endif
1613 #endif
1614
1615 int main() {
1616 char *p = (char *) alloca(1);
1617 ; return 0; }
1618 EOF
1619 if { (eval echo configure:1620: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1620 rm -rf conftest*
1621 ac_cv_func_alloca_works=yes
1622 else
1623 echo "configure: failed program was:" >&5
1624 cat conftest.$ac_ext >&5
1625 rm -rf conftest*
1626 ac_cv_func_alloca_works=no
1627 fi
1628 rm -f conftest*
1629 fi
1630
1631 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
1632 if test $ac_cv_func_alloca_works = yes; then
1633 cat >> confdefs.h <<\EOF
1634 #define HAVE_ALLOCA 1
1635 EOF
1636
1637 fi
1638
1639 if test $ac_cv_func_alloca_works = no; then
1640 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
1641 # that cause trouble. Some versions do not even contain alloca or
1642 # contain a buggy version. If you still want to use their alloca,
1643 # use ar to extract alloca.o from them instead of compiling alloca.c.
1644 ALLOCA=alloca.${ac_objext}
1645 cat >> confdefs.h <<\EOF
1646 #define C_ALLOCA 1
1647 EOF
1648
1649
1650 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
1651 echo "configure:1652: checking whether alloca needs Cray hooks" >&5
1652 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
1653 echo $ac_n "(cached) $ac_c" 1>&6
1654 else
1655 cat > conftest.$ac_ext <<EOF
1656 #line 1657 "configure"
1657 #include "confdefs.h"
1658 #if defined(CRAY) && ! defined(CRAY2)
1659 webecray
1660 #else
1661 wenotbecray
1662 #endif
1663
1664 EOF
1665 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1666 egrep "webecray" >/dev/null 2>&1; then
1667 rm -rf conftest*
1668 ac_cv_os_cray=yes
1669 else
1670 rm -rf conftest*
1671 ac_cv_os_cray=no
1672 fi
1673 rm -f conftest*
1674
1675 fi
1676
1677 echo "$ac_t""$ac_cv_os_cray" 1>&6
1678 if test $ac_cv_os_cray = yes; then
1679 for ac_func in _getb67 GETB67 getb67; do
1680 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1681 echo "configure:1682: checking for $ac_func" >&5
1682 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1683 echo $ac_n "(cached) $ac_c" 1>&6
1684 else
1685 cat > conftest.$ac_ext <<EOF
1686 #line 1687 "configure"
1687 #include "confdefs.h"
1688 /* System header to define __stub macros and hopefully few prototypes,
1689 which can conflict with char $ac_func(); below. */
1690 #include <assert.h>
1691 /* Override any gcc2 internal prototype to avoid an error. */
1692 /* We use char because int might match the return type of a gcc2
1693 builtin and then its argument prototype would still apply. */
1694 char $ac_func();
1695
1696 int main() {
1697
1698 /* The GNU C library defines this for functions which it implements
1699 to always fail with ENOSYS. Some functions are actually named
1700 something starting with __ and the normal name is an alias. */
1701 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1702 choke me
1703 #else
1704 $ac_func();
1705 #endif
1706
1707 ; return 0; }
1708 EOF
1709 if { (eval echo configure:1710: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1710 rm -rf conftest*
1711 eval "ac_cv_func_$ac_func=yes"
1712 else
1713 echo "configure: failed program was:" >&5
1714 cat conftest.$ac_ext >&5
1715 rm -rf conftest*
1716 eval "ac_cv_func_$ac_func=no"
1717 fi
1718 rm -f conftest*
1719 fi
1720
1721 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1722 echo "$ac_t""yes" 1>&6
1723 cat >> confdefs.h <<EOF
1724 #define CRAY_STACKSEG_END $ac_func
1725 EOF
1726
1727 break
1728 else
1729 echo "$ac_t""no" 1>&6
1730 fi
1731
1732 done
1733 fi
1734
1735 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
1736 echo "configure:1737: checking stack direction for C alloca" >&5
1737 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
1738 echo $ac_n "(cached) $ac_c" 1>&6
1739 else
1740 if test "$cross_compiling" = yes; then
1741 ac_cv_c_stack_direction=0
1742 else
1743 cat > conftest.$ac_ext <<EOF
1744 #line 1745 "configure"
1745 #include "confdefs.h"
1746 find_stack_direction ()
1747 {
1748 static char *addr = 0;
1749 auto char dummy;
1750 if (addr == 0)
1751 {
1752 addr = &dummy;
1753 return find_stack_direction ();
1754 }
1755 else
1756 return (&dummy > addr) ? 1 : -1;
1757 }
1758 main ()
1759 {
1760 exit (find_stack_direction() < 0);
1761 }
1762 EOF
1763 if { (eval echo configure:1764: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1764 then
1765 ac_cv_c_stack_direction=1
1766 else
1767 echo "configure: failed program was:" >&5
1768 cat conftest.$ac_ext >&5
1769 rm -fr conftest*
1770 ac_cv_c_stack_direction=-1
1771 fi
1772 rm -fr conftest*
1773 fi
1774
1775 fi
1776
1777 echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
1778 cat >> confdefs.h <<EOF
1779 #define STACK_DIRECTION $ac_cv_c_stack_direction
1780 EOF
1781
1782 fi
1783
1784 if test $ac_cv_prog_gcc = yes; then
1785 echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6
1786 echo "configure:1787: checking whether ${CC-cc} needs -traditional" >&5
1787 if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then
1788 echo $ac_n "(cached) $ac_c" 1>&6
1789 else
1790 ac_pattern="Autoconf.*'x'"
1791 cat > conftest.$ac_ext <<EOF
1792 #line 1793 "configure"
1793 #include "confdefs.h"
1794 #include <sgtty.h>
1795 Autoconf TIOCGETP
1796 EOF
1797 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1798 egrep "$ac_pattern" >/dev/null 2>&1; then
1799 rm -rf conftest*
1800 ac_cv_prog_gcc_traditional=yes
1801 else
1802 rm -rf conftest*
1803 ac_cv_prog_gcc_traditional=no
1804 fi
1805 rm -f conftest*
1806
1807
1808 if test $ac_cv_prog_gcc_traditional = no; then
1809 cat > conftest.$ac_ext <<EOF
1810 #line 1811 "configure"
1811 #include "confdefs.h"
1812 #include <termio.h>
1813 Autoconf TCGETA
1814 EOF
1815 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1816 egrep "$ac_pattern" >/dev/null 2>&1; then
1817 rm -rf conftest*
1818 ac_cv_prog_gcc_traditional=yes
1819 fi
1820 rm -f conftest*
1821
1822 fi
1823 fi
1824
1825 echo "$ac_t""$ac_cv_prog_gcc_traditional" 1>&6
1826 if test $ac_cv_prog_gcc_traditional = yes; then
1827 CC="$CC -traditional"
1828 fi
1829 fi
1830
1831 echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
1832 echo "configure:1833: checking for 8-bit clean memcmp" >&5
1833 if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then
1834 echo $ac_n "(cached) $ac_c" 1>&6
1835 else
1836 if test "$cross_compiling" = yes; then
1837 ac_cv_func_memcmp_clean=no
1838 else
1839 cat > conftest.$ac_ext <<EOF
1840 #line 1841 "configure"
1841 #include "confdefs.h"
1842
1843 main()
1844 {
1845 char c0 = 0x40, c1 = 0x80, c2 = 0x81;
1846 exit(memcmp(&c0, &c2, 1) < 0 && memcmp(&c1, &c2, 1) < 0 ? 0 : 1);
1847 }
1848
1849 EOF
1850 if { (eval echo configure:1851: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1851 then
1852 ac_cv_func_memcmp_clean=yes
1853 else
1854 echo "configure: failed program was:" >&5
1855 cat conftest.$ac_ext >&5
1856 rm -fr conftest*
1857 ac_cv_func_memcmp_clean=no
1858 fi
1859 rm -fr conftest*
1860 fi
1861
1862 fi
1863
1864 echo "$ac_t""$ac_cv_func_memcmp_clean" 1>&6
1865 test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.${ac_objext}"
1866
1867 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
1868 echo "configure:1869: checking return type of signal handlers" >&5
1869 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
1870 echo $ac_n "(cached) $ac_c" 1>&6
1871 else
1872 cat > conftest.$ac_ext <<EOF
1873 #line 1874 "configure"
1874 #include "confdefs.h"
1875 #include <sys/types.h>
1876 #include <signal.h>
1877 #ifdef signal
1878 #undef signal
1879 #endif
1880 #ifdef __cplusplus
1881 extern "C" void (*signal (int, void (*)(int)))(int);
1882 #else
1883 void (*signal ()) ();
1884 #endif
1885
1886 int main() {
1887 int i;
1888 ; return 0; }
1889 EOF
1890 if { (eval echo configure:1891: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1891 rm -rf conftest*
1892 ac_cv_type_signal=void
1893 else
1894 echo "configure: failed program was:" >&5
1895 cat conftest.$ac_ext >&5
1896 rm -rf conftest*
1897 ac_cv_type_signal=int
1898 fi
1899 rm -f conftest*
1900 fi
1901
1902 echo "$ac_t""$ac_cv_type_signal" 1>&6
1903 cat >> confdefs.h <<EOF
1904 #define RETSIGTYPE $ac_cv_type_signal
1905 EOF
1906
1907
1908
1909 for ac_func in ftime gettimeofday select strdup strstr strtol
1910 do
1911 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1912 echo "configure:1913: checking for $ac_func" >&5
1913 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1914 echo $ac_n "(cached) $ac_c" 1>&6
1915 else
1916 cat > conftest.$ac_ext <<EOF
1917 #line 1918 "configure"
1918 #include "confdefs.h"
1919 /* System header to define __stub macros and hopefully few prototypes,
1920 which can conflict with char $ac_func(); below. */
1921 #include <assert.h>
1922 /* Override any gcc2 internal prototype to avoid an error. */
1923 /* We use char because int might match the return type of a gcc2
1924 builtin and then its argument prototype would still apply. */
1925 char $ac_func();
1926
1927 int main() {
1928
1929 /* The GNU C library defines this for functions which it implements
1930 to always fail with ENOSYS. Some functions are actually named
1931 something starting with __ and the normal name is an alias. */
1932 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1933 choke me
1934 #else
1935 $ac_func();
1936 #endif
1937
1938 ; return 0; }
1939 EOF
1940 if { (eval echo configure:1941: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1941 rm -rf conftest*
1942 eval "ac_cv_func_$ac_func=yes"
1943 else
1944 echo "configure: failed program was:" >&5
1945 cat conftest.$ac_ext >&5
1946 rm -rf conftest*
1947 eval "ac_cv_func_$ac_func=no"
1948 fi
1949 rm -f conftest*
1950 fi
1951
1952 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1953 echo "$ac_t""yes" 1>&6
1954 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1955 cat >> confdefs.h <<EOF
1956 #define $ac_tr_func 1
1957 EOF
1958
1959 else
1960 echo "$ac_t""no" 1>&6
1961 fi
1962 done
1963
1964
1965 # Check whether --with-aalib-prefix or --without-aalib-prefix was given.
1966 if test "${with_aalib_prefix+set}" = set; then
1967 withval="$with_aalib_prefix"
1968 aalib_prefix="$withval"
1969 else
1970 aalib_prefix=""
1971 fi
1972
1973 # Check whether --with-aalib-exec-prefix or --without-aalib-exec-prefix was given.
1974 if test "${with_aalib_exec_prefix+set}" = set; then
1975 withval="$with_aalib_exec_prefix"
1976 aalib_exec_prefix="$withval"
1977 else
1978 aalib_exec_prefix=""
1979 fi
1980
1981 # Check whether --enable-aalibtest or --disable-aalibtest was given.
1982 if test "${enable_aalibtest+set}" = set; then
1983 enableval="$enable_aalibtest"
1984 :
1985 else
1986 enable_aalibtest=yes
1987 fi
1988
1989
1990 if test x$aalib_exec_prefix != x ; then
1991 aalib_args="$aalib_args --exec-prefix=$aalib_exec_prefix"
1992 if test x${AALIB_CONFIG+set} != xset ; then
1993 AALIB_CONFIG=$aalib_exec_prefix/bin/aalib-config
1994 fi
1995 fi
1996 if test x$aalib_prefix != x ; then
1997 aalib_args="$aalib_args --prefix=$aalib_prefix"
1998 if test x${AALIB_CONFIG+set} != xset ; then
1999 AALIB_CONFIG=$aalib_prefix/bin/aalib-config
2000 fi
2001 fi
2002
2003 # Extract the first word of "aalib-config", so it can be a program name with args.
2004 set dummy aalib-config; ac_word=$2
2005 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2006 echo "configure:2007: checking for $ac_word" >&5
2007 if eval "test \"`echo '$''{'ac_cv_path_AALIB_CONFIG'+set}'`\" = set"; then
2008 echo $ac_n "(cached) $ac_c" 1>&6
2009 else
2010 case "$AALIB_CONFIG" in
2011 /*)
2012 ac_cv_path_AALIB_CONFIG="$AALIB_CONFIG" # Let the user override the test with a path.
2013 ;;
2014 ?:/*)
2015 ac_cv_path_AALIB_CONFIG="$AALIB_CONFIG" # Let the user override the test with a dos path.
2016 ;;
2017 *)
2018 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2019 ac_dummy="$PATH"
2020 for ac_dir in $ac_dummy; do
2021 test -z "$ac_dir" && ac_dir=.
2022 if test -f $ac_dir/$ac_word; then
2023 ac_cv_path_AALIB_CONFIG="$ac_dir/$ac_word"
2024 break
2025 fi
2026 done
2027 IFS="$ac_save_ifs"
2028 test -z "$ac_cv_path_AALIB_CONFIG" && ac_cv_path_AALIB_CONFIG="no"
2029 ;;
2030 esac
2031 fi
2032 AALIB_CONFIG="$ac_cv_path_AALIB_CONFIG"
2033 if test -n "$AALIB_CONFIG"; then
2034 echo "$ac_t""$AALIB_CONFIG" 1>&6
2035 else
2036 echo "$ac_t""no" 1>&6
2037 fi
2038
2039 min_aalib_version=1.4.0
2040 echo $ac_n "checking for AALIB - version >= $min_aalib_version""... $ac_c" 1>&6
2041 echo "configure:2042: checking for AALIB - version >= $min_aalib_version" >&5
2042 no_aalib=""
2043 if test "$AALIB_CONFIG" = "no" ; then
2044 no_aalib=yes
2045 else
2046 AALIB_CFLAGS=`$AALIB_CONFIG $aalibconf_args --cflags`
2047 AALIB_LIBS=`$AALIB_CONFIG $aalibconf_args --libs`
2048
2049 aalib_major_version=`$AALIB_CONFIG $aalib_args --version | \
2050 sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'`
2051 aalib_minor_version=`$AALIB_CONFIG $aalib_args --version | \
2052 sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'`
2053 aalib_micro_version=`$AALIB_CONFIG $aalib_config_args --version | \
2054 sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'`
2055 if test "x$enable_aalibtest" = "xyes" ; then
2056 ac_save_CFLAGS="$CFLAGS"
2057 ac_save_LIBS="$LIBS"
2058 CFLAGS="$CFLAGS $AALIB_CFLAGS"
2059 LIBS="$LIBS $AALIB_LIBS"
2060 rm -f conf.aalibtest
2061 if test "$cross_compiling" = yes; then
2062 echo $ac_n "cross compiling; assumed OK... $ac_c"
2063 else
2064 cat > conftest.$ac_ext <<EOF
2065 #line 2066 "configure"
2066 #include "confdefs.h"
2067
2068 #include <stdio.h>
2069 #include <stdlib.h>
2070 #include <string.h>
2071 #include "aalib.h"
2072
2073 char*
2074 my_strdup (char *str)
2075 {
2076 char *new_str;
2077
2078 if (str)
2079 {
2080 new_str = (char *)malloc ((strlen (str) + 1) * sizeof(char));
2081 strcpy (new_str, str);
2082 }
2083 else
2084 new_str = NULL;
2085
2086 return new_str;
2087 }
2088
2089 int main (int argc, char *argv[])
2090 {
2091 int major, minor, micro;
2092 char *tmp_version;
2093
2094 /* This hangs on some systems (?)
2095 system ("touch conf.aalibtest");
2096 */
2097 { FILE *fp = fopen("conf.aalibtest", "a"); if ( fp ) fclose(fp); }
2098
2099 /* HP/UX 9 (%@#!) writes to sscanf strings */
2100 tmp_version = my_strdup("$min_aalib_version");
2101 if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
2102 printf("%s, bad version string\n", "$min_aalib_version");
2103 exit(1);
2104 }
2105
2106 if (($aalib_major_version > major) ||
2107 (($aalib_major_version == major) && ($aalib_minor_version > minor)) ||
2108 (($aalib_major_version == major) && ($aalib_minor_version == minor) && ($aalib_micro_version >= micro)))
2109 {
2110 return 0;
2111 }
2112 else
2113 {
2114 printf("\n*** 'aalib-config --version' returned %d.%d.%d, but the minimum version\n", $aalib_major_version, $aalib_minor_version, $aalib_micro_version);
2115 printf("*** of AALIB required is %d.%d.%d. If aalib-config is correct, then it is\n", major, minor, micro);
2116 printf("*** best to upgrade to the required version.\n");
2117 printf("*** If aalib-config was wrong, set the environment variable AALIB_CONFIG\n");
2118 printf("*** to point to the correct copy of aalib-config, and remove the file\n");
2119 printf("*** config.cache before re-running configure\n");
2120 return 1;
2121 }
2122 }
2123
2124
2125 EOF
2126 if { (eval echo configure:2127: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2127 then
2128 :
2129 else
2130 echo "configure: failed program was:" >&5
2131 cat conftest.$ac_ext >&5
2132 rm -fr conftest*
2133 no_aalib=yes
2134 fi
2135 rm -fr conftest*
2136 fi
2137
2138 CFLAGS="$ac_save_CFLAGS"
2139 LIBS="$ac_save_LIBS"
2140 fi
2141 fi
2142 if test "x$no_aalib" = x ; then
2143 echo "$ac_t""yes" 1>&6
2144 :
2145 else
2146 echo "$ac_t""no" 1>&6
2147 if test "$AALIB_CONFIG" = "no" ; then
2148 echo "*** The aalib-config script installed by AALIB could not be found"
2149 echo "*** If AALIB was installed in PREFIX, make sure PREFIX/bin is in"
2150 echo "*** your path, or set the AALIB_CONFIG environment variable to the"
2151 echo "*** full path to aalib-config."
2152 else
2153 if test -f conf.aalibtest ; then
2154 :
2155 else
2156 echo "*** Could not run AALIB test program, checking why..."
2157 CFLAGS="$CFLAGS $AALIB_CFLAGS"
2158 LIBS="$LIBS $AALIB_LIBS"
2159 cat > conftest.$ac_ext <<EOF
2160 #line 2161 "configure"
2161 #include "confdefs.h"
2162
2163 #include <stdio.h>
2164 #include "AALIB.h"
2165
2166 int main() {
2167 return 0;
2168 ; return 0; }
2169 EOF
2170 if { (eval echo configure:2171: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2171 rm -rf conftest*
2172 echo "*** The test program compiled, but did not run. This usually means"
2173 echo "*** that the run-time linker is not finding AALIB or finding the wrong"
2174 echo "*** version of AALIB. If it is not finding AALIB, you'll need to set your"
2175 echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
2176 echo "*** to the installed location Also, make sure you have run ldconfig if that"
2177 echo "*** is required on your system"
2178 echo "***"
2179 echo "*** If you have an old version installed, it is best to remove it, although"
2180 echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
2181 else
2182 echo "configure: failed program was:" >&5
2183 cat conftest.$ac_ext >&5
2184 rm -rf conftest*
2185 echo "*** The test program failed to compile or link. See the file config.log for the"
2186 echo "*** exact error that occured. This usually means AALIB was incorrectly installed"
2187 echo "*** or that you have moved AALIB since it was installed. In the latter case, you"
2188 echo "*** may want to edit the aalib-config script: $AALIB_CONFIG"
2189 fi
2190 rm -f conftest*
2191 CFLAGS="$ac_save_CFLAGS"
2192 LIBS="$ac_save_LIBS"
2193 fi
2194 fi
2195 AALIB_CFLAGS=""
2196 AALIB_LIBS=""
2197 { echo "configure: error: *** AALIB >= 1.4.0 not installed - please install first ***" 1>&2; exit 1; }
2198 fi
2199
2200
2201 rm -f conf.aalibtest
2202
2203 CFLAGS="$CFLAGS $AALIB_CFLAGS"
2204 LIBS="$LIBS $AALIB_LIBS"
2205
2206 SOUNDFILES=""
2207 # Check whether --with-libmikmod-prefix or --without-libmikmod-prefix was given.
2208 if test "${with_libmikmod_prefix+set}" = set; then
2209 withval="$with_libmikmod_prefix"
2210 libmikmod_config_prefix="$withval"
2211 else
2212 libmikmod_config_prefix=""
2213 fi
2214
2215 # Check whether --with-libmikmod-exec-prefix or --without-libmikmod-exec-prefix was given.
2216 if test "${with_libmikmod_exec_prefix+set}" = set; then
2217 withval="$with_libmikmod_exec_prefix"
2218 libmikmod_config_exec_prefix="$withval"
2219 else
2220 libmikmod_config_exec_prefix=""
2221 fi
2222
2223 # Check whether --enable-libmikmodtest or --disable-libmikmodtest was given.
2224 if test "${enable_libmikmodtest+set}" = set; then
2225 enableval="$enable_libmikmodtest"
2226 :
2227 else
2228 enable_libmikmodtest=yes
2229 fi
2230
2231
2232 if test x$libmikmod_config_exec_prefix != x ; then
2233 libmikmod_config_args="$libmikmod_config_args --exec-prefix=$libmikmod_config_exec_prefix"
2234 if test x${LIBMIKMOD_CONFIG+set} != xset ; then
2235 LIBMIKMOD_CONFIG=$libmikmod_config_exec_prefix/bin/libmikmod-config
2236 fi
2237 fi
2238 if test x$libmikmod_config_prefix != x ; then
2239 libmikmod_config_args="$libmikmod_config_args --prefix=$libmikmod_config_prefix"
2240 if test x${LIBMIKMOD_CONFIG+set} != xset ; then
2241 LIBMIKMOD_CONFIG=$libmikmod_config_prefix/bin/libmikmod-config
2242 fi
2243 fi
2244
2245 # Extract the first word of "libmikmod-config", so it can be a program name with args.
2246 set dummy libmikmod-config; ac_word=$2
2247 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2248 echo "configure:2249: checking for $ac_word" >&5
2249 if eval "test \"`echo '$''{'ac_cv_path_LIBMIKMOD_CONFIG'+set}'`\" = set"; then
2250 echo $ac_n "(cached) $ac_c" 1>&6
2251 else
2252 case "$LIBMIKMOD_CONFIG" in
2253 /*)
2254 ac_cv_path_LIBMIKMOD_CONFIG="$LIBMIKMOD_CONFIG" # Let the user override the test with a path.
2255 ;;
2256 ?:/*)
2257 ac_cv_path_LIBMIKMOD_CONFIG="$LIBMIKMOD_CONFIG" # Let the user override the test with a dos path.
2258 ;;
2259 *)
2260 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2261 ac_dummy="$PATH"
2262 for ac_dir in $ac_dummy; do
2263 test -z "$ac_dir" && ac_dir=.
2264 if test -f $ac_dir/$ac_word; then
2265 ac_cv_path_LIBMIKMOD_CONFIG="$ac_dir/$ac_word"
2266 break
2267 fi
2268 done
2269 IFS="$ac_save_ifs"
2270 test -z "$ac_cv_path_LIBMIKMOD_CONFIG" && ac_cv_path_LIBMIKMOD_CONFIG="no"
2271 ;;
2272 esac
2273 fi
2274 LIBMIKMOD_CONFIG="$ac_cv_path_LIBMIKMOD_CONFIG"
2275 if test -n "$LIBMIKMOD_CONFIG"; then
2276 echo "$ac_t""$LIBMIKMOD_CONFIG" 1>&6
2277 else
2278 echo "$ac_t""no" 1>&6
2279 fi
2280
2281 min_libmikmod_version=3.0.0
2282 echo $ac_n "checking for libmikmod - version >= $min_libmikmod_version""... $ac_c" 1>&6
2283 echo "configure:2284: checking for libmikmod - version >= $min_libmikmod_version" >&5
2284 no_libmikmod=""
2285 if test "$LIBMIKMOD_CONFIG" = "no" ; then
2286 no_libmikmod=yes
2287 else
2288 LIBMIKMOD_CFLAGS=`$LIBMIKMOD_CONFIG $libmikmod_config_args --cflags`
2289 LIBMIKMOD_LIBS=`$LIBMIKMOD_CONFIG $libmikmod_config_args --libs`
2290 LIBMIKMOD_LDADD=`$LIBMIKMOD_CONFIG $libmikmod_config_args --ldadd`
2291 libmikmod_config_major_version=`$LIBMIKMOD_CONFIG $libmikmod_config_args --version | \
2292 sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\).*/\1/'`
2293 libmikmod_config_minor_version=`$LIBMIKMOD_CONFIG $libmikmod_config_args --version | \
2294 sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\).*/\2/'`
2295 libmikmod_config_micro_version=`$LIBMIKMOD_CONFIG $libmikmod_config_args --version | \
2296 sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\).*/\3/'`
2297 if test "x$enable_libmikmodtest" = "xyes" ; then
2298 ac_save_CFLAGS="$CFLAGS"
2299 ac_save_LIBS="$LIBS"
2300
2301 ac_ext=c
2302 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2303 ac_cpp='$CPP $CPPFLAGS'
2304 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2305 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2306 cross_compiling=$ac_cv_prog_cc_cross
2307
2308 CFLAGS="$CFLAGS $LIBMIKMOD_CFLAGS $LIBMIKMOD_LDADD"
2309 LIBS="$LIBMIKMOD_LIBS $LIBS"
2310 rm -f conf.mikmodtest
2311 if test "$cross_compiling" = yes; then
2312 echo $ac_n "cross compiling; assumed OK... $ac_c"
2313 else
2314 cat > conftest.$ac_ext <<EOF
2315 #line 2316 "configure"
2316 #include "confdefs.h"
2317
2318 #include <mikmod.h>
2319 #include <stdio.h>
2320 #include <stdlib.h>
2321
2322 char* my_strdup (char *str)
2323 {
2324 char *new_str;
2325
2326 if (str) {
2327 new_str = malloc ((strlen (str) + 1) * sizeof(char));
2328 strcpy (new_str, str);
2329 } else
2330 new_str = NULL;
2331
2332 return new_str;
2333 }
2334
2335 int main()
2336 {
2337 int major,minor,micro;
2338 int libmikmod_major_version,libmikmod_minor_version,libmikmod_micro_version;
2339 char *tmp_version;
2340
2341 system("touch conf.mikmodtest");
2342
2343 /* HP/UX 9 (%@#!) writes to sscanf strings */
2344 tmp_version = my_strdup("$min_libmikmod_version");
2345 if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
2346 printf("%s, bad version string\n", "$min_libmikmod_version");
2347 exit(1);
2348 }
2349
2350 libmikmod_major_version=(MikMod_GetVersion() >> 16) & 255;
2351 libmikmod_minor_version=(MikMod_GetVersion() >> 8) & 255;
2352 libmikmod_micro_version=(MikMod_GetVersion() ) & 255;
2353
2354 if ((libmikmod_major_version != $libmikmod_config_major_version) ||
2355 (libmikmod_minor_version != $libmikmod_config_minor_version) ||
2356 (libmikmod_micro_version != $libmikmod_config_micro_version))
2357 {
2358 printf("\n*** 'libmikmod-config --version' returned %d.%d.%d, but libmikmod (%d.%d.%d)\n",
2359 $libmikmod_config_major_version, $libmikmod_config_minor_version, $libmikmod_config_micro_version,
2360 libmikmod_major_version, libmikmod_minor_version, libmikmod_micro_version);
2361 printf ("*** was found! If libmikmod-config was correct, then it is best\n");
2362 printf ("*** to remove the old version of libmikmod. You may also be able to fix the error\n");
2363 printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
2364 printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
2365 printf("*** required on your system.\n");
2366 printf("*** If libmikmod-config was wrong, set the environment variable LIBMIKMOD_CONFIG\n");
2367 printf("*** to point to the correct copy of libmikmod-config, and remove the file config.cache\n");
2368 printf("*** before re-running configure\n");
2369 }
2370 else if ((libmikmod_major_version != LIBMIKMOD_VERSION_MAJOR) ||
2371 (libmikmod_minor_version != LIBMIKMOD_VERSION_MINOR) ||
2372 (libmikmod_micro_version != LIBMIKMOD_REVISION))
2373 {
2374 printf("*** libmikmod header files (version %d.%d.%d) do not match\n",
2375 LIBMIKMOD_VERSION_MAJOR, LIBMIKMOD_VERSION_MINOR, LIBMIKMOD_REVISION);
2376 printf("*** library (version %d.%d.%d)\n",
2377 libmikmod_major_version, libmikmod_minor_version, libmikmod_micro_version);
2378 }
2379 else
2380 {
2381 if ((libmikmod_major_version > major) ||
2382 ((libmikmod_major_version == major) && (libmikmod_minor_version > minor)) ||
2383 ((libmikmod_major_version == major) && (libmikmod_minor_version == minor) && (libmikmod_micro_version >= micro)))
2384 {
2385 return 0;
2386 }
2387 else
2388 {
2389 printf("\n*** An old version of libmikmod (%d.%d.%d) was found.\n",
2390 libmikmod_major_version, libmikmod_minor_version, libmikmod_micro_version);
2391 printf("*** You need a version of libmikmod newer than %d.%d.%d.\n",
2392 major, minor, micro);
2393 printf("***\n");
2394 printf("*** If you have already installed a sufficiently new version, this error\n");
2395 printf("*** probably means that the wrong copy of the libmikmod-config shell script is\n");
2396 printf("*** being found. The easiest way to fix this is to remove the old version\n");
2397 printf("*** of libmikmod, but you can also set the LIBMIKMOD_CONFIG environment to point to the\n");
2398 printf("*** correct copy of libmikmod-config. (In this case, you will have to\n");
2399 printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
2400 printf("*** so that the correct libraries are found at run-time))\n");
2401 }
2402 }
2403 return 1;
2404 }
2405
2406 EOF
2407 if { (eval echo configure:2408: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2408 then
2409 :
2410 else
2411 echo "configure: failed program was:" >&5
2412 cat conftest.$ac_ext >&5
2413 rm -fr conftest*
2414 no_libmikmod=yes
2415 fi
2416 rm -fr conftest*
2417 fi
2418
2419 CFLAGS="$ac_save_CFLAGS"
2420 LIBS="$ac_save_LIBS"
2421 ac_ext=c
2422 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2423 ac_cpp='$CPP $CPPFLAGS'
2424 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2425 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2426 cross_compiling=$ac_cv_prog_cc_cross
2427
2428 fi
2429 fi
2430 if test "x$no_libmikmod" = x ; then
2431 echo "$ac_t""yes, `$LIBMIKMOD_CONFIG --version`" 1>&6
2432 CFLAGS="$CFLAGS $LIBMIKMOD_CFLAGS"
2433 LIBS="$LIBS $LIBMIKMOD_LIBS"
2434 LDADD="$LDADD $LIBMIKMOD_LDADD"
2435 cat >> confdefs.h <<\EOF
2436 #define HAVE_LIBMIKMOD 1
2437 EOF
2438
2439 SOUNDFILES="bb.s3m bb2.s3m bb3.s3m"
2440
2441 else
2442 echo "$ac_t""no" 1>&6
2443 if test "$LIBMIKMOD_CONFIG" = "no" ; then
2444 echo "*** The libmikmod-config script installed by libmikmod could not be found"
2445 echo "*** If libmikmod was installed in PREFIX, make sure PREFIX/bin is in"
2446 echo "*** your path, or set the LIBMIKMOD_CONFIG environment variable to the"
2447 echo "*** full path to libmikmod-config."
2448 else
2449 if test -f conf.mikmodtest ; then
2450 :
2451 else
2452 echo "*** Could not run libmikmod test program, checking why..."
2453 CFLAGS="$CFLAGS $LIBMIKMOD_CFLAGS"
2454 LIBS="$LIBS $LIBMIKMOD_LIBS"
2455
2456 ac_ext=c
2457 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2458 ac_cpp='$CPP $CPPFLAGS'
2459 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2460 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2461 cross_compiling=$ac_cv_prog_cc_cross
2462
2463 cat > conftest.$ac_ext <<EOF
2464 #line 2465 "configure"
2465 #include "confdefs.h"
2466
2467 #include <mikmod.h>
2468 #include <stdio.h>
2469
2470 int main() {
2471 return (MikMod_GetVersion()!=0);
2472 ; return 0; }
2473 EOF
2474 if { (eval echo configure:2475: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2475 rm -rf conftest*
2476 echo "*** The test program compiled, but did not run. This usually means"
2477 echo "*** that the run-time linker is not finding libmikmod or finding the wrong"
2478 echo "*** version of libmikmod. If it is not finding libmikmod, you'll need to set your"
2479 echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
2480 echo "*** to the installed location. Also, make sure you have run ldconfig if that"
2481 echo "*** is required on your system."
2482 echo "***"
2483 echo "*** If you have an old version installed, it is best to remove it, although"
2484 echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
2485 else
2486 echo "configure: failed program was:" >&5
2487 cat conftest.$ac_ext >&5
2488 rm -rf conftest*
2489 echo "*** The test program failed to compile or link. See the file config.log for the"
2490 echo "*** exact error that occured. This usually means libmikmod was incorrectly installed"
2491 echo "*** or that you have moved libmikmod since it was installed. In the latter case, you"
2492 echo "*** may want to edit the libmikmod-config script: $LIBMIKMOD_CONFIG"
2493 fi
2494 rm -f conftest*
2495 CFLAGS="$ac_save_CFLAGS"
2496 LIBS="$ac_save_LIBS"
2497 ac_ext=c
2498 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2499 ac_cpp='$CPP $CPPFLAGS'
2500 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2501 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2502 cross_compiling=$ac_cv_prog_cc_cross
2503
2504 fi
2505 fi
2506 LIBMIKMOD_CFLAGS=""
2507 LIBMIKMOD_LIBS=""
2508 LIBMIKMOD_LDADD=""
2509 echo "$ac_t""Libmikmod is missing - sound support will be disabled" 1>&6
2510
2511 fi
2512
2513
2514
2515 rm -f conf.mikmodtest
2516
2517
2518
2519 trap '' 1 2 15
2520 cat > confcache <<\EOF
2521 # This file is a shell script that caches the results of configure
2522 # tests run on this system so they can be shared between configure
2523 # scripts and configure runs. It is not useful on other systems.
2524 # If it contains results you don't want to keep, you may remove or edit it.
2525 #
2526 # By default, configure uses ./config.cache as the cache file,
2527 # creating it if it does not exist already. You can give configure
2528 # the --cache-file=FILE option to use a different cache file; that is
2529 # what configure does when it calls configure scripts in
2530 # subdirectories, so they share the cache.
2531 # Giving --cache-file=/dev/null disables caching, for debugging configure.
2532 # config.status only pays attention to the cache file if you give it the
2533 # --recheck option to rerun configure.
2534 #
2535 EOF
2536 # The following way of writing the cache mishandles newlines in values,
2537 # but we know of no workaround that is simple, portable, and efficient.
2538 # So, don't put newlines in cache variables' values.
2539 # Ultrix sh set writes to stderr and can't be redirected directly,
2540 # and sets the high bit in the cache file unless we assign to the vars.
2541 (set) 2>&1 |
2542 case `(ac_space=' '; set | grep ac_space) 2>&1` in
2543 *ac_space=\ *)
2544 # `set' does not quote correctly, so add quotes (double-quote substitution
2545 # turns \\\\ into \\, and sed turns \\ into \).
2546 sed -n \
2547 -e "s/'/'\\\\''/g" \
2548 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
2549 ;;
2550 *)
2551 # `set' quotes correctly as required by POSIX, so do not add quotes.
2552 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
2553 ;;
2554 esac >> confcache
2555 if cmp -s $cache_file confcache; then
2556 :
2557 else
2558 if test -w $cache_file; then
2559 echo "updating cache $cache_file"
2560 cat confcache > $cache_file
2561 else
2562 echo "not updating unwritable cache $cache_file"
2563 fi
2564 fi
2565 rm -f confcache
2566
2567 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
2568
2569 test "x$prefix" = xNONE && prefix=$ac_default_prefix
2570 # Let make expand exec_prefix.
2571 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
2572
2573 # Any assignment to VPATH causes Sun make to only execute
2574 # the first set of double-colon rules, so remove it if not needed.
2575 # If there is a colon in the path, we need to keep it.
2576 if test "x$srcdir" = x.; then
2577 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
2578 fi
2579
2580 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
2581
2582 DEFS=-DHAVE_CONFIG_H
2583
2584 # Without the "./", some shells look in PATH for config.status.
2585 : ${CONFIG_STATUS=./config.status}
2586
2587 echo creating $CONFIG_STATUS
2588 rm -f $CONFIG_STATUS
2589 cat > $CONFIG_STATUS <<EOF
2590 #! /bin/sh
2591 # Generated automatically by configure.
2592 # Run this file to recreate the current configuration.
2593 # This directory was configured as follows,
2594 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2595 #
2596 # $0 $ac_configure_args
2597 #
2598 # Compiler output produced by configure, useful for debugging
2599 # configure, is in ./config.log if it exists.
2600
2601 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
2602 for ac_option
2603 do
2604 case "\$ac_option" in
2605 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
2606 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
2607 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
2608 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
2609 echo "$CONFIG_STATUS generated by autoconf version 2.13"
2610 exit 0 ;;
2611 -help | --help | --hel | --he | --h)
2612 echo "\$ac_cs_usage"; exit 0 ;;
2613 *) echo "\$ac_cs_usage"; exit 1 ;;
2614 esac
2615 done
2616
2617 ac_given_srcdir=$srcdir
2618 ac_given_INSTALL="$INSTALL"
2619
2620 trap 'rm -fr `echo "Makefile aconfig.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
2621 EOF
2622 cat >> $CONFIG_STATUS <<EOF
2623
2624 # Protect against being on the right side of a sed subst in config.status.
2625 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
2626 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
2627 $ac_vpsub
2628 $extrasub
2629 s%@SHELL@%$SHELL%g
2630 s%@CFLAGS@%$CFLAGS%g
2631 s%@CPPFLAGS@%$CPPFLAGS%g
2632 s%@CXXFLAGS@%$CXXFLAGS%g
2633 s%@FFLAGS@%$FFLAGS%g
2634 s%@DEFS@%$DEFS%g
2635 s%@LDFLAGS@%$LDFLAGS%g
2636 s%@LIBS@%$LIBS%g
2637 s%@exec_prefix@%$exec_prefix%g
2638 s%@prefix@%$prefix%g
2639 s%@program_transform_name@%$program_transform_name%g
2640 s%@bindir@%$bindir%g
2641 s%@sbindir@%$sbindir%g
2642 s%@libexecdir@%$libexecdir%g
2643 s%@datadir@%$datadir%g
2644 s%@sysconfdir@%$sysconfdir%g
2645 s%@sharedstatedir@%$sharedstatedir%g
2646 s%@localstatedir@%$localstatedir%g
2647 s%@libdir@%$libdir%g
2648 s%@includedir@%$includedir%g
2649 s%@oldincludedir@%$oldincludedir%g
2650 s%@infodir@%$infodir%g
2651 s%@mandir@%$mandir%g
2652 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
2653 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
2654 s%@INSTALL_DATA@%$INSTALL_DATA%g
2655 s%@PACKAGE@%$PACKAGE%g
2656 s%@VERSION@%$VERSION%g
2657 s%@ACLOCAL@%$ACLOCAL%g
2658 s%@AUTOCONF@%$AUTOCONF%g
2659 s%@AUTOMAKE@%$AUTOMAKE%g
2660 s%@AUTOHEADER@%$AUTOHEADER%g
2661 s%@MAKEINFO@%$MAKEINFO%g
2662 s%@SET_MAKE@%$SET_MAKE%g
2663 s%@CC@%$CC%g
2664 s%@CPP@%$CPP%g
2665 s%@ALLOCA@%$ALLOCA%g
2666 s%@LIBOBJS@%$LIBOBJS%g
2667 s%@HAVE_MIKMOD@%$HAVE_MIKMOD%g
2668 s%@AALIB_CONFIG@%$AALIB_CONFIG%g
2669 s%@AALIB_CFLAGS@%$AALIB_CFLAGS%g
2670 s%@AALIB_LIBS@%$AALIB_LIBS%g
2671 s%@LIBMIKMOD_CONFIG@%$LIBMIKMOD_CONFIG%g
2672 s%@LIBMIKMOD_CFLAGS@%$LIBMIKMOD_CFLAGS%g
2673 s%@LIBMIKMOD_LIBS@%$LIBMIKMOD_LIBS%g
2674 s%@LIBMIKMOD_LDADD@%$LIBMIKMOD_LDADD%g
2675 s%@SOUNDFILES@%$SOUNDFILES%g
2676
2677 CEOF
2678 EOF
2679
2680 cat >> $CONFIG_STATUS <<\EOF
2681
2682 # Split the substitutions into bite-sized pieces for seds with
2683 # small command number limits, like on Digital OSF/1 and HP-UX.
2684 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
2685 ac_file=1 # Number of current file.
2686 ac_beg=1 # First line for current file.
2687 ac_end=$ac_max_sed_cmds # Line after last line for current file.
2688 ac_more_lines=:
2689 ac_sed_cmds=""
2690 while $ac_more_lines; do
2691 if test $ac_beg -gt 1; then
2692 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
2693 else
2694 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
2695 fi
2696 if test ! -s conftest.s$ac_file; then
2697 ac_more_lines=false
2698 rm -f conftest.s$ac_file
2699 else
2700 if test -z "$ac_sed_cmds"; then
2701 ac_sed_cmds="sed -f conftest.s$ac_file"
2702 else
2703 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
2704 fi
2705 ac_file=`expr $ac_file + 1`
2706 ac_beg=$ac_end
2707 ac_end=`expr $ac_end + $ac_max_sed_cmds`
2708 fi
2709 done
2710 if test -z "$ac_sed_cmds"; then
2711 ac_sed_cmds=cat
2712 fi
2713 EOF
2714
2715 cat >> $CONFIG_STATUS <<EOF
2716
2717 CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
2718 EOF
2719 cat >> $CONFIG_STATUS <<\EOF
2720 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
2721 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2722 case "$ac_file" in
2723 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2724 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2725 *) ac_file_in="${ac_file}.in" ;;
2726 esac
2727
2728 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
2729
2730 # Remove last slash and all that follows it. Not all systems have dirname.
2731 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2732 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2733 # The file is in a subdirectory.
2734 test ! -d "$ac_dir" && mkdir "$ac_dir"
2735 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
2736 # A "../" for each directory in $ac_dir_suffix.
2737 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
2738 else
2739 ac_dir_suffix= ac_dots=
2740 fi
2741
2742 case "$ac_given_srcdir" in
2743 .) srcdir=.
2744 if test -z "$ac_dots"; then top_srcdir=.
2745 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
2746 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
2747 *) # Relative path.
2748 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
2749 top_srcdir="$ac_dots$ac_given_srcdir" ;;
2750 esac
2751
2752 case "$ac_given_INSTALL" in
2753 [/$]*) INSTALL="$ac_given_INSTALL" ;;
2754 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
2755 esac
2756
2757 echo creating "$ac_file"
2758 rm -f "$ac_file"
2759 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
2760 case "$ac_file" in
2761 *Makefile*) ac_comsub="1i\\
2762 # $configure_input" ;;
2763 *) ac_comsub= ;;
2764 esac
2765
2766 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2767 sed -e "$ac_comsub
2768 s%@configure_input@%$configure_input%g
2769 s%@srcdir@%$srcdir%g
2770 s%@top_srcdir@%$top_srcdir%g
2771 s%@INSTALL@%$INSTALL%g
2772 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
2773 fi; done
2774 rm -f conftest.s*
2775
2776 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
2777 # NAME is the cpp macro being defined and VALUE is the value it is being given.
2778 #
2779 # ac_d sets the value in "#define NAME VALUE" lines.
2780 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
2781 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
2782 ac_dC='\3'
2783 ac_dD='%g'
2784 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
2785 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
2786 ac_uB='\([ ]\)%\1#\2define\3'
2787 ac_uC=' '
2788 ac_uD='\4%g'
2789 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
2790 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
2791 ac_eB='$%\1#\2define\3'
2792 ac_eC=' '
2793 ac_eD='%g'
2794
2795 if test "${CONFIG_HEADERS+set}" != set; then
2796 EOF
2797 cat >> $CONFIG_STATUS <<EOF
2798 CONFIG_HEADERS="aconfig.h"
2799 EOF
2800 cat >> $CONFIG_STATUS <<\EOF
2801 fi
2802 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
2803 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2804 case "$ac_file" in
2805 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2806 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2807 *) ac_file_in="${ac_file}.in" ;;
2808 esac
2809
2810 echo creating $ac_file
2811
2812 rm -f conftest.frag conftest.in conftest.out
2813 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2814 cat $ac_file_inputs > conftest.in
2815
2816 EOF
2817
2818 # Transform confdefs.h into a sed script conftest.vals that substitutes
2819 # the proper values into config.h.in to produce config.h. And first:
2820 # Protect against being on the right side of a sed subst in config.status.
2821 # Protect against being in an unquoted here document in config.status.
2822 rm -f conftest.vals
2823 cat > conftest.hdr <<\EOF
2824 s/[\\&%]/\\&/g
2825 s%[\\$`]%\\&%g
2826 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
2827 s%ac_d%ac_u%gp
2828 s%ac_u%ac_e%gp
2829 EOF
2830 sed -n -f conftest.hdr confdefs.h > conftest.vals
2831 rm -f conftest.hdr
2832
2833 # This sed command replaces #undef with comments. This is necessary, for
2834 # example, in the case of _POSIX_SOURCE, which is predefined and required
2835 # on some systems where configure will not decide to define it.
2836 cat >> conftest.vals <<\EOF
2837 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
2838 EOF
2839
2840 # Break up conftest.vals because some shells have a limit on
2841 # the size of here documents, and old seds have small limits too.
2842
2843 rm -f conftest.tail
2844 while :
2845 do
2846 ac_lines=`grep -c . conftest.vals`
2847 # grep -c gives empty output for an empty file on some AIX systems.
2848 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
2849 # Write a limited-size here document to conftest.frag.
2850 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
2851 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
2852 echo 'CEOF
2853 sed -f conftest.frag conftest.in > conftest.out
2854 rm -f conftest.in
2855 mv conftest.out conftest.in
2856 ' >> $CONFIG_STATUS
2857 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
2858 rm -f conftest.vals
2859 mv conftest.tail conftest.vals
2860 done
2861 rm -f conftest.vals
2862
2863 cat >> $CONFIG_STATUS <<\EOF
2864 rm -f conftest.frag conftest.h
2865 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
2866 cat conftest.in >> conftest.h
2867 rm -f conftest.in
2868 if cmp -s $ac_file conftest.h 2>/dev/null; then
2869 echo "$ac_file is unchanged"
2870 rm -f conftest.h
2871 else
2872 # Remove last slash and all that follows it. Not all systems have dirname.
2873 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2874 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2875 # The file is in a subdirectory.
2876 test ! -d "$ac_dir" && mkdir "$ac_dir"
2877 fi
2878 rm -f $ac_file
2879 mv conftest.h $ac_file
2880 fi
2881 fi; done
2882
2883 EOF
2884 cat >> $CONFIG_STATUS <<EOF
2885
2886
2887 EOF
2888 cat >> $CONFIG_STATUS <<\EOF
2889 test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
2890
2891 exit 0
2892 EOF
2893 chmod +x $CONFIG_STATUS
2894 rm -fr confdefs* $ac_clean_files
2895 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
2896