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