"Oops." Fixed.
[platform/upstream/libvorbis.git] / configure
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
15 # Initialize some variables set by options.
16 # The variables have the same names as the options, with
17 # dashes changed to underlines.
18 build=NONE
19 cache_file=./config.cache
20 exec_prefix=NONE
21 host=NONE
22 no_create=
23 nonopt=NONE
24 no_recursion=
25 prefix=NONE
26 program_prefix=NONE
27 program_suffix=NONE
28 program_transform_name=s,x,x,
29 silent=
30 site=
31 srcdir=
32 target=NONE
33 verbose=
34 x_includes=NONE
35 x_libraries=NONE
36 bindir='${exec_prefix}/bin'
37 sbindir='${exec_prefix}/sbin'
38 libexecdir='${exec_prefix}/libexec'
39 datadir='${prefix}/share'
40 sysconfdir='${prefix}/etc'
41 sharedstatedir='${prefix}/com'
42 localstatedir='${prefix}/var'
43 libdir='${exec_prefix}/lib'
44 includedir='${prefix}/include'
45 oldincludedir='/usr/include'
46 infodir='${prefix}/info'
47 mandir='${prefix}/man'
48
49 # Initialize some other variables.
50 subdirs=
51 MFLAGS= MAKEFLAGS=
52 SHELL=${CONFIG_SHELL-/bin/sh}
53 # Maximum number of lines to put in a shell here document.
54 ac_max_here_lines=12
55
56 ac_prev=
57 for ac_option
58 do
59
60   # If the previous option needs an argument, assign it.
61   if test -n "$ac_prev"; then
62     eval "$ac_prev=\$ac_option"
63     ac_prev=
64     continue
65   fi
66
67   case "$ac_option" in
68   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
69   *) ac_optarg= ;;
70   esac
71
72   # Accept the important Cygnus configure options, so we can diagnose typos.
73
74   case "$ac_option" in
75
76   -bindir | --bindir | --bindi | --bind | --bin | --bi)
77     ac_prev=bindir ;;
78   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
79     bindir="$ac_optarg" ;;
80
81   -build | --build | --buil | --bui | --bu)
82     ac_prev=build ;;
83   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
84     build="$ac_optarg" ;;
85
86   -cache-file | --cache-file | --cache-fil | --cache-fi \
87   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
88     ac_prev=cache_file ;;
89   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
90   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
91     cache_file="$ac_optarg" ;;
92
93   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
94     ac_prev=datadir ;;
95   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
96   | --da=*)
97     datadir="$ac_optarg" ;;
98
99   -disable-* | --disable-*)
100     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
101     # Reject names that are not valid shell variable names.
102     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
103       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
104     fi
105     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
106     eval "enable_${ac_feature}=no" ;;
107
108   -enable-* | --enable-*)
109     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
110     # Reject names that are not valid shell variable names.
111     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
112       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
113     fi
114     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
115     case "$ac_option" in
116       *=*) ;;
117       *) ac_optarg=yes ;;
118     esac
119     eval "enable_${ac_feature}='$ac_optarg'" ;;
120
121   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
122   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
123   | --exec | --exe | --ex)
124     ac_prev=exec_prefix ;;
125   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
126   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
127   | --exec=* | --exe=* | --ex=*)
128     exec_prefix="$ac_optarg" ;;
129
130   -gas | --gas | --ga | --g)
131     # Obsolete; use --with-gas.
132     with_gas=yes ;;
133
134   -help | --help | --hel | --he)
135     # Omit some internal or obsolete options to make the list less imposing.
136     # This message is too long to be a string in the A/UX 3.1 sh.
137     cat << EOF
138 Usage: configure [options] [host]
139 Options: [defaults in brackets after descriptions]
140 Configuration:
141   --cache-file=FILE       cache test results in FILE
142   --help                  print this message
143   --no-create             do not create output files
144   --quiet, --silent       do not print \`checking...' messages
145   --version               print the version of autoconf that created configure
146 Directory and file names:
147   --prefix=PREFIX         install architecture-independent files in PREFIX
148                           [$ac_default_prefix]
149   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
150                           [same as prefix]
151   --bindir=DIR            user executables in DIR [EPREFIX/bin]
152   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
153   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
154   --datadir=DIR           read-only architecture-independent data in DIR
155                           [PREFIX/share]
156   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
157   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
158                           [PREFIX/com]
159   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
160   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
161   --includedir=DIR        C header files in DIR [PREFIX/include]
162   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
163   --infodir=DIR           info documentation in DIR [PREFIX/info]
164   --mandir=DIR            man documentation in DIR [PREFIX/man]
165   --srcdir=DIR            find the sources in DIR [configure dir or ..]
166   --program-prefix=PREFIX prepend PREFIX to installed program names
167   --program-suffix=SUFFIX append SUFFIX to installed program names
168   --program-transform-name=PROGRAM
169                           run sed PROGRAM on installed program names
170 EOF
171     cat << EOF
172 Host type:
173   --build=BUILD           configure for building on BUILD [BUILD=HOST]
174   --host=HOST             configure for HOST [guessed]
175   --target=TARGET         configure for TARGET [TARGET=HOST]
176 Features and packages:
177   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
178   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
179   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
180   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
181   --x-includes=DIR        X include files are in DIR
182   --x-libraries=DIR       X library files are in DIR
183 EOF
184     if test -n "$ac_help"; then
185       echo "--enable and --with options recognized:$ac_help"
186     fi
187     exit 0 ;;
188
189   -host | --host | --hos | --ho)
190     ac_prev=host ;;
191   -host=* | --host=* | --hos=* | --ho=*)
192     host="$ac_optarg" ;;
193
194   -includedir | --includedir | --includedi | --included | --include \
195   | --includ | --inclu | --incl | --inc)
196     ac_prev=includedir ;;
197   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
198   | --includ=* | --inclu=* | --incl=* | --inc=*)
199     includedir="$ac_optarg" ;;
200
201   -infodir | --infodir | --infodi | --infod | --info | --inf)
202     ac_prev=infodir ;;
203   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
204     infodir="$ac_optarg" ;;
205
206   -libdir | --libdir | --libdi | --libd)
207     ac_prev=libdir ;;
208   -libdir=* | --libdir=* | --libdi=* | --libd=*)
209     libdir="$ac_optarg" ;;
210
211   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
212   | --libexe | --libex | --libe)
213     ac_prev=libexecdir ;;
214   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
215   | --libexe=* | --libex=* | --libe=*)
216     libexecdir="$ac_optarg" ;;
217
218   -localstatedir | --localstatedir | --localstatedi | --localstated \
219   | --localstate | --localstat | --localsta | --localst \
220   | --locals | --local | --loca | --loc | --lo)
221     ac_prev=localstatedir ;;
222   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
223   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
224   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
225     localstatedir="$ac_optarg" ;;
226
227   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
228     ac_prev=mandir ;;
229   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
230     mandir="$ac_optarg" ;;
231
232   -nfp | --nfp | --nf)
233     # Obsolete; use --without-fp.
234     with_fp=no ;;
235
236   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
237   | --no-cr | --no-c)
238     no_create=yes ;;
239
240   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
241   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
242     no_recursion=yes ;;
243
244   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
245   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
246   | --oldin | --oldi | --old | --ol | --o)
247     ac_prev=oldincludedir ;;
248   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
249   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
250   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
251     oldincludedir="$ac_optarg" ;;
252
253   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
254     ac_prev=prefix ;;
255   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
256     prefix="$ac_optarg" ;;
257
258   -program-prefix | --program-prefix | --program-prefi | --program-pref \
259   | --program-pre | --program-pr | --program-p)
260     ac_prev=program_prefix ;;
261   -program-prefix=* | --program-prefix=* | --program-prefi=* \
262   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
263     program_prefix="$ac_optarg" ;;
264
265   -program-suffix | --program-suffix | --program-suffi | --program-suff \
266   | --program-suf | --program-su | --program-s)
267     ac_prev=program_suffix ;;
268   -program-suffix=* | --program-suffix=* | --program-suffi=* \
269   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
270     program_suffix="$ac_optarg" ;;
271
272   -program-transform-name | --program-transform-name \
273   | --program-transform-nam | --program-transform-na \
274   | --program-transform-n | --program-transform- \
275   | --program-transform | --program-transfor \
276   | --program-transfo | --program-transf \
277   | --program-trans | --program-tran \
278   | --progr-tra | --program-tr | --program-t)
279     ac_prev=program_transform_name ;;
280   -program-transform-name=* | --program-transform-name=* \
281   | --program-transform-nam=* | --program-transform-na=* \
282   | --program-transform-n=* | --program-transform-=* \
283   | --program-transform=* | --program-transfor=* \
284   | --program-transfo=* | --program-transf=* \
285   | --program-trans=* | --program-tran=* \
286   | --progr-tra=* | --program-tr=* | --program-t=*)
287     program_transform_name="$ac_optarg" ;;
288
289   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
290   | -silent | --silent | --silen | --sile | --sil)
291     silent=yes ;;
292
293   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
294     ac_prev=sbindir ;;
295   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
296   | --sbi=* | --sb=*)
297     sbindir="$ac_optarg" ;;
298
299   -sharedstatedir | --sharedstatedir | --sharedstatedi \
300   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
301   | --sharedst | --shareds | --shared | --share | --shar \
302   | --sha | --sh)
303     ac_prev=sharedstatedir ;;
304   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
305   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
306   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
307   | --sha=* | --sh=*)
308     sharedstatedir="$ac_optarg" ;;
309
310   -site | --site | --sit)
311     ac_prev=site ;;
312   -site=* | --site=* | --sit=*)
313     site="$ac_optarg" ;;
314
315   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
316     ac_prev=srcdir ;;
317   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
318     srcdir="$ac_optarg" ;;
319
320   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
321   | --syscon | --sysco | --sysc | --sys | --sy)
322     ac_prev=sysconfdir ;;
323   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
324   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
325     sysconfdir="$ac_optarg" ;;
326
327   -target | --target | --targe | --targ | --tar | --ta | --t)
328     ac_prev=target ;;
329   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
330     target="$ac_optarg" ;;
331
332   -v | -verbose | --verbose | --verbos | --verbo | --verb)
333     verbose=yes ;;
334
335   -version | --version | --versio | --versi | --vers)
336     echo "configure generated by autoconf version 2.13"
337     exit 0 ;;
338
339   -with-* | --with-*)
340     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
341     # Reject names that are not valid shell variable names.
342     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
343       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
344     fi
345     ac_package=`echo $ac_package| sed 's/-/_/g'`
346     case "$ac_option" in
347       *=*) ;;
348       *) ac_optarg=yes ;;
349     esac
350     eval "with_${ac_package}='$ac_optarg'" ;;
351
352   -without-* | --without-*)
353     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
354     # Reject names that are not valid shell variable names.
355     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
356       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
357     fi
358     ac_package=`echo $ac_package| sed 's/-/_/g'`
359     eval "with_${ac_package}=no" ;;
360
361   --x)
362     # Obsolete; use --with-x.
363     with_x=yes ;;
364
365   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
366   | --x-incl | --x-inc | --x-in | --x-i)
367     ac_prev=x_includes ;;
368   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
369   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
370     x_includes="$ac_optarg" ;;
371
372   -x-libraries | --x-libraries | --x-librarie | --x-librari \
373   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
374     ac_prev=x_libraries ;;
375   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
376   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
377     x_libraries="$ac_optarg" ;;
378
379   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
380     ;;
381
382   *)
383     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
384       echo "configure: warning: $ac_option: invalid host type" 1>&2
385     fi
386     if test "x$nonopt" != xNONE; then
387       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
388     fi
389     nonopt="$ac_option"
390     ;;
391
392   esac
393 done
394
395 if test -n "$ac_prev"; then
396   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
397 fi
398
399 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
400
401 # File descriptor usage:
402 # 0 standard input
403 # 1 file creation
404 # 2 errors and warnings
405 # 3 some systems may open it to /dev/tty
406 # 4 used on the Kubota Titan
407 # 6 checking for... messages and results
408 # 5 compiler messages saved in config.log
409 if test "$silent" = yes; then
410   exec 6>/dev/null
411 else
412   exec 6>&1
413 fi
414 exec 5>./config.log
415
416 echo "\
417 This file contains any messages produced by compilers while
418 running configure, to aid debugging if configure makes a mistake.
419 " 1>&5
420
421 # Strip out --no-create and --no-recursion so they do not pile up.
422 # Also quote any args containing shell metacharacters.
423 ac_configure_args=
424 for ac_arg
425 do
426   case "$ac_arg" in
427   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
428   | --no-cr | --no-c) ;;
429   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
430   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
431   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
432   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
433   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
434   esac
435 done
436
437 # NLS nuisances.
438 # Only set these to C if already set.  These must not be set unconditionally
439 # because not all systems understand e.g. LANG=C (notably SCO).
440 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
441 # Non-C LC_CTYPE values break the ctype check.
442 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
443 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
444 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
445 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
446
447 # confdefs.h avoids OS command line length limits that DEFS can exceed.
448 rm -rf conftest* confdefs.h
449 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
450 echo > confdefs.h
451
452 # A filename unique to this package, relative to the directory that
453 # configure is in, which we can look for to find out if srcdir is correct.
454 ac_unique_file=lib/mdct.c
455
456 # Find the source files, if location was not specified.
457 if test -z "$srcdir"; then
458   ac_srcdir_defaulted=yes
459   # Try the directory containing this script, then its parent.
460   ac_prog=$0
461   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
462   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
463   srcdir=$ac_confdir
464   if test ! -r $srcdir/$ac_unique_file; then
465     srcdir=..
466   fi
467 else
468   ac_srcdir_defaulted=no
469 fi
470 if test ! -r $srcdir/$ac_unique_file; then
471   if test "$ac_srcdir_defaulted" = yes; then
472     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
473   else
474     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
475   fi
476 fi
477 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
478
479 # Prefer explicitly selected file to automatically selected ones.
480 if test -z "$CONFIG_SITE"; then
481   if test "x$prefix" != xNONE; then
482     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
483   else
484     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
485   fi
486 fi
487 for ac_site_file in $CONFIG_SITE; do
488   if test -r "$ac_site_file"; then
489     echo "loading site script $ac_site_file"
490     . "$ac_site_file"
491   fi
492 done
493
494 if test -r "$cache_file"; then
495   echo "loading cache $cache_file"
496   . $cache_file
497 else
498   echo "creating cache $cache_file"
499   > $cache_file
500 fi
501
502 ac_ext=c
503 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
504 ac_cpp='$CPP $CPPFLAGS'
505 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
506 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
507 cross_compiling=$ac_cv_prog_cc_cross
508
509 ac_exeext=
510 ac_objext=o
511 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
512   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
513   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
514     ac_n= ac_c='
515 ' ac_t='        '
516   else
517     ac_n=-n ac_c= ac_t=
518   fi
519 else
520   ac_n= ac_c='\c' ac_t=
521 fi
522
523
524 #AC_CONFIG_HEADER(config.h)
525
526 cp configure.guess config.guess
527 cp configure.sub config.sub
528
529 ac_aux_dir=
530 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
531   if test -f $ac_dir/install-sh; then
532     ac_aux_dir=$ac_dir
533     ac_install_sh="$ac_aux_dir/install-sh -c"
534     break
535   elif test -f $ac_dir/install.sh; then
536     ac_aux_dir=$ac_dir
537     ac_install_sh="$ac_aux_dir/install.sh -c"
538     break
539   fi
540 done
541 if test -z "$ac_aux_dir"; then
542   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
543 fi
544 ac_config_guess=$ac_aux_dir/config.guess
545 ac_config_sub=$ac_aux_dir/config.sub
546 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
547
548
549 # Make sure we can run config.sub.
550 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
551 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
552 fi
553
554 echo $ac_n "checking host system type""... $ac_c" 1>&6
555 echo "configure:556: checking host system type" >&5
556
557 host_alias=$host
558 case "$host_alias" in
559 NONE)
560   case $nonopt in
561   NONE)
562     if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
563     else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
564     fi ;;
565   *) host_alias=$nonopt ;;
566   esac ;;
567 esac
568
569 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
570 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
571 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
572 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
573 echo "$ac_t""$host" 1>&6
574
575
576 case $host in 
577         *-*-irix*)
578                 if test -z "$CC"; then
579                         CC=cc
580                 fi
581                 echo $ac_n "checking for ALwritesamps in -laudio""... $ac_c" 1>&6
582 echo "configure:583: checking for ALwritesamps in -laudio" >&5
583 ac_lib_var=`echo audio'_'ALwritesamps | sed 'y%./+-%__p_%'`
584 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
585   echo $ac_n "(cached) $ac_c" 1>&6
586 else
587   ac_save_LIBS="$LIBS"
588 LIBS="-laudio  $LIBS"
589 cat > conftest.$ac_ext <<EOF
590 #line 591 "configure"
591 #include "confdefs.h"
592 /* Override any gcc2 internal prototype to avoid an error.  */
593 /* We use char because int might match the return type of a gcc2
594     builtin and then its argument prototype would still apply.  */
595 char ALwritesamps();
596
597 int main() {
598 ALwritesamps()
599 ; return 0; }
600 EOF
601 if { (eval echo configure:602: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
602   rm -rf conftest*
603   eval "ac_cv_lib_$ac_lib_var=yes"
604 else
605   echo "configure: failed program was:" >&5
606   cat conftest.$ac_ext >&5
607   rm -rf conftest*
608   eval "ac_cv_lib_$ac_lib_var=no"
609 fi
610 rm -f conftest*
611 LIBS="$ac_save_LIBS"
612
613 fi
614 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
615   echo "$ac_t""yes" 1>&6
616     ac_tr_lib=HAVE_LIB`echo audio | sed -e 's/[^a-zA-Z0-9_]/_/g' \
617     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
618   cat >> confdefs.h <<EOF
619 #define $ac_tr_lib 1
620 EOF
621
622   LIBS="-laudio $LIBS"
623
624 else
625   echo "$ac_t""no" 1>&6
626 fi
627
628         ;;
629 # BeOS does not use -lm
630 #       *-*-beos)
631 #               LIBS=""
632 #       ;;
633 # added better check below
634
635 esac
636
637 if test -z "$CC"; then
638         # Extract the first word of "gcc", so it can be a program name with args.
639 set dummy gcc; ac_word=$2
640 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
641 echo "configure:642: checking for $ac_word" >&5
642 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
643   echo $ac_n "(cached) $ac_c" 1>&6
644 else
645   if test -n "$CC"; then
646   ac_cv_prog_CC="$CC" # Let the user override the test.
647 else
648   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
649   ac_dummy="$PATH"
650   for ac_dir in $ac_dummy; do
651     test -z "$ac_dir" && ac_dir=.
652     if test -f $ac_dir/$ac_word; then
653       ac_cv_prog_CC="gcc"
654       break
655     fi
656   done
657   IFS="$ac_save_ifs"
658 fi
659 fi
660 CC="$ac_cv_prog_CC"
661 if test -n "$CC"; then
662   echo "$ac_t""$CC" 1>&6
663 else
664   echo "$ac_t""no" 1>&6
665 fi
666
667 if test -z "$CC"; then
668   # Extract the first word of "cc", so it can be a program name with args.
669 set dummy cc; ac_word=$2
670 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
671 echo "configure:672: checking for $ac_word" >&5
672 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
673   echo $ac_n "(cached) $ac_c" 1>&6
674 else
675   if test -n "$CC"; then
676   ac_cv_prog_CC="$CC" # Let the user override the test.
677 else
678   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
679   ac_prog_rejected=no
680   ac_dummy="$PATH"
681   for ac_dir in $ac_dummy; do
682     test -z "$ac_dir" && ac_dir=.
683     if test -f $ac_dir/$ac_word; then
684       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
685         ac_prog_rejected=yes
686         continue
687       fi
688       ac_cv_prog_CC="cc"
689       break
690     fi
691   done
692   IFS="$ac_save_ifs"
693 if test $ac_prog_rejected = yes; then
694   # We found a bogon in the path, so make sure we never use it.
695   set dummy $ac_cv_prog_CC
696   shift
697   if test $# -gt 0; then
698     # We chose a different compiler from the bogus one.
699     # However, it has the same basename, so the bogon will be chosen
700     # first if we set CC to just the basename; use the full file name.
701     shift
702     set dummy "$ac_dir/$ac_word" "$@"
703     shift
704     ac_cv_prog_CC="$@"
705   fi
706 fi
707 fi
708 fi
709 CC="$ac_cv_prog_CC"
710 if test -n "$CC"; then
711   echo "$ac_t""$CC" 1>&6
712 else
713   echo "$ac_t""no" 1>&6
714 fi
715
716   if test -z "$CC"; then
717     case "`uname -s`" in
718     *win32* | *WIN32*)
719       # Extract the first word of "cl", so it can be a program name with args.
720 set dummy cl; ac_word=$2
721 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
722 echo "configure:723: checking for $ac_word" >&5
723 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
724   echo $ac_n "(cached) $ac_c" 1>&6
725 else
726   if test -n "$CC"; then
727   ac_cv_prog_CC="$CC" # Let the user override the test.
728 else
729   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
730   ac_dummy="$PATH"
731   for ac_dir in $ac_dummy; do
732     test -z "$ac_dir" && ac_dir=.
733     if test -f $ac_dir/$ac_word; then
734       ac_cv_prog_CC="cl"
735       break
736     fi
737   done
738   IFS="$ac_save_ifs"
739 fi
740 fi
741 CC="$ac_cv_prog_CC"
742 if test -n "$CC"; then
743   echo "$ac_t""$CC" 1>&6
744 else
745   echo "$ac_t""no" 1>&6
746 fi
747  ;;
748     esac
749   fi
750   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
751 fi
752
753 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
754 echo "configure:755: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
755
756 ac_ext=c
757 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
758 ac_cpp='$CPP $CPPFLAGS'
759 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
760 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
761 cross_compiling=$ac_cv_prog_cc_cross
762
763 cat > conftest.$ac_ext << EOF
764
765 #line 766 "configure"
766 #include "confdefs.h"
767
768 main(){return(0);}
769 EOF
770 if { (eval echo configure:771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
771   ac_cv_prog_cc_works=yes
772   # If we can't run a trivial program, we are probably using a cross compiler.
773   if (./conftest; exit) 2>/dev/null; then
774     ac_cv_prog_cc_cross=no
775   else
776     ac_cv_prog_cc_cross=yes
777   fi
778 else
779   echo "configure: failed program was:" >&5
780   cat conftest.$ac_ext >&5
781   ac_cv_prog_cc_works=no
782 fi
783 rm -fr conftest*
784 ac_ext=c
785 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
786 ac_cpp='$CPP $CPPFLAGS'
787 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
788 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
789 cross_compiling=$ac_cv_prog_cc_cross
790
791 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
792 if test $ac_cv_prog_cc_works = no; then
793   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
794 fi
795 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
796 echo "configure:797: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
797 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
798 cross_compiling=$ac_cv_prog_cc_cross
799
800 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
801 echo "configure:802: checking whether we are using GNU C" >&5
802 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
803   echo $ac_n "(cached) $ac_c" 1>&6
804 else
805   cat > conftest.c <<EOF
806 #ifdef __GNUC__
807   yes;
808 #endif
809 EOF
810 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:811: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
811   ac_cv_prog_gcc=yes
812 else
813   ac_cv_prog_gcc=no
814 fi
815 fi
816
817 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
818
819 if test $ac_cv_prog_gcc = yes; then
820   GCC=yes
821 else
822   GCC=
823 fi
824
825 ac_test_CFLAGS="${CFLAGS+set}"
826 ac_save_CFLAGS="$CFLAGS"
827 CFLAGS=
828 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
829 echo "configure:830: checking whether ${CC-cc} accepts -g" >&5
830 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
831   echo $ac_n "(cached) $ac_c" 1>&6
832 else
833   echo 'void f(){}' > conftest.c
834 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
835   ac_cv_prog_cc_g=yes
836 else
837   ac_cv_prog_cc_g=no
838 fi
839 rm -f conftest*
840
841 fi
842
843 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
844 if test "$ac_test_CFLAGS" = set; then
845   CFLAGS="$ac_save_CFLAGS"
846 elif test $ac_cv_prog_cc_g = yes; then
847   if test "$GCC" = yes; then
848     CFLAGS="-g -O2"
849   else
850     CFLAGS="-g"
851   fi
852 else
853   if test "$GCC" = yes; then
854     CFLAGS="-O2"
855   else
856     CFLAGS=
857   fi
858 fi
859         
860 fi
861 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
862 echo "configure:863: checking how to run the C preprocessor" >&5
863 # On Suns, sometimes $CPP names a directory.
864 if test -n "$CPP" && test -d "$CPP"; then
865   CPP=
866 fi
867 if test -z "$CPP"; then
868 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
869   echo $ac_n "(cached) $ac_c" 1>&6
870 else
871     # This must be in double quotes, not single quotes, because CPP may get
872   # substituted into the Makefile and "${CC-cc}" will confuse make.
873   CPP="${CC-cc} -E"
874   # On the NeXT, cc -E runs the code through the compiler's parser,
875   # not just through cpp.
876   cat > conftest.$ac_ext <<EOF
877 #line 878 "configure"
878 #include "confdefs.h"
879 #include <assert.h>
880 Syntax Error
881 EOF
882 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
883 { (eval echo configure:884: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
884 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
885 if test -z "$ac_err"; then
886   :
887 else
888   echo "$ac_err" >&5
889   echo "configure: failed program was:" >&5
890   cat conftest.$ac_ext >&5
891   rm -rf conftest*
892   CPP="${CC-cc} -E -traditional-cpp"
893   cat > conftest.$ac_ext <<EOF
894 #line 895 "configure"
895 #include "confdefs.h"
896 #include <assert.h>
897 Syntax Error
898 EOF
899 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
900 { (eval echo configure:901: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
901 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
902 if test -z "$ac_err"; then
903   :
904 else
905   echo "$ac_err" >&5
906   echo "configure: failed program was:" >&5
907   cat conftest.$ac_ext >&5
908   rm -rf conftest*
909   CPP="${CC-cc} -nologo -E"
910   cat > conftest.$ac_ext <<EOF
911 #line 912 "configure"
912 #include "confdefs.h"
913 #include <assert.h>
914 Syntax Error
915 EOF
916 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
917 { (eval echo configure:918: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
918 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
919 if test -z "$ac_err"; then
920   :
921 else
922   echo "$ac_err" >&5
923   echo "configure: failed program was:" >&5
924   cat conftest.$ac_ext >&5
925   rm -rf conftest*
926   CPP=/lib/cpp
927 fi
928 rm -f conftest*
929 fi
930 rm -f conftest*
931 fi
932 rm -f conftest*
933   ac_cv_prog_CPP="$CPP"
934 fi
935   CPP="$ac_cv_prog_CPP"
936 else
937   ac_cv_prog_CPP="$CPP"
938 fi
939 echo "$ac_t""$CPP" 1>&6
940
941 # Extract the first word of "ranlib", so it can be a program name with args.
942 set dummy ranlib; ac_word=$2
943 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
944 echo "configure:945: checking for $ac_word" >&5
945 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
946   echo $ac_n "(cached) $ac_c" 1>&6
947 else
948   if test -n "$RANLIB"; then
949   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
950 else
951   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
952   ac_dummy="$PATH"
953   for ac_dir in $ac_dummy; do
954     test -z "$ac_dir" && ac_dir=.
955     if test -f $ac_dir/$ac_word; then
956       ac_cv_prog_RANLIB="ranlib"
957       break
958     fi
959   done
960   IFS="$ac_save_ifs"
961   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
962 fi
963 fi
964 RANLIB="$ac_cv_prog_RANLIB"
965 if test -n "$RANLIB"; then
966   echo "$ac_t""$RANLIB" 1>&6
967 else
968   echo "$ac_t""no" 1>&6
969 fi
970
971 # Extract the first word of "ar", so it can be a program name with args.
972 set dummy ar; ac_word=$2
973 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
974 echo "configure:975: checking for $ac_word" >&5
975 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
976   echo $ac_n "(cached) $ac_c" 1>&6
977 else
978   if test -n "$AR"; then
979   ac_cv_prog_AR="$AR" # Let the user override the test.
980 else
981   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
982   ac_dummy="$PATH"
983   for ac_dir in $ac_dummy; do
984     test -z "$ac_dir" && ac_dir=.
985     if test -f $ac_dir/$ac_word; then
986       ac_cv_prog_AR="ar"
987       break
988     fi
989   done
990   IFS="$ac_save_ifs"
991 fi
992 fi
993 AR="$ac_cv_prog_AR"
994 if test -n "$AR"; then
995   echo "$ac_t""$AR" 1>&6
996 else
997   echo "$ac_t""no" 1>&6
998 fi
999
1000 # Extract the first word of "install", so it can be a program name with args.
1001 set dummy install; ac_word=$2
1002 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1003 echo "configure:1004: checking for $ac_word" >&5
1004 if eval "test \"`echo '$''{'ac_cv_prog_INSTALL'+set}'`\" = set"; then
1005   echo $ac_n "(cached) $ac_c" 1>&6
1006 else
1007   if test -n "$INSTALL"; then
1008   ac_cv_prog_INSTALL="$INSTALL" # Let the user override the test.
1009 else
1010   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1011   ac_dummy="$PATH"
1012   for ac_dir in $ac_dummy; do
1013     test -z "$ac_dir" && ac_dir=.
1014     if test -f $ac_dir/$ac_word; then
1015       ac_cv_prog_INSTALL="install"
1016       break
1017     fi
1018   done
1019   IFS="$ac_save_ifs"
1020 fi
1021 fi
1022 INSTALL="$ac_cv_prog_INSTALL"
1023 if test -n "$INSTALL"; then
1024   echo "$ac_t""$INSTALL" 1>&6
1025 else
1026   echo "$ac_t""no" 1>&6
1027 fi
1028
1029
1030 #not everyone uses libm (eg, BeOS)
1031 #AC_CHECK_LIB(m, cos, LIBS="-lm"; AC_DEFINE(HAVE_LIBM), LIBS="")
1032 # We no longer use config.h
1033 echo $ac_n "checking for cos in -lm""... $ac_c" 1>&6
1034 echo "configure:1035: checking for cos in -lm" >&5
1035 ac_lib_var=`echo m'_'cos | sed 'y%./+-%__p_%'`
1036 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1037   echo $ac_n "(cached) $ac_c" 1>&6
1038 else
1039   ac_save_LIBS="$LIBS"
1040 LIBS="-lm  $LIBS"
1041 cat > conftest.$ac_ext <<EOF
1042 #line 1043 "configure"
1043 #include "confdefs.h"
1044 /* Override any gcc2 internal prototype to avoid an error.  */
1045 /* We use char because int might match the return type of a gcc2
1046     builtin and then its argument prototype would still apply.  */
1047 char cos();
1048
1049 int main() {
1050 cos()
1051 ; return 0; }
1052 EOF
1053 if { (eval echo configure:1054: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1054   rm -rf conftest*
1055   eval "ac_cv_lib_$ac_lib_var=yes"
1056 else
1057   echo "configure: failed program was:" >&5
1058   cat conftest.$ac_ext >&5
1059   rm -rf conftest*
1060   eval "ac_cv_lib_$ac_lib_var=no"
1061 fi
1062 rm -f conftest*
1063 LIBS="$ac_save_LIBS"
1064
1065 fi
1066 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1067   echo "$ac_t""yes" 1>&6
1068   LIBS="-lm"
1069 else
1070   echo "$ac_t""no" 1>&6
1071 LIBS=""
1072 fi
1073
1074
1075 if test -z "$GCC"; then
1076         case $host in 
1077         *-*-irix*)
1078                 DEBUG="-g -signed" 
1079                 OPT="-O2 -w -signed"
1080                 PROFILE="-p -g3 -O2 -signed" ;;
1081         sparc-sun-solaris*)
1082                 DEBUG="-v -g"
1083                 OPT="-xO4 -fast -w -fsimple -native -xcg92"
1084                 PROFILE="-v -xpg -g -xO4 -fast -native -fsimple -xcg92 -Dsuncc" ;;
1085         *)
1086                 DEBUG="-g"
1087                 OPT="-O"
1088                 PROFILE="-g -p" ;;
1089         esac
1090 else
1091
1092         case $host in 
1093         *86-*-linux*)
1094                 DEBUG="-g -Wall -D_REENTRANT -D__NO_MATH_INLINES -fsigned-char"
1095                 OPT="-O20 -ffast-math -D_REENTRANT -fsigned-char"
1096                 PROFILE="-pg -g -O20 -ffast-math -D_REENTRANT -fsigned-char"
1097                 
1098                 # glibc < 2.1.3 has a serious FP bug in the math inline header
1099                 # that will cripple Vorbis.  Look to see if the magic FP stack
1100                 # clobber is missing in the mathinline header, thus indicating
1101                 # the buggy version
1102
1103                 cat > conftest.$ac_ext <<EOF
1104 #line 1105 "configure"
1105 #include "confdefs.h"
1106
1107                                 #define __LIBC_INTERNAL_MATH_INLINES 1
1108                                 #define __OPTIMIZE__
1109                                 #include <math.h>
1110                                 
1111 EOF
1112 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1113   egrep "log10.*fldlg2.*fxch" >/dev/null 2>&1; then
1114   rm -rf conftest*
1115   bad=maybe
1116 else
1117   rm -rf conftest*
1118   bad=no
1119 fi
1120 rm -f conftest*
1121
1122                 if test ${bad} = "maybe" ;then
1123                       cat > conftest.$ac_ext <<EOF
1124 #line 1125 "configure"
1125 #include "confdefs.h"
1126
1127                                         #define __LIBC_INTERNAL_MATH_INLINES 1
1128                                         #define __OPTIMIZE__
1129                                         #include <math.h>
1130                                         
1131 EOF
1132 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1133   egrep "log10.*fldlg2.*fxch.*st\([0123456789]*\)" >/dev/null 2>&1; then
1134   rm -rf conftest*
1135   bad=no
1136 else
1137   rm -rf conftest*
1138   bad=yes
1139 fi
1140 rm -f conftest*
1141
1142                 fi
1143                 if test ${bad} = "yes" ;then
1144  echo "configure: warning:                                                         " 1>&2
1145  echo "configure: warning: ********************************************************" 1>&2
1146  echo "configure: warning: * The glibc headers on this machine have a serious bug *" 1>&2
1147  echo "configure: warning: * in /usr/include/bits/mathinline.h  This bug affects  *" 1>&2
1148  echo "configure: warning: * all floating point code, not just Ogg, built on this *" 1>&2
1149  echo "configure: warning: * machine.  Upgrading to glibc 2.1.3 is strongly urged *" 1>&2
1150  echo "configure: warning: * to correct the problem.  Note that upgrading glibc   *" 1>&2
1151  echo "configure: warning: * will not fix any previously built programs; this is  *" 1>&2
1152  echo "configure: warning: * a compile-time time bug.                             *" 1>&2
1153  echo "configure: warning: * To work around the problem for this build of Ogg,    *" 1>&2
1154  echo "configure: warning: * autoconf is disabling all math inlining.  This will  *" 1>&2
1155  echo "configure: warning: * hurt Ogg performace but is necessary for an Ogg that *" 1>&2
1156  echo "configure: warning: * will actually work.  Once glibc is upgraded, rerun   *" 1>&2
1157  echo "configure: warning: * configure and make to build with inlining.           *" 1>&2
1158  echo "configure: warning: ********************************************************" 1>&2
1159  echo "configure: warning:                                                         " 1>&2
1160
1161                 OPT=${OPT}" -D__NO_MATH_INLINES"
1162                 PROFILE=${PROFILE}" -D__NO_MATH_INLINES"
1163                 fi;;
1164         *-*-linux*)
1165                 DEBUG="-g -Wall -D_REENTRANT -D__NO_MATH_INLINES -fsigned-char"
1166                 OPT="-O20 -ffast-math -D_REENTRANT -fsigned-char"
1167                 PROFILE="-pg -g -O20 -ffast-math -D_REENTRANT -fsigned-char";;
1168         sparc-sun-*)
1169                 DEBUG="-g -Wall -D__NO_MATH_INLINES -fsigned-char -mv8"
1170                 OPT="-O20 -ffast-math -D__NO_MATH_INLINES -fsigned-char -mv8"
1171                 PROFILE="-pg -g -O20 -D__NO_MATH_INLINES -fsigned-char -mv8" ;;
1172         *)
1173                 DEBUG="-g -Wall -D__NO_MATH_INLINES -fsigned-char"
1174                 OPT="-O20 -D__NO_MATH_INLINES -fsigned-char"
1175                 PROFILE="-O20 -g -pg -D__NO_MATH_INLINES -fsigned-char" ;;
1176         esac
1177 fi
1178
1179 subdirs="vorbis-tools/libao"
1180
1181
1182 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1183 echo "configure:1184: checking for ANSI C header files" >&5
1184 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1185   echo $ac_n "(cached) $ac_c" 1>&6
1186 else
1187   cat > conftest.$ac_ext <<EOF
1188 #line 1189 "configure"
1189 #include "confdefs.h"
1190 #include <stdlib.h>
1191 #include <stdarg.h>
1192 #include <string.h>
1193 #include <float.h>
1194 EOF
1195 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1196 { (eval echo configure:1197: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1197 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1198 if test -z "$ac_err"; then
1199   rm -rf conftest*
1200   ac_cv_header_stdc=yes
1201 else
1202   echo "$ac_err" >&5
1203   echo "configure: failed program was:" >&5
1204   cat conftest.$ac_ext >&5
1205   rm -rf conftest*
1206   ac_cv_header_stdc=no
1207 fi
1208 rm -f conftest*
1209
1210 if test $ac_cv_header_stdc = yes; then
1211   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1212 cat > conftest.$ac_ext <<EOF
1213 #line 1214 "configure"
1214 #include "confdefs.h"
1215 #include <string.h>
1216 EOF
1217 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1218   egrep "memchr" >/dev/null 2>&1; then
1219   :
1220 else
1221   rm -rf conftest*
1222   ac_cv_header_stdc=no
1223 fi
1224 rm -f conftest*
1225
1226 fi
1227
1228 if test $ac_cv_header_stdc = yes; then
1229   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1230 cat > conftest.$ac_ext <<EOF
1231 #line 1232 "configure"
1232 #include "confdefs.h"
1233 #include <stdlib.h>
1234 EOF
1235 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1236   egrep "free" >/dev/null 2>&1; then
1237   :
1238 else
1239   rm -rf conftest*
1240   ac_cv_header_stdc=no
1241 fi
1242 rm -f conftest*
1243
1244 fi
1245
1246 if test $ac_cv_header_stdc = yes; then
1247   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1248 if test "$cross_compiling" = yes; then
1249   :
1250 else
1251   cat > conftest.$ac_ext <<EOF
1252 #line 1253 "configure"
1253 #include "confdefs.h"
1254 #include <ctype.h>
1255 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1256 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1257 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1258 int main () { int i; for (i = 0; i < 256; i++)
1259 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1260 exit (0); }
1261
1262 EOF
1263 if { (eval echo configure:1264: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1264 then
1265   :
1266 else
1267   echo "configure: failed program was:" >&5
1268   cat conftest.$ac_ext >&5
1269   rm -fr conftest*
1270   ac_cv_header_stdc=no
1271 fi
1272 rm -fr conftest*
1273 fi
1274
1275 fi
1276 fi
1277
1278 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1279 if test $ac_cv_header_stdc = yes; then
1280   cat >> confdefs.h <<\EOF
1281 #define STDC_HEADERS 1
1282 EOF
1283
1284 fi
1285
1286
1287 CFLAGS=""
1288
1289
1290 #AC_CHECK_LIB(pthread, pthread_create, 
1291 #       pthread_lib="-lpthread"; AC_DEFINE(HAVE_LIBPTHREAD), :)
1292 # We no longer use config.h
1293 echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
1294 echo "configure:1295: checking for pthread_create in -lpthread" >&5
1295 ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'`
1296 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1297   echo $ac_n "(cached) $ac_c" 1>&6
1298 else
1299   ac_save_LIBS="$LIBS"
1300 LIBS="-lpthread  $LIBS"
1301 cat > conftest.$ac_ext <<EOF
1302 #line 1303 "configure"
1303 #include "confdefs.h"
1304 /* Override any gcc2 internal prototype to avoid an error.  */
1305 /* We use char because int might match the return type of a gcc2
1306     builtin and then its argument prototype would still apply.  */
1307 char pthread_create();
1308
1309 int main() {
1310 pthread_create()
1311 ; return 0; }
1312 EOF
1313 if { (eval echo configure:1314: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1314   rm -rf conftest*
1315   eval "ac_cv_lib_$ac_lib_var=yes"
1316 else
1317   echo "configure: failed program was:" >&5
1318   cat conftest.$ac_ext >&5
1319   rm -rf conftest*
1320   eval "ac_cv_lib_$ac_lib_var=no"
1321 fi
1322 rm -f conftest*
1323 LIBS="$ac_save_LIBS"
1324
1325 fi
1326 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1327   echo "$ac_t""yes" 1>&6
1328   pthread_lib="-lpthread"
1329 else
1330   echo "$ac_t""no" 1>&6
1331 :
1332 fi
1333
1334
1335 #dnl Linuxthreads require you to define _REENTRANT in all threaded
1336 #dnl code.  Bogus, bogus...
1337 #
1338 #if test -n "$pthread_lib"; then
1339 #       case $host in 
1340 #       i?86-*-linux*)
1341 #               AC_DEFINE(_REENTRANT)
1342 #               ;;
1343 #       esac
1344 #fi
1345 # We no longer use config.h
1346
1347 #if test -n "$x_libraries"; then
1348 #       XOGG="yes"
1349 #
1350 #       dnl If we find libgtk installed, great; otherwise assume we have
1351 #       dnl to build it ourselves.
1352 #
1353 #       AC_CHECK_LIB(gtk, gtk_main, :, LIBGTKDIR="libgtk", $X_LIBS -lglib -lgdk -lX11 -lXext -lm)
1354 #
1355 #       dnl libpthread is required for xogg.
1356 #
1357 #       if test -z "$pthread_lib"; then XOGG=""; fi
1358 #
1359 #       dnl If we don't have libgtk installed, and we don't have a libgtk 
1360 #       dnl  subdirectory to build the library ourself, we can't build xogg.
1361 #
1362 #       if test -n "$LIBGTKDIR" -a ! -d "$LIBGTKDIR"; then
1363 #               XOGG=""
1364 #               LIBGTKDIR=""
1365 #       fi
1366 #fi
1367
1368
1369 dummy="__noconf"
1370
1371 #if test -d "$LIBGTKDIR"; then
1372 #       enable_shared="no"; export enable_shared
1373 #       dummy="libgtk"
1374 #       AC_CONFIG_SUBDIRS("$dummy")
1375 #       X_LIBS="-L${srcdir}/libgtk/gtk/.libs -L${srcdir}/libgtk/gdk/.libs -L${srcdir}/libgtk/glib/.libs $X_LIBS"
1376 #fi
1377
1378 echo $ac_n "checking size of short""... $ac_c" 1>&6
1379 echo "configure:1380: checking size of short" >&5
1380 if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then
1381   echo $ac_n "(cached) $ac_c" 1>&6
1382 else
1383   if test "$cross_compiling" = yes; then
1384     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1385 else
1386   cat > conftest.$ac_ext <<EOF
1387 #line 1388 "configure"
1388 #include "confdefs.h"
1389 #include <stdio.h>
1390 main()
1391 {
1392   FILE *f=fopen("conftestval", "w");
1393   if (!f) exit(1);
1394   fprintf(f, "%d\n", sizeof(short));
1395   exit(0);
1396 }
1397 EOF
1398 if { (eval echo configure:1399: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1399 then
1400   ac_cv_sizeof_short=`cat conftestval`
1401 else
1402   echo "configure: failed program was:" >&5
1403   cat conftest.$ac_ext >&5
1404   rm -fr conftest*
1405   ac_cv_sizeof_short=0
1406 fi
1407 rm -fr conftest*
1408 fi
1409
1410 fi
1411 echo "$ac_t""$ac_cv_sizeof_short" 1>&6
1412 cat >> confdefs.h <<EOF
1413 #define SIZEOF_SHORT $ac_cv_sizeof_short
1414 EOF
1415
1416
1417 echo $ac_n "checking size of int""... $ac_c" 1>&6
1418 echo "configure:1419: checking size of int" >&5
1419 if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
1420   echo $ac_n "(cached) $ac_c" 1>&6
1421 else
1422   if test "$cross_compiling" = yes; then
1423     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1424 else
1425   cat > conftest.$ac_ext <<EOF
1426 #line 1427 "configure"
1427 #include "confdefs.h"
1428 #include <stdio.h>
1429 main()
1430 {
1431   FILE *f=fopen("conftestval", "w");
1432   if (!f) exit(1);
1433   fprintf(f, "%d\n", sizeof(int));
1434   exit(0);
1435 }
1436 EOF
1437 if { (eval echo configure:1438: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1438 then
1439   ac_cv_sizeof_int=`cat conftestval`
1440 else
1441   echo "configure: failed program was:" >&5
1442   cat conftest.$ac_ext >&5
1443   rm -fr conftest*
1444   ac_cv_sizeof_int=0
1445 fi
1446 rm -fr conftest*
1447 fi
1448
1449 fi
1450 echo "$ac_t""$ac_cv_sizeof_int" 1>&6
1451 cat >> confdefs.h <<EOF
1452 #define SIZEOF_INT $ac_cv_sizeof_int
1453 EOF
1454
1455
1456 echo $ac_n "checking size of long""... $ac_c" 1>&6
1457 echo "configure:1458: checking size of long" >&5
1458 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
1459   echo $ac_n "(cached) $ac_c" 1>&6
1460 else
1461   if test "$cross_compiling" = yes; then
1462     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1463 else
1464   cat > conftest.$ac_ext <<EOF
1465 #line 1466 "configure"
1466 #include "confdefs.h"
1467 #include <stdio.h>
1468 main()
1469 {
1470   FILE *f=fopen("conftestval", "w");
1471   if (!f) exit(1);
1472   fprintf(f, "%d\n", sizeof(long));
1473   exit(0);
1474 }
1475 EOF
1476 if { (eval echo configure:1477: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1477 then
1478   ac_cv_sizeof_long=`cat conftestval`
1479 else
1480   echo "configure: failed program was:" >&5
1481   cat conftest.$ac_ext >&5
1482   rm -fr conftest*
1483   ac_cv_sizeof_long=0
1484 fi
1485 rm -fr conftest*
1486 fi
1487
1488 fi
1489 echo "$ac_t""$ac_cv_sizeof_long" 1>&6
1490 cat >> confdefs.h <<EOF
1491 #define SIZEOF_LONG $ac_cv_sizeof_long
1492 EOF
1493
1494
1495 echo $ac_n "checking size of long long""... $ac_c" 1>&6
1496 echo "configure:1497: checking size of long long" >&5
1497 if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
1498   echo $ac_n "(cached) $ac_c" 1>&6
1499 else
1500   if test "$cross_compiling" = yes; then
1501     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1502 else
1503   cat > conftest.$ac_ext <<EOF
1504 #line 1505 "configure"
1505 #include "confdefs.h"
1506 #include <stdio.h>
1507 main()
1508 {
1509   FILE *f=fopen("conftestval", "w");
1510   if (!f) exit(1);
1511   fprintf(f, "%d\n", sizeof(long long));
1512   exit(0);
1513 }
1514 EOF
1515 if { (eval echo configure:1516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1516 then
1517   ac_cv_sizeof_long_long=`cat conftestval`
1518 else
1519   echo "configure: failed program was:" >&5
1520   cat conftest.$ac_ext >&5
1521   rm -fr conftest*
1522   ac_cv_sizeof_long_long=0
1523 fi
1524 rm -fr conftest*
1525 fi
1526
1527 fi
1528 echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6
1529 cat >> confdefs.h <<EOF
1530 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
1531 EOF
1532
1533
1534
1535 case 2 in
1536         $ac_cv_sizeof_short) SIZE16="short";;
1537         $ac_cv_sizeof_int) SIZE16="int";;
1538 esac
1539
1540 case 4 in
1541         $ac_cv_sizeof_short) SIZE32="short";;
1542         $ac_cv_sizeof_int) SIZE32="int";;
1543         $ac_cv_sizeof_long) SIZE32="long";;
1544 esac
1545
1546 case 8 in
1547         $ac_cv_sizeof_int) SIZE64="int";;
1548         $ac_cv_sizeof_long) SIZE64="long";;
1549         $ac_cv_sizeof_long_long) SIZE64="long long";;
1550 esac
1551
1552 if test -z "$SIZE16"; then
1553         { echo "configure: error: No 16 bit type found on this platform!" 1>&2; exit 1; }
1554 fi
1555 if test -z "$SIZE32"; then
1556         { echo "configure: error: No 32 bit type found on this platform!" 1>&2; exit 1; }
1557 fi
1558 if test -z "$SIZE64"; then
1559         echo "configure: warning: No 64 bit type found on this platform!" 1>&2
1560 fi
1561         
1562 #AC_CHECK_HEADER(alloca.h,AC_DEFINE(USE_ALLOCA_H),:)
1563 #AC_CHECK_HEADER(memory.h,AC_DEFINE(USE_MEMORY_H),:)
1564 # We no longer use config.h
1565 ac_safe=`echo "alloca.h" | sed 'y%./+-%__p_%'`
1566 echo $ac_n "checking for alloca.h""... $ac_c" 1>&6
1567 echo "configure:1568: checking for alloca.h" >&5
1568 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1569   echo $ac_n "(cached) $ac_c" 1>&6
1570 else
1571   cat > conftest.$ac_ext <<EOF
1572 #line 1573 "configure"
1573 #include "confdefs.h"
1574 #include <alloca.h>
1575 EOF
1576 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1577 { (eval echo configure:1578: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1578 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1579 if test -z "$ac_err"; then
1580   rm -rf conftest*
1581   eval "ac_cv_header_$ac_safe=yes"
1582 else
1583   echo "$ac_err" >&5
1584   echo "configure: failed program was:" >&5
1585   cat conftest.$ac_ext >&5
1586   rm -rf conftest*
1587   eval "ac_cv_header_$ac_safe=no"
1588 fi
1589 rm -f conftest*
1590 fi
1591 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1592   echo "$ac_t""yes" 1>&6
1593   CFLAGS="$CFLAGS -DUSE_ALLOCA_H"
1594 else
1595   echo "$ac_t""no" 1>&6
1596 :
1597 fi
1598
1599 ac_safe=`echo "memory.h" | sed 'y%./+-%__p_%'`
1600 echo $ac_n "checking for memory.h""... $ac_c" 1>&6
1601 echo "configure:1602: checking for memory.h" >&5
1602 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1603   echo $ac_n "(cached) $ac_c" 1>&6
1604 else
1605   cat > conftest.$ac_ext <<EOF
1606 #line 1607 "configure"
1607 #include "confdefs.h"
1608 #include <memory.h>
1609 EOF
1610 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1611 { (eval echo configure:1612: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1612 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1613 if test -z "$ac_err"; then
1614   rm -rf conftest*
1615   eval "ac_cv_header_$ac_safe=yes"
1616 else
1617   echo "$ac_err" >&5
1618   echo "configure: failed program was:" >&5
1619   cat conftest.$ac_ext >&5
1620   rm -rf conftest*
1621   eval "ac_cv_header_$ac_safe=no"
1622 fi
1623 rm -f conftest*
1624 fi
1625 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1626   echo "$ac_t""yes" 1>&6
1627   CFLAGS="$CFLAGS -DUSE_MEMORY_H"
1628 else
1629   echo "$ac_t""no" 1>&6
1630 :
1631 fi
1632
1633
1634 echo $ac_n "checking for working const""... $ac_c" 1>&6
1635 echo "configure:1636: checking for working const" >&5
1636 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
1637   echo $ac_n "(cached) $ac_c" 1>&6
1638 else
1639   cat > conftest.$ac_ext <<EOF
1640 #line 1641 "configure"
1641 #include "confdefs.h"
1642
1643 int main() {
1644
1645 /* Ultrix mips cc rejects this.  */
1646 typedef int charset[2]; const charset x;
1647 /* SunOS 4.1.1 cc rejects this.  */
1648 char const *const *ccp;
1649 char **p;
1650 /* NEC SVR4.0.2 mips cc rejects this.  */
1651 struct point {int x, y;};
1652 static struct point const zero = {0,0};
1653 /* AIX XL C 1.02.0.0 rejects this.
1654    It does not let you subtract one const X* pointer from another in an arm
1655    of an if-expression whose if-part is not a constant expression */
1656 const char *g = "string";
1657 ccp = &g + (g ? g-g : 0);
1658 /* HPUX 7.0 cc rejects these. */
1659 ++ccp;
1660 p = (char**) ccp;
1661 ccp = (char const *const *) p;
1662 { /* SCO 3.2v4 cc rejects this.  */
1663   char *t;
1664   char const *s = 0 ? (char *) 0 : (char const *) 0;
1665
1666   *t++ = 0;
1667 }
1668 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
1669   int x[] = {25, 17};
1670   const int *foo = &x[0];
1671   ++foo;
1672 }
1673 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
1674   typedef const int *iptr;
1675   iptr p = 0;
1676   ++p;
1677 }
1678 { /* AIX XL C 1.02.0.0 rejects this saying
1679      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
1680   struct s { int j; const int *ap[3]; };
1681   struct s *b; b->j = 5;
1682 }
1683 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
1684   const int foo = 10;
1685 }
1686
1687 ; return 0; }
1688 EOF
1689 if { (eval echo configure:1690: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1690   rm -rf conftest*
1691   ac_cv_c_const=yes
1692 else
1693   echo "configure: failed program was:" >&5
1694   cat conftest.$ac_ext >&5
1695   rm -rf conftest*
1696   ac_cv_c_const=no
1697 fi
1698 rm -f conftest*
1699 fi
1700
1701 echo "$ac_t""$ac_cv_c_const" 1>&6
1702 if test $ac_cv_c_const = no; then
1703   cat >> confdefs.h <<\EOF
1704 #define const 
1705 EOF
1706
1707 fi
1708
1709 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
1710 echo "configure:1711: checking whether time.h and sys/time.h may both be included" >&5
1711 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
1712   echo $ac_n "(cached) $ac_c" 1>&6
1713 else
1714   cat > conftest.$ac_ext <<EOF
1715 #line 1716 "configure"
1716 #include "confdefs.h"
1717 #include <sys/types.h>
1718 #include <sys/time.h>
1719 #include <time.h>
1720 int main() {
1721 struct tm *tp;
1722 ; return 0; }
1723 EOF
1724 if { (eval echo configure:1725: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1725   rm -rf conftest*
1726   ac_cv_header_time=yes
1727 else
1728   echo "configure: failed program was:" >&5
1729   cat conftest.$ac_ext >&5
1730   rm -rf conftest*
1731   ac_cv_header_time=no
1732 fi
1733 rm -f conftest*
1734 fi
1735
1736 echo "$ac_t""$ac_cv_header_time" 1>&6
1737 if test $ac_cv_header_time = yes; then
1738   cat >> confdefs.h <<\EOF
1739 #define TIME_WITH_SYS_TIME 1
1740 EOF
1741
1742 fi
1743
1744 echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
1745 echo "configure:1746: checking whether struct tm is in sys/time.h or time.h" >&5
1746 if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
1747   echo $ac_n "(cached) $ac_c" 1>&6
1748 else
1749   cat > conftest.$ac_ext <<EOF
1750 #line 1751 "configure"
1751 #include "confdefs.h"
1752 #include <sys/types.h>
1753 #include <time.h>
1754 int main() {
1755 struct tm *tp; tp->tm_sec;
1756 ; return 0; }
1757 EOF
1758 if { (eval echo configure:1759: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1759   rm -rf conftest*
1760   ac_cv_struct_tm=time.h
1761 else
1762   echo "configure: failed program was:" >&5
1763   cat conftest.$ac_ext >&5
1764   rm -rf conftest*
1765   ac_cv_struct_tm=sys/time.h
1766 fi
1767 rm -f conftest*
1768 fi
1769
1770 echo "$ac_t""$ac_cv_struct_tm" 1>&6
1771 if test $ac_cv_struct_tm = sys/time.h; then
1772   cat >> confdefs.h <<\EOF
1773 #define TM_IN_SYS_TIME 1
1774 EOF
1775
1776 fi
1777
1778
1779 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
1780 echo "configure:1781: checking whether ${MAKE-make} sets \${MAKE}" >&5
1781 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1782 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1783   echo $ac_n "(cached) $ac_c" 1>&6
1784 else
1785   cat > conftestmake <<\EOF
1786 all:
1787         @echo 'ac_maketemp="${MAKE}"'
1788 EOF
1789 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1790 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1791 if test -n "$ac_maketemp"; then
1792   eval ac_cv_prog_make_${ac_make}_set=yes
1793 else
1794   eval ac_cv_prog_make_${ac_make}_set=no
1795 fi
1796 rm -f conftestmake
1797 fi
1798 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1799   echo "$ac_t""yes" 1>&6
1800   SET_MAKE=
1801 else
1802   echo "$ac_t""no" 1>&6
1803   SET_MAKE="MAKE=${MAKE-make}"
1804 fi
1805
1806 echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
1807 echo "configure:1808: checking for 8-bit clean memcmp" >&5
1808 if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then
1809   echo $ac_n "(cached) $ac_c" 1>&6
1810 else
1811   if test "$cross_compiling" = yes; then
1812   ac_cv_func_memcmp_clean=no
1813 else
1814   cat > conftest.$ac_ext <<EOF
1815 #line 1816 "configure"
1816 #include "confdefs.h"
1817
1818 main()
1819 {
1820   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
1821   exit(memcmp(&c0, &c2, 1) < 0 && memcmp(&c1, &c2, 1) < 0 ? 0 : 1);
1822 }
1823
1824 EOF
1825 if { (eval echo configure:1826: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1826 then
1827   ac_cv_func_memcmp_clean=yes
1828 else
1829   echo "configure: failed program was:" >&5
1830   cat conftest.$ac_ext >&5
1831   rm -fr conftest*
1832   ac_cv_func_memcmp_clean=no
1833 fi
1834 rm -fr conftest*
1835 fi
1836
1837 fi
1838
1839 echo "$ac_t""$ac_cv_func_memcmp_clean" 1>&6
1840 test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.${ac_objext}"
1841
1842 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
1843 echo "configure:1844: checking return type of signal handlers" >&5
1844 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
1845   echo $ac_n "(cached) $ac_c" 1>&6
1846 else
1847   cat > conftest.$ac_ext <<EOF
1848 #line 1849 "configure"
1849 #include "confdefs.h"
1850 #include <sys/types.h>
1851 #include <signal.h>
1852 #ifdef signal
1853 #undef signal
1854 #endif
1855 #ifdef __cplusplus
1856 extern "C" void (*signal (int, void (*)(int)))(int);
1857 #else
1858 void (*signal ()) ();
1859 #endif
1860
1861 int main() {
1862 int i;
1863 ; return 0; }
1864 EOF
1865 if { (eval echo configure:1866: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1866   rm -rf conftest*
1867   ac_cv_type_signal=void
1868 else
1869   echo "configure: failed program was:" >&5
1870   cat conftest.$ac_ext >&5
1871   rm -rf conftest*
1872   ac_cv_type_signal=int
1873 fi
1874 rm -f conftest*
1875 fi
1876
1877 echo "$ac_t""$ac_cv_type_signal" 1>&6
1878 cat >> confdefs.h <<EOF
1879 #define RETSIGTYPE $ac_cv_type_signal
1880 EOF
1881
1882
1883 for ac_func in gettimeofday select strcspn strerror strspn sigaction
1884 do
1885 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1886 echo "configure:1887: checking for $ac_func" >&5
1887 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1888   echo $ac_n "(cached) $ac_c" 1>&6
1889 else
1890   cat > conftest.$ac_ext <<EOF
1891 #line 1892 "configure"
1892 #include "confdefs.h"
1893 /* System header to define __stub macros and hopefully few prototypes,
1894     which can conflict with char $ac_func(); below.  */
1895 #include <assert.h>
1896 /* Override any gcc2 internal prototype to avoid an error.  */
1897 /* We use char because int might match the return type of a gcc2
1898     builtin and then its argument prototype would still apply.  */
1899 char $ac_func();
1900
1901 int main() {
1902
1903 /* The GNU C library defines this for functions which it implements
1904     to always fail with ENOSYS.  Some functions are actually named
1905     something starting with __ and the normal name is an alias.  */
1906 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1907 choke me
1908 #else
1909 $ac_func();
1910 #endif
1911
1912 ; return 0; }
1913 EOF
1914 if { (eval echo configure:1915: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1915   rm -rf conftest*
1916   eval "ac_cv_func_$ac_func=yes"
1917 else
1918   echo "configure: failed program was:" >&5
1919   cat conftest.$ac_ext >&5
1920   rm -rf conftest*
1921   eval "ac_cv_func_$ac_func=no"
1922 fi
1923 rm -f conftest*
1924 fi
1925
1926 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1927   echo "$ac_t""yes" 1>&6
1928     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1929   cat >> confdefs.h <<EOF
1930 #define $ac_tr_func 1
1931 EOF
1932  
1933 else
1934   echo "$ac_t""no" 1>&6
1935 fi
1936 done
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948 #AC_SUBST(XOGG)
1949 #AC_SUBST(LIBGTKDIR)
1950
1951
1952 trap '' 1 2 15
1953 cat > confcache <<\EOF
1954 # This file is a shell script that caches the results of configure
1955 # tests run on this system so they can be shared between configure
1956 # scripts and configure runs.  It is not useful on other systems.
1957 # If it contains results you don't want to keep, you may remove or edit it.
1958 #
1959 # By default, configure uses ./config.cache as the cache file,
1960 # creating it if it does not exist already.  You can give configure
1961 # the --cache-file=FILE option to use a different cache file; that is
1962 # what configure does when it calls configure scripts in
1963 # subdirectories, so they share the cache.
1964 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1965 # config.status only pays attention to the cache file if you give it the
1966 # --recheck option to rerun configure.
1967 #
1968 EOF
1969 # The following way of writing the cache mishandles newlines in values,
1970 # but we know of no workaround that is simple, portable, and efficient.
1971 # So, don't put newlines in cache variables' values.
1972 # Ultrix sh set writes to stderr and can't be redirected directly,
1973 # and sets the high bit in the cache file unless we assign to the vars.
1974 (set) 2>&1 |
1975   case `(ac_space=' '; set | grep ac_space) 2>&1` in
1976   *ac_space=\ *)
1977     # `set' does not quote correctly, so add quotes (double-quote substitution
1978     # turns \\\\ into \\, and sed turns \\ into \).
1979     sed -n \
1980       -e "s/'/'\\\\''/g" \
1981       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
1982     ;;
1983   *)
1984     # `set' quotes correctly as required by POSIX, so do not add quotes.
1985     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
1986     ;;
1987   esac >> confcache
1988 if cmp -s $cache_file confcache; then
1989   :
1990 else
1991   if test -w $cache_file; then
1992     echo "updating cache $cache_file"
1993     cat confcache > $cache_file
1994   else
1995     echo "not updating unwritable cache $cache_file"
1996   fi
1997 fi
1998 rm -f confcache
1999
2000 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
2001
2002 test "x$prefix" = xNONE && prefix=$ac_default_prefix
2003 # Let make expand exec_prefix.
2004 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
2005
2006 # Any assignment to VPATH causes Sun make to only execute
2007 # the first set of double-colon rules, so remove it if not needed.
2008 # If there is a colon in the path, we need to keep it.
2009 if test "x$srcdir" = x.; then
2010   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
2011 fi
2012
2013 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
2014
2015 # Transform confdefs.h into DEFS.
2016 # Protect against shell expansion while executing Makefile rules.
2017 # Protect against Makefile macro expansion.
2018 cat > conftest.defs <<\EOF
2019 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
2020 s%[     `~#$^&*(){}\\|;'"<>?]%\\&%g
2021 s%\[%\\&%g
2022 s%\]%\\&%g
2023 s%\$%$$%g
2024 EOF
2025 DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
2026 rm -f conftest.defs
2027
2028
2029 # Without the "./", some shells look in PATH for config.status.
2030 : ${CONFIG_STATUS=./config.status}
2031
2032 echo creating $CONFIG_STATUS
2033 rm -f $CONFIG_STATUS
2034 cat > $CONFIG_STATUS <<EOF
2035 #! /bin/sh
2036 # Generated automatically by configure.
2037 # Run this file to recreate the current configuration.
2038 # This directory was configured as follows,
2039 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2040 #
2041 # $0 $ac_configure_args
2042 #
2043 # Compiler output produced by configure, useful for debugging
2044 # configure, is in ./config.log if it exists.
2045
2046 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
2047 for ac_option
2048 do
2049   case "\$ac_option" in
2050   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
2051     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
2052     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
2053   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
2054     echo "$CONFIG_STATUS generated by autoconf version 2.13"
2055     exit 0 ;;
2056   -help | --help | --hel | --he | --h)
2057     echo "\$ac_cs_usage"; exit 0 ;;
2058   *) echo "\$ac_cs_usage"; exit 1 ;;
2059   esac
2060 done
2061
2062 ac_given_srcdir=$srcdir
2063
2064 trap 'rm -fr `echo "Makefile lib/Makefile examples/Makefile vorbis-tools/Makefile\
2065         vorbis-tools/libao/Makefile vq/Makefile huff/Makefile cmdline/Makefile\
2066         xmms/Makefile kmpg/Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
2067 EOF
2068 cat >> $CONFIG_STATUS <<EOF
2069
2070 # Protect against being on the right side of a sed subst in config.status.
2071 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
2072  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
2073 $ac_vpsub
2074 $extrasub
2075 s%@SHELL@%$SHELL%g
2076 s%@CFLAGS@%$CFLAGS%g
2077 s%@CPPFLAGS@%$CPPFLAGS%g
2078 s%@CXXFLAGS@%$CXXFLAGS%g
2079 s%@FFLAGS@%$FFLAGS%g
2080 s%@DEFS@%$DEFS%g
2081 s%@LDFLAGS@%$LDFLAGS%g
2082 s%@LIBS@%$LIBS%g
2083 s%@exec_prefix@%$exec_prefix%g
2084 s%@prefix@%$prefix%g
2085 s%@program_transform_name@%$program_transform_name%g
2086 s%@bindir@%$bindir%g
2087 s%@sbindir@%$sbindir%g
2088 s%@libexecdir@%$libexecdir%g
2089 s%@datadir@%$datadir%g
2090 s%@sysconfdir@%$sysconfdir%g
2091 s%@sharedstatedir@%$sharedstatedir%g
2092 s%@localstatedir@%$localstatedir%g
2093 s%@libdir@%$libdir%g
2094 s%@includedir@%$includedir%g
2095 s%@oldincludedir@%$oldincludedir%g
2096 s%@infodir@%$infodir%g
2097 s%@mandir@%$mandir%g
2098 s%@host@%$host%g
2099 s%@host_alias@%$host_alias%g
2100 s%@host_cpu@%$host_cpu%g
2101 s%@host_vendor@%$host_vendor%g
2102 s%@host_os@%$host_os%g
2103 s%@CC@%$CC%g
2104 s%@CPP@%$CPP%g
2105 s%@RANLIB@%$RANLIB%g
2106 s%@AR@%$AR%g
2107 s%@INSTALL@%$INSTALL%g
2108 s%@subdirs@%$subdirs%g
2109 s%@SET_MAKE@%$SET_MAKE%g
2110 s%@LIBOBJS@%$LIBOBJS%g
2111 s%@SIZE16@%$SIZE16%g
2112 s%@SIZE32@%$SIZE32%g
2113 s%@SIZE64@%$SIZE64%g
2114 s%@OPT@%$OPT%g
2115 s%@DEBUG@%$DEBUG%g
2116 s%@PROFILE@%$PROFILE%g
2117 s%@pthread_lib@%$pthread_lib%g
2118
2119 CEOF
2120 EOF
2121
2122 cat >> $CONFIG_STATUS <<\EOF
2123
2124 # Split the substitutions into bite-sized pieces for seds with
2125 # small command number limits, like on Digital OSF/1 and HP-UX.
2126 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
2127 ac_file=1 # Number of current file.
2128 ac_beg=1 # First line for current file.
2129 ac_end=$ac_max_sed_cmds # Line after last line for current file.
2130 ac_more_lines=:
2131 ac_sed_cmds=""
2132 while $ac_more_lines; do
2133   if test $ac_beg -gt 1; then
2134     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
2135   else
2136     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
2137   fi
2138   if test ! -s conftest.s$ac_file; then
2139     ac_more_lines=false
2140     rm -f conftest.s$ac_file
2141   else
2142     if test -z "$ac_sed_cmds"; then
2143       ac_sed_cmds="sed -f conftest.s$ac_file"
2144     else
2145       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
2146     fi
2147     ac_file=`expr $ac_file + 1`
2148     ac_beg=$ac_end
2149     ac_end=`expr $ac_end + $ac_max_sed_cmds`
2150   fi
2151 done
2152 if test -z "$ac_sed_cmds"; then
2153   ac_sed_cmds=cat
2154 fi
2155 EOF
2156
2157 cat >> $CONFIG_STATUS <<EOF
2158
2159 CONFIG_FILES=\${CONFIG_FILES-"Makefile lib/Makefile examples/Makefile vorbis-tools/Makefile\
2160         vorbis-tools/libao/Makefile vq/Makefile huff/Makefile cmdline/Makefile\
2161         xmms/Makefile kmpg/Makefile"}
2162 EOF
2163 cat >> $CONFIG_STATUS <<\EOF
2164 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
2165   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2166   case "$ac_file" in
2167   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2168        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2169   *) ac_file_in="${ac_file}.in" ;;
2170   esac
2171
2172   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
2173
2174   # Remove last slash and all that follows it.  Not all systems have dirname.
2175   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2176   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2177     # The file is in a subdirectory.
2178     test ! -d "$ac_dir" && mkdir "$ac_dir"
2179     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
2180     # A "../" for each directory in $ac_dir_suffix.
2181     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
2182   else
2183     ac_dir_suffix= ac_dots=
2184   fi
2185
2186   case "$ac_given_srcdir" in
2187   .)  srcdir=.
2188       if test -z "$ac_dots"; then top_srcdir=.
2189       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
2190   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
2191   *) # Relative path.
2192     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
2193     top_srcdir="$ac_dots$ac_given_srcdir" ;;
2194   esac
2195
2196
2197   echo creating "$ac_file"
2198   rm -f "$ac_file"
2199   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
2200   case "$ac_file" in
2201   *Makefile*) ac_comsub="1i\\
2202 # $configure_input" ;;
2203   *) ac_comsub= ;;
2204   esac
2205
2206   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2207   sed -e "$ac_comsub
2208 s%@configure_input@%$configure_input%g
2209 s%@srcdir@%$srcdir%g
2210 s%@top_srcdir@%$top_srcdir%g
2211 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
2212 fi; done
2213 rm -f conftest.s*
2214
2215 EOF
2216 cat >> $CONFIG_STATUS <<EOF
2217
2218 EOF
2219 cat >> $CONFIG_STATUS <<\EOF
2220
2221 exit 0
2222 EOF
2223 chmod +x $CONFIG_STATUS
2224 rm -fr confdefs* $ac_clean_files
2225 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
2226
2227 if test "$no_recursion" != yes; then
2228
2229   # Remove --cache-file and --srcdir arguments so they do not pile up.
2230   ac_sub_configure_args=
2231   ac_prev=
2232   for ac_arg in $ac_configure_args; do
2233     if test -n "$ac_prev"; then
2234       ac_prev=
2235       continue
2236     fi
2237     case "$ac_arg" in
2238     -cache-file | --cache-file | --cache-fil | --cache-fi \
2239     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
2240       ac_prev=cache_file ;;
2241     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
2242     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
2243       ;;
2244     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
2245       ac_prev=srcdir ;;
2246     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
2247       ;;
2248     *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;;
2249     esac
2250   done
2251
2252   for ac_config_dir in vorbis-tools/libao; do
2253
2254     # Do not complain, so a configure script can configure whichever
2255     # parts of a large source tree are present.
2256     if test ! -d $srcdir/$ac_config_dir; then
2257       continue
2258     fi
2259
2260     echo configuring in $ac_config_dir
2261
2262     case "$srcdir" in
2263     .) ;;
2264     *)
2265       if test -d ./$ac_config_dir || mkdir ./$ac_config_dir; then :;
2266       else
2267         { echo "configure: error: can not create `pwd`/$ac_config_dir" 1>&2; exit 1; }
2268       fi
2269       ;;
2270     esac
2271
2272     ac_popdir=`pwd`
2273     cd $ac_config_dir
2274
2275       # A "../" for each directory in /$ac_config_dir.
2276       ac_dots=`echo $ac_config_dir|sed -e 's%^\./%%' -e 's%[^/]$%&/%' -e 's%[^/]*/%../%g'`
2277
2278     case "$srcdir" in
2279     .) # No --srcdir option.  We are building in place.
2280       ac_sub_srcdir=$srcdir ;;
2281     /*) # Absolute path.
2282       ac_sub_srcdir=$srcdir/$ac_config_dir ;;
2283     *) # Relative path.
2284       ac_sub_srcdir=$ac_dots$srcdir/$ac_config_dir ;;
2285     esac
2286
2287     # Check for guested configure; otherwise get Cygnus style configure.
2288     if test -f $ac_sub_srcdir/configure; then
2289       ac_sub_configure=$ac_sub_srcdir/configure
2290     elif test -f $ac_sub_srcdir/configure.in; then
2291       ac_sub_configure=$ac_configure
2292     else
2293       echo "configure: warning: no configuration information is in $ac_config_dir" 1>&2
2294       ac_sub_configure=
2295     fi
2296
2297     # The recursion is here.
2298     if test -n "$ac_sub_configure"; then
2299
2300       # Make the cache file name correct relative to the subdirectory.
2301       case "$cache_file" in
2302       /*) ac_sub_cache_file=$cache_file ;;
2303       *) # Relative path.
2304         ac_sub_cache_file="$ac_dots$cache_file" ;;
2305       esac
2306
2307       echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir"
2308       # The eval makes quoting arguments work.
2309       if eval ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir
2310       then :
2311       else
2312         { echo "configure: error: $ac_sub_configure failed for $ac_config_dir" 1>&2; exit 1; }
2313       fi
2314     fi
2315
2316     cd $ac_popdir
2317   done
2318 fi
2319
2320