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