]> git.sesse.net Git - vlc/blob - configure
* Fixed a segfault in the Mac OS X interface.
[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   --with-libiconv-prefix=DIR  search for libiconv in DIR/include and DIR/lib"
16 ac_help="$ac_help
17   --disable-nls           do not use Native Language Support"
18 ac_help="$ac_help
19   --with-included-gettext use the GNU gettext library included here"
20 ac_help="$ac_help
21 "
22 ac_help="$ac_help
23 Optimization options:"
24 ac_help="$ac_help
25   --with-tuning=ARCH      enable special tuning for an architecture
26                           (default i686 on IA-32 and 750 on PPC)"
27 ac_help="$ac_help
28   --disable-optimizations disable compiler optimizations (default enabled)"
29 ac_help="$ac_help
30   --disable-altivec       disable altivec optimizations (default enabled on PPC)"
31 ac_help="$ac_help
32   --enable-debug          debug mode (default disabled)"
33 ac_help="$ac_help
34   --enable-release        activate extra optimizations (default disabled)"
35 ac_help="$ac_help
36 Input plugins:"
37 ac_help="$ac_help
38   --enable-dvd            DVD input module (default enabled)"
39 ac_help="$ac_help
40     --with-dvdcss=PATH    libdvdcss headers and libraries"
41 ac_help="$ac_help
42     --with-dvdcss-tree=PATH libdvdcss tree for static linking"
43 ac_help="$ac_help
44   --enable-dvdread        dvdread input module (default disabled)"
45 ac_help="$ac_help
46     --with-dvdread=PATH   libdvdread headers and libraries"
47 ac_help="$ac_help
48   --enable-dvbpsi        dvbpsi ts demux module (default disabled)"
49 ac_help="$ac_help
50     --with-dvbpsi=PATH    libdvbpsi headers and libraries"
51 ac_help="$ac_help
52   --enable-vcd            VCD support for Linux, FreeBSD and MacOS X (default enabled)"
53 ac_help="$ac_help
54   --enable-satellite      satellite card support (default disabled)"
55 ac_help="$ac_help
56   --enable-avi            AVI demux module (default enabled)"
57 ac_help="$ac_help
58 Codec plugins:"
59 ac_help="$ac_help
60   --enable-mad            libmad module (default disabled)"
61 ac_help="$ac_help
62     --with-mad=PATH       path to libmad"
63 ac_help="$ac_help
64     --with-mad-tree=PATH  mad tree for static linking"
65 ac_help="$ac_help
66   --enable-ffmpeg         ffmpeg codec (default disabled)"
67 ac_help="$ac_help
68     --with-ffmpeg=PATH    path to ffmpeg installation"
69 ac_help="$ac_help
70     --with-ffmpeg-tree=PATH ffmpeg tree for static linking"
71 ac_help="$ac_help
72   --enable-a52            AC3 support with liba52 (default enabled)"
73 ac_help="$ac_help
74     --with-a52-tree=PATH  a52dec tree for static linking "
75 ac_help="$ac_help
76   --enable-vorbis         Ogg/Vorbis decoder support (default enabled)"
77 ac_help="$ac_help
78 Video plugins:"
79 ac_help="$ac_help
80   --enable-x11            X11 support (default enabled)"
81 ac_help="$ac_help
82   --enable-xvideo         XVideo support (default enabled)"
83 ac_help="$ac_help
84   --enable-sdl            SDL support (default enabled)"
85 ac_help="$ac_help
86     --with-sdl-config-path=PATH sdl-config path (default search in \$PATH)"
87 ac_help="$ac_help
88   --enable-directx        Win32 DirectX support (default enabled on Win32)"
89 ac_help="$ac_help
90     --with-directx=PATH   Win32 DirectX headers and libraries"
91 ac_help="$ac_help
92   --enable-fb             Linux framebuffer support (default enabled on Linux)"
93 ac_help="$ac_help
94   --enable-mga            Linux kernel Matrox support (default disabled)"
95 ac_help="$ac_help
96   --enable-ggi            GGI support (default disabled)"
97 ac_help="$ac_help
98     --with-ggi=PATH       path to libggi"
99 ac_help="$ac_help
100   --enable-glide          Glide (3dfx) support (default disabled)"
101 ac_help="$ac_help
102     --with-glide=PATH     path to libglide"
103 ac_help="$ac_help
104   --enable-aa             aalib output (default disabled)"
105 ac_help="$ac_help
106 Audio plugins:"
107 ac_help="$ac_help
108   --enable-dsp            Linux /dev/dsp support (enabled on Linux)"
109 ac_help="$ac_help
110   --enable-esd            Esound library support (default disabled)"
111 ac_help="$ac_help
112   --enable-arts           aRts sound server (default disabled)"
113 ac_help="$ac_help
114   --enable-alsa           ALSA sound support for Linux (default disabled)"
115 ac_help="$ac_help
116   --enable-waveout        Win32 waveOut module (default enabled on Win32)"
117 ac_help="$ac_help
118 Interface plugins:"
119 ac_help="$ac_help
120   --enable-gtk            Gtk+ support (default enabled)"
121 ac_help="$ac_help
122     --with-gtk-config-path=PATH gtk-config path (default search in \$PATH)"
123 ac_help="$ac_help
124   --enable-gnome          Gnome interface support (default disabled)"
125 ac_help="$ac_help
126   --enable-qt             Qt interface support (default disabled)"
127 ac_help="$ac_help
128   --enable-kde            KDE interface support (default disabled)"
129 ac_help="$ac_help
130   --enable-macosx         MacOS X support (default enabled on MacOS X)"
131 ac_help="$ac_help
132   --enable-qnx            QNX RTOS support (default enabled on QNX RTOS)"
133 ac_help="$ac_help
134   --enable-intfwin        Win32 interface support (default disabled)"
135 ac_help="$ac_help
136     --with-bcbuilder=PATH Borland C++ Builder installation path"
137 ac_help="$ac_help
138   --enable-ncurses        ncurses interface support (default disabled)"
139 ac_help="$ac_help
140   --enable-lirc           lirc support (default disabled)"
141 ac_help="$ac_help
142 Misc options:"
143 ac_help="$ac_help
144   --with-words=endianness set endianness (big or little)"
145 ac_help="$ac_help
146   --enable-gprof          gprof profiling (default disabled)"
147 ac_help="$ac_help
148   --enable-cprof          cprof profiling (default disabled)"
149 ac_help="$ac_help
150   --enable-pth            GNU Pth support (default disabled)"
151 ac_help="$ac_help
152   --enable-st             State Threads (default disabled)"
153 ac_help="$ac_help
154   --disable-plugins       make all plug-ins built-in (default plug-ins enabled)"
155
156 # Initialize some variables set by options.
157 # The variables have the same names as the options, with
158 # dashes changed to underlines.
159 build=NONE
160 cache_file=./config.cache
161 exec_prefix=NONE
162 host=NONE
163 no_create=
164 nonopt=NONE
165 no_recursion=
166 prefix=NONE
167 program_prefix=NONE
168 program_suffix=NONE
169 program_transform_name=s,x,x,
170 silent=
171 site=
172 srcdir=
173 target=NONE
174 verbose=
175 x_includes=NONE
176 x_libraries=NONE
177 bindir='${exec_prefix}/bin'
178 sbindir='${exec_prefix}/sbin'
179 libexecdir='${exec_prefix}/libexec'
180 datadir='${prefix}/share'
181 sysconfdir='${prefix}/etc'
182 sharedstatedir='${prefix}/com'
183 localstatedir='${prefix}/var'
184 libdir='${exec_prefix}/lib'
185 includedir='${prefix}/include'
186 oldincludedir='/usr/include'
187 infodir='${prefix}/info'
188 mandir='${prefix}/man'
189
190 # Initialize some other variables.
191 subdirs=
192 MFLAGS= MAKEFLAGS=
193 SHELL=${CONFIG_SHELL-/bin/sh}
194 # Maximum number of lines to put in a shell here document.
195 ac_max_here_lines=12
196
197 ac_prev=
198 for ac_option
199 do
200
201   # If the previous option needs an argument, assign it.
202   if test -n "$ac_prev"; then
203     eval "$ac_prev=\$ac_option"
204     ac_prev=
205     continue
206   fi
207
208   case "$ac_option" in
209   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
210   *) ac_optarg= ;;
211   esac
212
213   # Accept the important Cygnus configure options, so we can diagnose typos.
214
215   case "$ac_option" in
216
217   -bindir | --bindir | --bindi | --bind | --bin | --bi)
218     ac_prev=bindir ;;
219   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
220     bindir="$ac_optarg" ;;
221
222   -build | --build | --buil | --bui | --bu)
223     ac_prev=build ;;
224   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
225     build="$ac_optarg" ;;
226
227   -cache-file | --cache-file | --cache-fil | --cache-fi \
228   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
229     ac_prev=cache_file ;;
230   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
231   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
232     cache_file="$ac_optarg" ;;
233
234   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
235     ac_prev=datadir ;;
236   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
237   | --da=*)
238     datadir="$ac_optarg" ;;
239
240   -disable-* | --disable-*)
241     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
242     # Reject names that are not valid shell variable names.
243     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
244       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
245     fi
246     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
247     eval "enable_${ac_feature}=no" ;;
248
249   -enable-* | --enable-*)
250     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
251     # Reject names that are not valid shell variable names.
252     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
253       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
254     fi
255     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
256     case "$ac_option" in
257       *=*) ;;
258       *) ac_optarg=yes ;;
259     esac
260     eval "enable_${ac_feature}='$ac_optarg'" ;;
261
262   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
263   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
264   | --exec | --exe | --ex)
265     ac_prev=exec_prefix ;;
266   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
267   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
268   | --exec=* | --exe=* | --ex=*)
269     exec_prefix="$ac_optarg" ;;
270
271   -gas | --gas | --ga | --g)
272     # Obsolete; use --with-gas.
273     with_gas=yes ;;
274
275   -help | --help | --hel | --he)
276     # Omit some internal or obsolete options to make the list less imposing.
277     # This message is too long to be a string in the A/UX 3.1 sh.
278     cat << EOF
279 Usage: configure [options] [host]
280 Options: [defaults in brackets after descriptions]
281 Configuration:
282   --cache-file=FILE       cache test results in FILE
283   --help                  print this message
284   --no-create             do not create output files
285   --quiet, --silent       do not print \`checking...' messages
286   --version               print the version of autoconf that created configure
287 Directory and file names:
288   --prefix=PREFIX         install architecture-independent files in PREFIX
289                           [$ac_default_prefix]
290   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
291                           [same as prefix]
292   --bindir=DIR            user executables in DIR [EPREFIX/bin]
293   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
294   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
295   --datadir=DIR           read-only architecture-independent data in DIR
296                           [PREFIX/share]
297   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
298   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
299                           [PREFIX/com]
300   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
301   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
302   --includedir=DIR        C header files in DIR [PREFIX/include]
303   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
304   --infodir=DIR           info documentation in DIR [PREFIX/info]
305   --mandir=DIR            man documentation in DIR [PREFIX/man]
306   --srcdir=DIR            find the sources in DIR [configure dir or ..]
307   --program-prefix=PREFIX prepend PREFIX to installed program names
308   --program-suffix=SUFFIX append SUFFIX to installed program names
309   --program-transform-name=PROGRAM
310                           run sed PROGRAM on installed program names
311 EOF
312     cat << EOF
313 Host type:
314   --build=BUILD           configure for building on BUILD [BUILD=HOST]
315   --host=HOST             configure for HOST [guessed]
316   --target=TARGET         configure for TARGET [TARGET=HOST]
317 Features and packages:
318   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
319   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
320   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
321   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
322   --x-includes=DIR        X include files are in DIR
323   --x-libraries=DIR       X library files are in DIR
324 EOF
325     if test -n "$ac_help"; then
326       echo "--enable and --with options recognized:$ac_help"
327     fi
328     exit 0 ;;
329
330   -host | --host | --hos | --ho)
331     ac_prev=host ;;
332   -host=* | --host=* | --hos=* | --ho=*)
333     host="$ac_optarg" ;;
334
335   -includedir | --includedir | --includedi | --included | --include \
336   | --includ | --inclu | --incl | --inc)
337     ac_prev=includedir ;;
338   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
339   | --includ=* | --inclu=* | --incl=* | --inc=*)
340     includedir="$ac_optarg" ;;
341
342   -infodir | --infodir | --infodi | --infod | --info | --inf)
343     ac_prev=infodir ;;
344   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
345     infodir="$ac_optarg" ;;
346
347   -libdir | --libdir | --libdi | --libd)
348     ac_prev=libdir ;;
349   -libdir=* | --libdir=* | --libdi=* | --libd=*)
350     libdir="$ac_optarg" ;;
351
352   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
353   | --libexe | --libex | --libe)
354     ac_prev=libexecdir ;;
355   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
356   | --libexe=* | --libex=* | --libe=*)
357     libexecdir="$ac_optarg" ;;
358
359   -localstatedir | --localstatedir | --localstatedi | --localstated \
360   | --localstate | --localstat | --localsta | --localst \
361   | --locals | --local | --loca | --loc | --lo)
362     ac_prev=localstatedir ;;
363   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
364   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
365   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
366     localstatedir="$ac_optarg" ;;
367
368   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
369     ac_prev=mandir ;;
370   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
371     mandir="$ac_optarg" ;;
372
373   -nfp | --nfp | --nf)
374     # Obsolete; use --without-fp.
375     with_fp=no ;;
376
377   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
378   | --no-cr | --no-c)
379     no_create=yes ;;
380
381   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
382   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
383     no_recursion=yes ;;
384
385   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
386   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
387   | --oldin | --oldi | --old | --ol | --o)
388     ac_prev=oldincludedir ;;
389   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
390   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
391   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
392     oldincludedir="$ac_optarg" ;;
393
394   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
395     ac_prev=prefix ;;
396   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
397     prefix="$ac_optarg" ;;
398
399   -program-prefix | --program-prefix | --program-prefi | --program-pref \
400   | --program-pre | --program-pr | --program-p)
401     ac_prev=program_prefix ;;
402   -program-prefix=* | --program-prefix=* | --program-prefi=* \
403   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
404     program_prefix="$ac_optarg" ;;
405
406   -program-suffix | --program-suffix | --program-suffi | --program-suff \
407   | --program-suf | --program-su | --program-s)
408     ac_prev=program_suffix ;;
409   -program-suffix=* | --program-suffix=* | --program-suffi=* \
410   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
411     program_suffix="$ac_optarg" ;;
412
413   -program-transform-name | --program-transform-name \
414   | --program-transform-nam | --program-transform-na \
415   | --program-transform-n | --program-transform- \
416   | --program-transform | --program-transfor \
417   | --program-transfo | --program-transf \
418   | --program-trans | --program-tran \
419   | --progr-tra | --program-tr | --program-t)
420     ac_prev=program_transform_name ;;
421   -program-transform-name=* | --program-transform-name=* \
422   | --program-transform-nam=* | --program-transform-na=* \
423   | --program-transform-n=* | --program-transform-=* \
424   | --program-transform=* | --program-transfor=* \
425   | --program-transfo=* | --program-transf=* \
426   | --program-trans=* | --program-tran=* \
427   | --progr-tra=* | --program-tr=* | --program-t=*)
428     program_transform_name="$ac_optarg" ;;
429
430   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
431   | -silent | --silent | --silen | --sile | --sil)
432     silent=yes ;;
433
434   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
435     ac_prev=sbindir ;;
436   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
437   | --sbi=* | --sb=*)
438     sbindir="$ac_optarg" ;;
439
440   -sharedstatedir | --sharedstatedir | --sharedstatedi \
441   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
442   | --sharedst | --shareds | --shared | --share | --shar \
443   | --sha | --sh)
444     ac_prev=sharedstatedir ;;
445   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
446   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
447   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
448   | --sha=* | --sh=*)
449     sharedstatedir="$ac_optarg" ;;
450
451   -site | --site | --sit)
452     ac_prev=site ;;
453   -site=* | --site=* | --sit=*)
454     site="$ac_optarg" ;;
455
456   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
457     ac_prev=srcdir ;;
458   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
459     srcdir="$ac_optarg" ;;
460
461   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
462   | --syscon | --sysco | --sysc | --sys | --sy)
463     ac_prev=sysconfdir ;;
464   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
465   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
466     sysconfdir="$ac_optarg" ;;
467
468   -target | --target | --targe | --targ | --tar | --ta | --t)
469     ac_prev=target ;;
470   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
471     target="$ac_optarg" ;;
472
473   -v | -verbose | --verbose | --verbos | --verbo | --verb)
474     verbose=yes ;;
475
476   -version | --version | --versio | --versi | --vers)
477     echo "configure generated by autoconf version 2.13"
478     exit 0 ;;
479
480   -with-* | --with-*)
481     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
482     # Reject names that are not valid shell variable names.
483     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
484       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
485     fi
486     ac_package=`echo $ac_package| sed 's/-/_/g'`
487     case "$ac_option" in
488       *=*) ;;
489       *) ac_optarg=yes ;;
490     esac
491     eval "with_${ac_package}='$ac_optarg'" ;;
492
493   -without-* | --without-*)
494     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
495     # Reject names that are not valid shell variable names.
496     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
497       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
498     fi
499     ac_package=`echo $ac_package| sed 's/-/_/g'`
500     eval "with_${ac_package}=no" ;;
501
502   --x)
503     # Obsolete; use --with-x.
504     with_x=yes ;;
505
506   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
507   | --x-incl | --x-inc | --x-in | --x-i)
508     ac_prev=x_includes ;;
509   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
510   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
511     x_includes="$ac_optarg" ;;
512
513   -x-libraries | --x-libraries | --x-librarie | --x-librari \
514   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
515     ac_prev=x_libraries ;;
516   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
517   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
518     x_libraries="$ac_optarg" ;;
519
520   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
521     ;;
522
523   *)
524     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
525       echo "configure: warning: $ac_option: invalid host type" 1>&2
526     fi
527     if test "x$nonopt" != xNONE; then
528       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
529     fi
530     nonopt="$ac_option"
531     ;;
532
533   esac
534 done
535
536 if test -n "$ac_prev"; then
537   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
538 fi
539
540 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
541
542 # File descriptor usage:
543 # 0 standard input
544 # 1 file creation
545 # 2 errors and warnings
546 # 3 some systems may open it to /dev/tty
547 # 4 used on the Kubota Titan
548 # 6 checking for... messages and results
549 # 5 compiler messages saved in config.log
550 if test "$silent" = yes; then
551   exec 6>/dev/null
552 else
553   exec 6>&1
554 fi
555 exec 5>./config.log
556
557 echo "\
558 This file contains any messages produced by compilers while
559 running configure, to aid debugging if configure makes a mistake.
560 " 1>&5
561
562 # Strip out --no-create and --no-recursion so they do not pile up.
563 # Also quote any args containing shell metacharacters.
564 ac_configure_args=
565 for ac_arg
566 do
567   case "$ac_arg" in
568   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
569   | --no-cr | --no-c) ;;
570   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
571   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
572   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
573   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
574   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
575   esac
576 done
577
578 # NLS nuisances.
579 # Only set these to C if already set.  These must not be set unconditionally
580 # because not all systems understand e.g. LANG=C (notably SCO).
581 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
582 # Non-C LC_CTYPE values break the ctype check.
583 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
584 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
585 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
586 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
587
588 # confdefs.h avoids OS command line length limits that DEFS can exceed.
589 rm -rf conftest* confdefs.h
590 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
591 echo > confdefs.h
592
593 # A filename unique to this package, relative to the directory that
594 # configure is in, which we can look for to find out if srcdir is correct.
595 ac_unique_file=include/main.h
596
597 # Find the source files, if location was not specified.
598 if test -z "$srcdir"; then
599   ac_srcdir_defaulted=yes
600   # Try the directory containing this script, then its parent.
601   ac_prog=$0
602   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
603   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
604   srcdir=$ac_confdir
605   if test ! -r $srcdir/$ac_unique_file; then
606     srcdir=..
607   fi
608 else
609   ac_srcdir_defaulted=no
610 fi
611 if test ! -r $srcdir/$ac_unique_file; then
612   if test "$ac_srcdir_defaulted" = yes; then
613     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
614   else
615     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
616   fi
617 fi
618 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
619
620 # Prefer explicitly selected file to automatically selected ones.
621 if test -z "$CONFIG_SITE"; then
622   if test "x$prefix" != xNONE; then
623     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
624   else
625     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
626   fi
627 fi
628 for ac_site_file in $CONFIG_SITE; do
629   if test -r "$ac_site_file"; then
630     echo "loading site script $ac_site_file"
631     . "$ac_site_file"
632   fi
633 done
634
635 if test -r "$cache_file"; then
636   echo "loading cache $cache_file"
637   . $cache_file
638 else
639   echo "creating cache $cache_file"
640   > $cache_file
641 fi
642
643 ac_ext=c
644 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
645 ac_cpp='$CPP $CPPFLAGS'
646 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
647 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
648 cross_compiling=$ac_cv_prog_cc_cross
649
650 ac_exeext=
651 ac_objext=o
652 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
653   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
654   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
655     ac_n= ac_c='
656 ' ac_t='        '
657   else
658     ac_n=-n ac_c= ac_t=
659   fi
660 else
661   ac_n= ac_c='\c' ac_t=
662 fi
663
664
665
666 ac_aux_dir=
667 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
668   if test -f $ac_dir/install-sh; then
669     ac_aux_dir=$ac_dir
670     ac_install_sh="$ac_aux_dir/install-sh -c"
671     break
672   elif test -f $ac_dir/install.sh; then
673     ac_aux_dir=$ac_dir
674     ac_install_sh="$ac_aux_dir/install.sh -c"
675     break
676   fi
677 done
678 if test -z "$ac_aux_dir"; then
679   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
680 fi
681 ac_config_guess=$ac_aux_dir/config.guess
682 ac_config_sub=$ac_aux_dir/config.sub
683 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
684
685
686 # Do some error checking and defaulting for the host and target type.
687 # The inputs are:
688 #    configure --host=HOST --target=TARGET --build=BUILD NONOPT
689 #
690 # The rules are:
691 # 1. You are not allowed to specify --host, --target, and nonopt at the
692 #    same time.
693 # 2. Host defaults to nonopt.
694 # 3. If nonopt is not specified, then host defaults to the current host,
695 #    as determined by config.guess.
696 # 4. Target and build default to nonopt.
697 # 5. If nonopt is not specified, then target and build default to host.
698
699 # The aliases save the names the user supplied, while $host etc.
700 # will get canonicalized.
701 case $host---$target---$nonopt in
702 NONE---*---* | *---NONE---* | *---*---NONE) ;;
703 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
704 esac
705
706
707 # Make sure we can run config.sub.
708 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
709 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
710 fi
711
712 echo $ac_n "checking host system type""... $ac_c" 1>&6
713 echo "configure:714: checking host system type" >&5
714
715 host_alias=$host
716 case "$host_alias" in
717 NONE)
718   case $nonopt in
719   NONE)
720     if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
721     else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
722     fi ;;
723   *) host_alias=$nonopt ;;
724   esac ;;
725 esac
726
727 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
728 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
729 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
730 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
731 echo "$ac_t""$host" 1>&6
732
733 echo $ac_n "checking target system type""... $ac_c" 1>&6
734 echo "configure:735: checking target system type" >&5
735
736 target_alias=$target
737 case "$target_alias" in
738 NONE)
739   case $nonopt in
740   NONE) target_alias=$host_alias ;;
741   *) target_alias=$nonopt ;;
742   esac ;;
743 esac
744
745 target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
746 target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
747 target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
748 target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
749 echo "$ac_t""$target" 1>&6
750
751 echo $ac_n "checking build system type""... $ac_c" 1>&6
752 echo "configure:753: checking build system type" >&5
753
754 build_alias=$build
755 case "$build_alias" in
756 NONE)
757   case $nonopt in
758   NONE) build_alias=$host_alias ;;
759   *) build_alias=$nonopt ;;
760   esac ;;
761 esac
762
763 build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
764 build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
765 build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
766 build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
767 echo "$ac_t""$build" 1>&6
768
769 test "$host_alias" != "$target_alias" &&
770   test "$program_prefix$program_suffix$program_transform_name" = \
771     NONENONEs,x,x, &&
772   program_prefix=${target_alias}-
773
774
775 PACKAGE="vlc"
776 VERSION="0.3.1"
777 CODENAME=Ourumov
778
779 save_CFLAGS="${CFLAGS}"
780 save_CPPFLAGS="${CPPFLAGS}"
781 save_LDFLAGS="${LDFLAGS}"
782
783 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
784 echo "configure:785: checking whether ${MAKE-make} sets \${MAKE}" >&5
785 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
786 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
787   echo $ac_n "(cached) $ac_c" 1>&6
788 else
789   cat > conftestmake <<\EOF
790 all:
791         @echo 'ac_maketemp="${MAKE}"'
792 EOF
793 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
794 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
795 if test -n "$ac_maketemp"; then
796   eval ac_cv_prog_make_${ac_make}_set=yes
797 else
798   eval ac_cv_prog_make_${ac_make}_set=no
799 fi
800 rm -f conftestmake
801 fi
802 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
803   echo "$ac_t""yes" 1>&6
804   SET_MAKE=
805 else
806   echo "$ac_t""no" 1>&6
807   SET_MAKE="MAKE=${MAKE-make}"
808 fi
809
810 # Extract the first word of "gcc", so it can be a program name with args.
811 set dummy gcc; ac_word=$2
812 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
813 echo "configure:814: checking for $ac_word" >&5
814 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
815   echo $ac_n "(cached) $ac_c" 1>&6
816 else
817   if test -n "$CC"; then
818   ac_cv_prog_CC="$CC" # Let the user override the test.
819 else
820   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
821   ac_dummy="$PATH"
822   for ac_dir in $ac_dummy; do
823     test -z "$ac_dir" && ac_dir=.
824     if test -f $ac_dir/$ac_word; then
825       ac_cv_prog_CC="gcc"
826       break
827     fi
828   done
829   IFS="$ac_save_ifs"
830 fi
831 fi
832 CC="$ac_cv_prog_CC"
833 if test -n "$CC"; then
834   echo "$ac_t""$CC" 1>&6
835 else
836   echo "$ac_t""no" 1>&6
837 fi
838
839 if test -z "$CC"; then
840   # Extract the first word of "cc", so it can be a program name with args.
841 set dummy cc; ac_word=$2
842 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
843 echo "configure:844: checking for $ac_word" >&5
844 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
845   echo $ac_n "(cached) $ac_c" 1>&6
846 else
847   if test -n "$CC"; then
848   ac_cv_prog_CC="$CC" # Let the user override the test.
849 else
850   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
851   ac_prog_rejected=no
852   ac_dummy="$PATH"
853   for ac_dir in $ac_dummy; do
854     test -z "$ac_dir" && ac_dir=.
855     if test -f $ac_dir/$ac_word; then
856       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
857         ac_prog_rejected=yes
858         continue
859       fi
860       ac_cv_prog_CC="cc"
861       break
862     fi
863   done
864   IFS="$ac_save_ifs"
865 if test $ac_prog_rejected = yes; then
866   # We found a bogon in the path, so make sure we never use it.
867   set dummy $ac_cv_prog_CC
868   shift
869   if test $# -gt 0; then
870     # We chose a different compiler from the bogus one.
871     # However, it has the same basename, so the bogon will be chosen
872     # first if we set CC to just the basename; use the full file name.
873     shift
874     set dummy "$ac_dir/$ac_word" "$@"
875     shift
876     ac_cv_prog_CC="$@"
877   fi
878 fi
879 fi
880 fi
881 CC="$ac_cv_prog_CC"
882 if test -n "$CC"; then
883   echo "$ac_t""$CC" 1>&6
884 else
885   echo "$ac_t""no" 1>&6
886 fi
887
888   if test -z "$CC"; then
889     case "`uname -s`" in
890     *win32* | *WIN32*)
891       # Extract the first word of "cl", so it can be a program name with args.
892 set dummy cl; ac_word=$2
893 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
894 echo "configure:895: checking for $ac_word" >&5
895 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
896   echo $ac_n "(cached) $ac_c" 1>&6
897 else
898   if test -n "$CC"; then
899   ac_cv_prog_CC="$CC" # Let the user override the test.
900 else
901   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
902   ac_dummy="$PATH"
903   for ac_dir in $ac_dummy; do
904     test -z "$ac_dir" && ac_dir=.
905     if test -f $ac_dir/$ac_word; then
906       ac_cv_prog_CC="cl"
907       break
908     fi
909   done
910   IFS="$ac_save_ifs"
911 fi
912 fi
913 CC="$ac_cv_prog_CC"
914 if test -n "$CC"; then
915   echo "$ac_t""$CC" 1>&6
916 else
917   echo "$ac_t""no" 1>&6
918 fi
919  ;;
920     esac
921   fi
922   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
923 fi
924
925 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
926 echo "configure:927: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
927
928 ac_ext=c
929 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
930 ac_cpp='$CPP $CPPFLAGS'
931 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
932 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
933 cross_compiling=$ac_cv_prog_cc_cross
934
935 cat > conftest.$ac_ext << EOF
936
937 #line 938 "configure"
938 #include "confdefs.h"
939
940 main(){return(0);}
941 EOF
942 if { (eval echo configure:943: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
943   ac_cv_prog_cc_works=yes
944   # If we can't run a trivial program, we are probably using a cross compiler.
945   if (./conftest; exit) 2>/dev/null; then
946     ac_cv_prog_cc_cross=no
947   else
948     ac_cv_prog_cc_cross=yes
949   fi
950 else
951   echo "configure: failed program was:" >&5
952   cat conftest.$ac_ext >&5
953   ac_cv_prog_cc_works=no
954 fi
955 rm -fr conftest*
956 ac_ext=c
957 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
958 ac_cpp='$CPP $CPPFLAGS'
959 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
960 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
961 cross_compiling=$ac_cv_prog_cc_cross
962
963 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
964 if test $ac_cv_prog_cc_works = no; then
965   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
966 fi
967 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
968 echo "configure:969: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
969 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
970 cross_compiling=$ac_cv_prog_cc_cross
971
972 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
973 echo "configure:974: checking whether we are using GNU C" >&5
974 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
975   echo $ac_n "(cached) $ac_c" 1>&6
976 else
977   cat > conftest.c <<EOF
978 #ifdef __GNUC__
979   yes;
980 #endif
981 EOF
982 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:983: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
983   ac_cv_prog_gcc=yes
984 else
985   ac_cv_prog_gcc=no
986 fi
987 fi
988
989 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
990
991 if test $ac_cv_prog_gcc = yes; then
992   GCC=yes
993 else
994   GCC=
995 fi
996
997 ac_test_CFLAGS="${CFLAGS+set}"
998 ac_save_CFLAGS="$CFLAGS"
999 CFLAGS=
1000 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1001 echo "configure:1002: checking whether ${CC-cc} accepts -g" >&5
1002 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1003   echo $ac_n "(cached) $ac_c" 1>&6
1004 else
1005   echo 'void f(){}' > conftest.c
1006 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1007   ac_cv_prog_cc_g=yes
1008 else
1009   ac_cv_prog_cc_g=no
1010 fi
1011 rm -f conftest*
1012
1013 fi
1014
1015 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1016 if test "$ac_test_CFLAGS" = set; then
1017   CFLAGS="$ac_save_CFLAGS"
1018 elif test $ac_cv_prog_cc_g = yes; then
1019   if test "$GCC" = yes; then
1020     CFLAGS="-g -O2"
1021   else
1022     CFLAGS="-g"
1023   fi
1024 else
1025   if test "$GCC" = yes; then
1026     CFLAGS="-O2"
1027   else
1028     CFLAGS=
1029   fi
1030 fi
1031
1032 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1033 echo "configure:1034: checking how to run the C preprocessor" >&5
1034 # On Suns, sometimes $CPP names a directory.
1035 if test -n "$CPP" && test -d "$CPP"; then
1036   CPP=
1037 fi
1038 if test -z "$CPP"; then
1039 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1040   echo $ac_n "(cached) $ac_c" 1>&6
1041 else
1042     # This must be in double quotes, not single quotes, because CPP may get
1043   # substituted into the Makefile and "${CC-cc}" will confuse make.
1044   CPP="${CC-cc} -E"
1045   # On the NeXT, cc -E runs the code through the compiler's parser,
1046   # not just through cpp.
1047   cat > conftest.$ac_ext <<EOF
1048 #line 1049 "configure"
1049 #include "confdefs.h"
1050 #include <assert.h>
1051 Syntax Error
1052 EOF
1053 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1054 { (eval echo configure:1055: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1055 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1056 if test -z "$ac_err"; then
1057   :
1058 else
1059   echo "$ac_err" >&5
1060   echo "configure: failed program was:" >&5
1061   cat conftest.$ac_ext >&5
1062   rm -rf conftest*
1063   CPP="${CC-cc} -E -traditional-cpp"
1064   cat > conftest.$ac_ext <<EOF
1065 #line 1066 "configure"
1066 #include "confdefs.h"
1067 #include <assert.h>
1068 Syntax Error
1069 EOF
1070 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1071 { (eval echo configure:1072: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1072 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1073 if test -z "$ac_err"; then
1074   :
1075 else
1076   echo "$ac_err" >&5
1077   echo "configure: failed program was:" >&5
1078   cat conftest.$ac_ext >&5
1079   rm -rf conftest*
1080   CPP="${CC-cc} -nologo -E"
1081   cat > conftest.$ac_ext <<EOF
1082 #line 1083 "configure"
1083 #include "confdefs.h"
1084 #include <assert.h>
1085 Syntax Error
1086 EOF
1087 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1088 { (eval echo configure:1089: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1089 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1090 if test -z "$ac_err"; then
1091   :
1092 else
1093   echo "$ac_err" >&5
1094   echo "configure: failed program was:" >&5
1095   cat conftest.$ac_ext >&5
1096   rm -rf conftest*
1097   CPP=/lib/cpp
1098 fi
1099 rm -f conftest*
1100 fi
1101 rm -f conftest*
1102 fi
1103 rm -f conftest*
1104   ac_cv_prog_CPP="$CPP"
1105 fi
1106   CPP="$ac_cv_prog_CPP"
1107 else
1108   ac_cv_prog_CPP="$CPP"
1109 fi
1110 echo "$ac_t""$CPP" 1>&6
1111
1112
1113 if test $host != $build; then
1114   ac_tool_prefix=${host_alias}-
1115 else
1116   ac_tool_prefix=
1117 fi
1118
1119 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
1120 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
1121 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1122 echo "configure:1123: checking for $ac_word" >&5
1123 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1124   echo $ac_n "(cached) $ac_c" 1>&6
1125 else
1126   if test -n "$RANLIB"; then
1127   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1128 else
1129   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1130   ac_dummy="$PATH"
1131   for ac_dir in $ac_dummy; do
1132     test -z "$ac_dir" && ac_dir=.
1133     if test -f $ac_dir/$ac_word; then
1134       ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
1135       break
1136     fi
1137   done
1138   IFS="$ac_save_ifs"
1139 fi
1140 fi
1141 RANLIB="$ac_cv_prog_RANLIB"
1142 if test -n "$RANLIB"; then
1143   echo "$ac_t""$RANLIB" 1>&6
1144 else
1145   echo "$ac_t""no" 1>&6
1146 fi
1147
1148
1149 if test -z "$ac_cv_prog_RANLIB"; then
1150 if test -n "$ac_tool_prefix"; then
1151   # Extract the first word of "ranlib", so it can be a program name with args.
1152 set dummy ranlib; ac_word=$2
1153 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1154 echo "configure:1155: checking for $ac_word" >&5
1155 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1156   echo $ac_n "(cached) $ac_c" 1>&6
1157 else
1158   if test -n "$RANLIB"; then
1159   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1160 else
1161   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1162   ac_dummy="$PATH"
1163   for ac_dir in $ac_dummy; do
1164     test -z "$ac_dir" && ac_dir=.
1165     if test -f $ac_dir/$ac_word; then
1166       ac_cv_prog_RANLIB="ranlib"
1167       break
1168     fi
1169   done
1170   IFS="$ac_save_ifs"
1171   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1172 fi
1173 fi
1174 RANLIB="$ac_cv_prog_RANLIB"
1175 if test -n "$RANLIB"; then
1176   echo "$ac_t""$RANLIB" 1>&6
1177 else
1178   echo "$ac_t""no" 1>&6
1179 fi
1180
1181 else
1182   RANLIB=":"
1183 fi
1184 fi
1185
1186 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
1187 set dummy ${ac_tool_prefix}strip; ac_word=$2
1188 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1189 echo "configure:1190: checking for $ac_word" >&5
1190 if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
1191   echo $ac_n "(cached) $ac_c" 1>&6
1192 else
1193   if test -n "$STRIP"; then
1194   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
1195 else
1196   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1197   ac_dummy="$PATH"
1198   for ac_dir in $ac_dummy; do
1199     test -z "$ac_dir" && ac_dir=.
1200     if test -f $ac_dir/$ac_word; then
1201       ac_cv_prog_STRIP="${ac_tool_prefix}strip"
1202       break
1203     fi
1204   done
1205   IFS="$ac_save_ifs"
1206 fi
1207 fi
1208 STRIP="$ac_cv_prog_STRIP"
1209 if test -n "$STRIP"; then
1210   echo "$ac_t""$STRIP" 1>&6
1211 else
1212   echo "$ac_t""no" 1>&6
1213 fi
1214
1215
1216 if test -z "$ac_cv_prog_STRIP"; then
1217 if test -n "$ac_tool_prefix"; then
1218   # Extract the first word of "strip", so it can be a program name with args.
1219 set dummy strip; ac_word=$2
1220 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1221 echo "configure:1222: checking for $ac_word" >&5
1222 if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
1223   echo $ac_n "(cached) $ac_c" 1>&6
1224 else
1225   if test -n "$STRIP"; then
1226   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
1227 else
1228   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1229   ac_dummy="$PATH"
1230   for ac_dir in $ac_dummy; do
1231     test -z "$ac_dir" && ac_dir=.
1232     if test -f $ac_dir/$ac_word; then
1233       ac_cv_prog_STRIP="strip"
1234       break
1235     fi
1236   done
1237   IFS="$ac_save_ifs"
1238   test -z "$ac_cv_prog_STRIP" && ac_cv_prog_STRIP=":"
1239 fi
1240 fi
1241 STRIP="$ac_cv_prog_STRIP"
1242 if test -n "$STRIP"; then
1243   echo "$ac_t""$STRIP" 1>&6
1244 else
1245   echo "$ac_t""no" 1>&6
1246 fi
1247
1248 else
1249   STRIP=":"
1250 fi
1251 fi
1252
1253
1254 # Extract the first word of "gmake", so it can be a program name with args.
1255 set dummy gmake; ac_word=$2
1256 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1257 echo "configure:1258: checking for $ac_word" >&5
1258 if eval "test \"`echo '$''{'ac_cv_path_GMAKE'+set}'`\" = set"; then
1259   echo $ac_n "(cached) $ac_c" 1>&6
1260 else
1261   case "$GMAKE" in
1262   /*)
1263   ac_cv_path_GMAKE="$GMAKE" # Let the user override the test with a path.
1264   ;;
1265   ?:/*)                  
1266   ac_cv_path_GMAKE="$GMAKE" # Let the user override the test with a dos path.
1267   ;;
1268   *)
1269   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1270   ac_dummy="$PATH"
1271   for ac_dir in $ac_dummy; do 
1272     test -z "$ac_dir" && ac_dir=.
1273     if test -f $ac_dir/$ac_word; then
1274       ac_cv_path_GMAKE="$ac_dir/$ac_word"
1275       break
1276     fi
1277   done
1278   IFS="$ac_save_ifs"
1279   test -z "$ac_cv_path_GMAKE" && ac_cv_path_GMAKE="no"
1280   ;;
1281 esac
1282 fi
1283 GMAKE="$ac_cv_path_GMAKE"
1284 if test -n "$GMAKE"; then
1285   echo "$ac_t""$GMAKE" 1>&6
1286 else
1287   echo "$ac_t""no" 1>&6
1288 fi
1289
1290 if test "x$GMAKE" = "xno"; then
1291   echo $ac_n "checking whether GNU make is installed""... $ac_c" 1>&6
1292 echo "configure:1293: checking whether GNU make is installed" >&5
1293 if eval "test \"`echo '$''{'ac_cv_gmake'+set}'`\" = set"; then
1294   echo $ac_n "(cached) $ac_c" 1>&6
1295 else
1296   if make --version | grep -q -i gnu; then
1297          ac_cv_gmake="yes"
1298        else
1299          echo "This software needs you to install GNU make to compile properly."
1300          echo "You can get it from http://www.gnu.org/."
1301          exit
1302        fi
1303 fi
1304
1305 echo "$ac_t""$ac_cv_gmake" 1>&6
1306   VLC_MAKE="make"
1307 else
1308   VLC_MAKE="gmake"
1309 fi
1310
1311 ALL_LINGUAS="de en_GB fr ja no ru nl"
1312
1313 cat >> confdefs.h <<EOF
1314 #define VLC_PACKAGE "$PACKAGE"
1315 EOF
1316
1317 cat >> confdefs.h <<EOF
1318 #define VLC_VERSION "$VERSION"
1319 EOF
1320
1321 # Extract the first word of "ranlib", so it can be a program name with args.
1322 set dummy ranlib; ac_word=$2
1323 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1324 echo "configure:1325: checking for $ac_word" >&5
1325 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1326   echo $ac_n "(cached) $ac_c" 1>&6
1327 else
1328   if test -n "$RANLIB"; then
1329   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1330 else
1331   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1332   ac_dummy="$PATH"
1333   for ac_dir in $ac_dummy; do
1334     test -z "$ac_dir" && ac_dir=.
1335     if test -f $ac_dir/$ac_word; then
1336       ac_cv_prog_RANLIB="ranlib"
1337       break
1338     fi
1339   done
1340   IFS="$ac_save_ifs"
1341   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1342 fi
1343 fi
1344 RANLIB="$ac_cv_prog_RANLIB"
1345 if test -n "$RANLIB"; then
1346   echo "$ac_t""$RANLIB" 1>&6
1347 else
1348   echo "$ac_t""no" 1>&6
1349 fi
1350
1351
1352         echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6
1353 echo "configure:1354: checking for strerror in -lcposix" >&5
1354 ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'`
1355 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1356   echo $ac_n "(cached) $ac_c" 1>&6
1357 else
1358   ac_save_LIBS="$LIBS"
1359 LIBS="-lcposix  $LIBS"
1360 cat > conftest.$ac_ext <<EOF
1361 #line 1362 "configure"
1362 #include "confdefs.h"
1363 /* Override any gcc2 internal prototype to avoid an error.  */
1364 /* We use char because int might match the return type of a gcc2
1365     builtin and then its argument prototype would still apply.  */
1366 char strerror();
1367
1368 int main() {
1369 strerror()
1370 ; return 0; }
1371 EOF
1372 if { (eval echo configure:1373: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1373   rm -rf conftest*
1374   eval "ac_cv_lib_$ac_lib_var=yes"
1375 else
1376   echo "configure: failed program was:" >&5
1377   cat conftest.$ac_ext >&5
1378   rm -rf conftest*
1379   eval "ac_cv_lib_$ac_lib_var=no"
1380 fi
1381 rm -f conftest*
1382 LIBS="$ac_save_LIBS"
1383
1384 fi
1385 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1386   echo "$ac_t""yes" 1>&6
1387   LIBS="$LIBS -lcposix"
1388 else
1389   echo "$ac_t""no" 1>&6
1390 fi
1391
1392   
1393
1394 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1395 echo "configure:1396: checking for ANSI C header files" >&5
1396 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1397   echo $ac_n "(cached) $ac_c" 1>&6
1398 else
1399   cat > conftest.$ac_ext <<EOF
1400 #line 1401 "configure"
1401 #include "confdefs.h"
1402 #include <stdlib.h>
1403 #include <stdarg.h>
1404 #include <string.h>
1405 #include <float.h>
1406 EOF
1407 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1408 { (eval echo configure:1409: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1409 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1410 if test -z "$ac_err"; then
1411   rm -rf conftest*
1412   ac_cv_header_stdc=yes
1413 else
1414   echo "$ac_err" >&5
1415   echo "configure: failed program was:" >&5
1416   cat conftest.$ac_ext >&5
1417   rm -rf conftest*
1418   ac_cv_header_stdc=no
1419 fi
1420 rm -f conftest*
1421
1422 if test $ac_cv_header_stdc = yes; then
1423   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1424 cat > conftest.$ac_ext <<EOF
1425 #line 1426 "configure"
1426 #include "confdefs.h"
1427 #include <string.h>
1428 EOF
1429 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1430   egrep "memchr" >/dev/null 2>&1; then
1431   :
1432 else
1433   rm -rf conftest*
1434   ac_cv_header_stdc=no
1435 fi
1436 rm -f conftest*
1437
1438 fi
1439
1440 if test $ac_cv_header_stdc = yes; then
1441   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1442 cat > conftest.$ac_ext <<EOF
1443 #line 1444 "configure"
1444 #include "confdefs.h"
1445 #include <stdlib.h>
1446 EOF
1447 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1448   egrep "free" >/dev/null 2>&1; then
1449   :
1450 else
1451   rm -rf conftest*
1452   ac_cv_header_stdc=no
1453 fi
1454 rm -f conftest*
1455
1456 fi
1457
1458 if test $ac_cv_header_stdc = yes; then
1459   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1460 if test "$cross_compiling" = yes; then
1461   :
1462 else
1463   cat > conftest.$ac_ext <<EOF
1464 #line 1465 "configure"
1465 #include "confdefs.h"
1466 #include <ctype.h>
1467 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1468 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1469 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1470 int main () { int i; for (i = 0; i < 256; i++)
1471 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1472 exit (0); }
1473
1474 EOF
1475 if { (eval echo configure:1476: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1476 then
1477   :
1478 else
1479   echo "configure: failed program was:" >&5
1480   cat conftest.$ac_ext >&5
1481   rm -fr conftest*
1482   ac_cv_header_stdc=no
1483 fi
1484 rm -fr conftest*
1485 fi
1486
1487 fi
1488 fi
1489
1490 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1491 if test $ac_cv_header_stdc = yes; then
1492   cat >> confdefs.h <<\EOF
1493 #define STDC_HEADERS 1
1494 EOF
1495
1496 fi
1497
1498 echo $ac_n "checking for working const""... $ac_c" 1>&6
1499 echo "configure:1500: checking for working const" >&5
1500 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
1501   echo $ac_n "(cached) $ac_c" 1>&6
1502 else
1503   cat > conftest.$ac_ext <<EOF
1504 #line 1505 "configure"
1505 #include "confdefs.h"
1506
1507 int main() {
1508
1509 /* Ultrix mips cc rejects this.  */
1510 typedef int charset[2]; const charset x;
1511 /* SunOS 4.1.1 cc rejects this.  */
1512 char const *const *ccp;
1513 char **p;
1514 /* NEC SVR4.0.2 mips cc rejects this.  */
1515 struct point {int x, y;};
1516 static struct point const zero = {0,0};
1517 /* AIX XL C 1.02.0.0 rejects this.
1518    It does not let you subtract one const X* pointer from another in an arm
1519    of an if-expression whose if-part is not a constant expression */
1520 const char *g = "string";
1521 ccp = &g + (g ? g-g : 0);
1522 /* HPUX 7.0 cc rejects these. */
1523 ++ccp;
1524 p = (char**) ccp;
1525 ccp = (char const *const *) p;
1526 { /* SCO 3.2v4 cc rejects this.  */
1527   char *t;
1528   char const *s = 0 ? (char *) 0 : (char const *) 0;
1529
1530   *t++ = 0;
1531 }
1532 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
1533   int x[] = {25, 17};
1534   const int *foo = &x[0];
1535   ++foo;
1536 }
1537 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
1538   typedef const int *iptr;
1539   iptr p = 0;
1540   ++p;
1541 }
1542 { /* AIX XL C 1.02.0.0 rejects this saying
1543      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
1544   struct s { int j; const int *ap[3]; };
1545   struct s *b; b->j = 5;
1546 }
1547 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
1548   const int foo = 10;
1549 }
1550
1551 ; return 0; }
1552 EOF
1553 if { (eval echo configure:1554: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1554   rm -rf conftest*
1555   ac_cv_c_const=yes
1556 else
1557   echo "configure: failed program was:" >&5
1558   cat conftest.$ac_ext >&5
1559   rm -rf conftest*
1560   ac_cv_c_const=no
1561 fi
1562 rm -f conftest*
1563 fi
1564
1565 echo "$ac_t""$ac_cv_c_const" 1>&6
1566 if test $ac_cv_c_const = no; then
1567   cat >> confdefs.h <<\EOF
1568 #define const 
1569 EOF
1570
1571 fi
1572
1573 echo $ac_n "checking for inline""... $ac_c" 1>&6
1574 echo "configure:1575: checking for inline" >&5
1575 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
1576   echo $ac_n "(cached) $ac_c" 1>&6
1577 else
1578   ac_cv_c_inline=no
1579 for ac_kw in inline __inline__ __inline; do
1580   cat > conftest.$ac_ext <<EOF
1581 #line 1582 "configure"
1582 #include "confdefs.h"
1583
1584 int main() {
1585 } $ac_kw foo() {
1586 ; return 0; }
1587 EOF
1588 if { (eval echo configure:1589: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1589   rm -rf conftest*
1590   ac_cv_c_inline=$ac_kw; break
1591 else
1592   echo "configure: failed program was:" >&5
1593   cat conftest.$ac_ext >&5
1594 fi
1595 rm -f conftest*
1596 done
1597
1598 fi
1599
1600 echo "$ac_t""$ac_cv_c_inline" 1>&6
1601 case "$ac_cv_c_inline" in
1602   inline | yes) ;;
1603   no) cat >> confdefs.h <<\EOF
1604 #define inline 
1605 EOF
1606  ;;
1607   *)  cat >> confdefs.h <<EOF
1608 #define inline $ac_cv_c_inline
1609 EOF
1610  ;;
1611 esac
1612
1613 echo $ac_n "checking for off_t""... $ac_c" 1>&6
1614 echo "configure:1615: checking for off_t" >&5
1615 if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
1616   echo $ac_n "(cached) $ac_c" 1>&6
1617 else
1618   cat > conftest.$ac_ext <<EOF
1619 #line 1620 "configure"
1620 #include "confdefs.h"
1621 #include <sys/types.h>
1622 #if STDC_HEADERS
1623 #include <stdlib.h>
1624 #include <stddef.h>
1625 #endif
1626 EOF
1627 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1628   egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1629   rm -rf conftest*
1630   ac_cv_type_off_t=yes
1631 else
1632   rm -rf conftest*
1633   ac_cv_type_off_t=no
1634 fi
1635 rm -f conftest*
1636
1637 fi
1638 echo "$ac_t""$ac_cv_type_off_t" 1>&6
1639 if test $ac_cv_type_off_t = no; then
1640   cat >> confdefs.h <<\EOF
1641 #define off_t long
1642 EOF
1643
1644 fi
1645
1646 echo $ac_n "checking for size_t""... $ac_c" 1>&6
1647 echo "configure:1648: checking for size_t" >&5
1648 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
1649   echo $ac_n "(cached) $ac_c" 1>&6
1650 else
1651   cat > conftest.$ac_ext <<EOF
1652 #line 1653 "configure"
1653 #include "confdefs.h"
1654 #include <sys/types.h>
1655 #if STDC_HEADERS
1656 #include <stdlib.h>
1657 #include <stddef.h>
1658 #endif
1659 EOF
1660 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1661   egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1662   rm -rf conftest*
1663   ac_cv_type_size_t=yes
1664 else
1665   rm -rf conftest*
1666   ac_cv_type_size_t=no
1667 fi
1668 rm -f conftest*
1669
1670 fi
1671 echo "$ac_t""$ac_cv_type_size_t" 1>&6
1672 if test $ac_cv_type_size_t = no; then
1673   cat >> confdefs.h <<\EOF
1674 #define size_t unsigned
1675 EOF
1676
1677 fi
1678
1679 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
1680 # for constant arguments.  Useless!
1681 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
1682 echo "configure:1683: checking for working alloca.h" >&5
1683 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
1684   echo $ac_n "(cached) $ac_c" 1>&6
1685 else
1686   cat > conftest.$ac_ext <<EOF
1687 #line 1688 "configure"
1688 #include "confdefs.h"
1689 #include <alloca.h>
1690 int main() {
1691 char *p = alloca(2 * sizeof(int));
1692 ; return 0; }
1693 EOF
1694 if { (eval echo configure:1695: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1695   rm -rf conftest*
1696   ac_cv_header_alloca_h=yes
1697 else
1698   echo "configure: failed program was:" >&5
1699   cat conftest.$ac_ext >&5
1700   rm -rf conftest*
1701   ac_cv_header_alloca_h=no
1702 fi
1703 rm -f conftest*
1704 fi
1705
1706 echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
1707 if test $ac_cv_header_alloca_h = yes; then
1708   cat >> confdefs.h <<\EOF
1709 #define HAVE_ALLOCA_H 1
1710 EOF
1711
1712 fi
1713
1714 echo $ac_n "checking for alloca""... $ac_c" 1>&6
1715 echo "configure:1716: checking for alloca" >&5
1716 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
1717   echo $ac_n "(cached) $ac_c" 1>&6
1718 else
1719   cat > conftest.$ac_ext <<EOF
1720 #line 1721 "configure"
1721 #include "confdefs.h"
1722
1723 #ifdef __GNUC__
1724 # define alloca __builtin_alloca
1725 #else
1726 # ifdef _MSC_VER
1727 #  include <malloc.h>
1728 #  define alloca _alloca
1729 # else
1730 #  if HAVE_ALLOCA_H
1731 #   include <alloca.h>
1732 #  else
1733 #   ifdef _AIX
1734  #pragma alloca
1735 #   else
1736 #    ifndef alloca /* predefined by HP cc +Olibcalls */
1737 char *alloca ();
1738 #    endif
1739 #   endif
1740 #  endif
1741 # endif
1742 #endif
1743
1744 int main() {
1745 char *p = (char *) alloca(1);
1746 ; return 0; }
1747 EOF
1748 if { (eval echo configure:1749: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1749   rm -rf conftest*
1750   ac_cv_func_alloca_works=yes
1751 else
1752   echo "configure: failed program was:" >&5
1753   cat conftest.$ac_ext >&5
1754   rm -rf conftest*
1755   ac_cv_func_alloca_works=no
1756 fi
1757 rm -f conftest*
1758 fi
1759
1760 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
1761 if test $ac_cv_func_alloca_works = yes; then
1762   cat >> confdefs.h <<\EOF
1763 #define HAVE_ALLOCA 1
1764 EOF
1765
1766 fi
1767
1768 if test $ac_cv_func_alloca_works = no; then
1769   # The SVR3 libPW and SVR4 libucb both contain incompatible functions
1770   # that cause trouble.  Some versions do not even contain alloca or
1771   # contain a buggy version.  If you still want to use their alloca,
1772   # use ar to extract alloca.o from them instead of compiling alloca.c.
1773   ALLOCA=alloca.${ac_objext}
1774   cat >> confdefs.h <<\EOF
1775 #define C_ALLOCA 1
1776 EOF
1777
1778
1779 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
1780 echo "configure:1781: checking whether alloca needs Cray hooks" >&5
1781 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
1782   echo $ac_n "(cached) $ac_c" 1>&6
1783 else
1784   cat > conftest.$ac_ext <<EOF
1785 #line 1786 "configure"
1786 #include "confdefs.h"
1787 #if defined(CRAY) && ! defined(CRAY2)
1788 webecray
1789 #else
1790 wenotbecray
1791 #endif
1792
1793 EOF
1794 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1795   egrep "webecray" >/dev/null 2>&1; then
1796   rm -rf conftest*
1797   ac_cv_os_cray=yes
1798 else
1799   rm -rf conftest*
1800   ac_cv_os_cray=no
1801 fi
1802 rm -f conftest*
1803
1804 fi
1805
1806 echo "$ac_t""$ac_cv_os_cray" 1>&6
1807 if test $ac_cv_os_cray = yes; then
1808 for ac_func in _getb67 GETB67 getb67; do
1809   echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1810 echo "configure:1811: checking for $ac_func" >&5
1811 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1812   echo $ac_n "(cached) $ac_c" 1>&6
1813 else
1814   cat > conftest.$ac_ext <<EOF
1815 #line 1816 "configure"
1816 #include "confdefs.h"
1817 /* System header to define __stub macros and hopefully few prototypes,
1818     which can conflict with char $ac_func(); below.  */
1819 #include <assert.h>
1820 /* Override any gcc2 internal prototype to avoid an error.  */
1821 /* We use char because int might match the return type of a gcc2
1822     builtin and then its argument prototype would still apply.  */
1823 char $ac_func();
1824
1825 int main() {
1826
1827 /* The GNU C library defines this for functions which it implements
1828     to always fail with ENOSYS.  Some functions are actually named
1829     something starting with __ and the normal name is an alias.  */
1830 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1831 choke me
1832 #else
1833 $ac_func();
1834 #endif
1835
1836 ; return 0; }
1837 EOF
1838 if { (eval echo configure:1839: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1839   rm -rf conftest*
1840   eval "ac_cv_func_$ac_func=yes"
1841 else
1842   echo "configure: failed program was:" >&5
1843   cat conftest.$ac_ext >&5
1844   rm -rf conftest*
1845   eval "ac_cv_func_$ac_func=no"
1846 fi
1847 rm -f conftest*
1848 fi
1849
1850 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1851   echo "$ac_t""yes" 1>&6
1852   cat >> confdefs.h <<EOF
1853 #define CRAY_STACKSEG_END $ac_func
1854 EOF
1855
1856   break
1857 else
1858   echo "$ac_t""no" 1>&6
1859 fi
1860
1861 done
1862 fi
1863
1864 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
1865 echo "configure:1866: checking stack direction for C alloca" >&5
1866 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
1867   echo $ac_n "(cached) $ac_c" 1>&6
1868 else
1869   if test "$cross_compiling" = yes; then
1870   ac_cv_c_stack_direction=0
1871 else
1872   cat > conftest.$ac_ext <<EOF
1873 #line 1874 "configure"
1874 #include "confdefs.h"
1875 find_stack_direction ()
1876 {
1877   static char *addr = 0;
1878   auto char dummy;
1879   if (addr == 0)
1880     {
1881       addr = &dummy;
1882       return find_stack_direction ();
1883     }
1884   else
1885     return (&dummy > addr) ? 1 : -1;
1886 }
1887 main ()
1888 {
1889   exit (find_stack_direction() < 0);
1890 }
1891 EOF
1892 if { (eval echo configure:1893: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1893 then
1894   ac_cv_c_stack_direction=1
1895 else
1896   echo "configure: failed program was:" >&5
1897   cat conftest.$ac_ext >&5
1898   rm -fr conftest*
1899   ac_cv_c_stack_direction=-1
1900 fi
1901 rm -fr conftest*
1902 fi
1903
1904 fi
1905
1906 echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
1907 cat >> confdefs.h <<EOF
1908 #define STACK_DIRECTION $ac_cv_c_stack_direction
1909 EOF
1910
1911 fi
1912
1913 for ac_hdr in unistd.h
1914 do
1915 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1916 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1917 echo "configure:1918: checking for $ac_hdr" >&5
1918 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1919   echo $ac_n "(cached) $ac_c" 1>&6
1920 else
1921   cat > conftest.$ac_ext <<EOF
1922 #line 1923 "configure"
1923 #include "confdefs.h"
1924 #include <$ac_hdr>
1925 EOF
1926 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1927 { (eval echo configure:1928: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1928 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1929 if test -z "$ac_err"; then
1930   rm -rf conftest*
1931   eval "ac_cv_header_$ac_safe=yes"
1932 else
1933   echo "$ac_err" >&5
1934   echo "configure: failed program was:" >&5
1935   cat conftest.$ac_ext >&5
1936   rm -rf conftest*
1937   eval "ac_cv_header_$ac_safe=no"
1938 fi
1939 rm -f conftest*
1940 fi
1941 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1942   echo "$ac_t""yes" 1>&6
1943     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1944   cat >> confdefs.h <<EOF
1945 #define $ac_tr_hdr 1
1946 EOF
1947  
1948 else
1949   echo "$ac_t""no" 1>&6
1950 fi
1951 done
1952
1953 for ac_func in getpagesize
1954 do
1955 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1956 echo "configure:1957: checking for $ac_func" >&5
1957 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1958   echo $ac_n "(cached) $ac_c" 1>&6
1959 else
1960   cat > conftest.$ac_ext <<EOF
1961 #line 1962 "configure"
1962 #include "confdefs.h"
1963 /* System header to define __stub macros and hopefully few prototypes,
1964     which can conflict with char $ac_func(); below.  */
1965 #include <assert.h>
1966 /* Override any gcc2 internal prototype to avoid an error.  */
1967 /* We use char because int might match the return type of a gcc2
1968     builtin and then its argument prototype would still apply.  */
1969 char $ac_func();
1970
1971 int main() {
1972
1973 /* The GNU C library defines this for functions which it implements
1974     to always fail with ENOSYS.  Some functions are actually named
1975     something starting with __ and the normal name is an alias.  */
1976 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1977 choke me
1978 #else
1979 $ac_func();
1980 #endif
1981
1982 ; return 0; }
1983 EOF
1984 if { (eval echo configure:1985: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1985   rm -rf conftest*
1986   eval "ac_cv_func_$ac_func=yes"
1987 else
1988   echo "configure: failed program was:" >&5
1989   cat conftest.$ac_ext >&5
1990   rm -rf conftest*
1991   eval "ac_cv_func_$ac_func=no"
1992 fi
1993 rm -f conftest*
1994 fi
1995
1996 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1997   echo "$ac_t""yes" 1>&6
1998     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1999   cat >> confdefs.h <<EOF
2000 #define $ac_tr_func 1
2001 EOF
2002  
2003 else
2004   echo "$ac_t""no" 1>&6
2005 fi
2006 done
2007
2008 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
2009 echo "configure:2010: checking for working mmap" >&5
2010 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
2011   echo $ac_n "(cached) $ac_c" 1>&6
2012 else
2013   if test "$cross_compiling" = yes; then
2014   ac_cv_func_mmap_fixed_mapped=no
2015 else
2016   cat > conftest.$ac_ext <<EOF
2017 #line 2018 "configure"
2018 #include "confdefs.h"
2019
2020 /* Thanks to Mike Haertel and Jim Avera for this test.
2021    Here is a matrix of mmap possibilities:
2022         mmap private not fixed
2023         mmap private fixed at somewhere currently unmapped
2024         mmap private fixed at somewhere already mapped
2025         mmap shared not fixed
2026         mmap shared fixed at somewhere currently unmapped
2027         mmap shared fixed at somewhere already mapped
2028    For private mappings, we should verify that changes cannot be read()
2029    back from the file, nor mmap's back from the file at a different
2030    address.  (There have been systems where private was not correctly
2031    implemented like the infamous i386 svr4.0, and systems where the
2032    VM page cache was not coherent with the filesystem buffer cache
2033    like early versions of FreeBSD and possibly contemporary NetBSD.)
2034    For shared mappings, we should conversely verify that changes get
2035    propogated back to all the places they're supposed to be.
2036
2037    Grep wants private fixed already mapped.
2038    The main things grep needs to know about mmap are:
2039    * does it exist and is it safe to write into the mmap'd area
2040    * how to use it (BSD variants)  */
2041 #include <sys/types.h>
2042 #include <fcntl.h>
2043 #include <sys/mman.h>
2044
2045 /* This mess was copied from the GNU getpagesize.h.  */
2046 #ifndef HAVE_GETPAGESIZE
2047 # ifdef HAVE_UNISTD_H
2048 #  include <unistd.h>
2049 # endif
2050
2051 /* Assume that all systems that can run configure have sys/param.h.  */
2052 # ifndef HAVE_SYS_PARAM_H
2053 #  define HAVE_SYS_PARAM_H 1
2054 # endif
2055
2056 # ifdef _SC_PAGESIZE
2057 #  define getpagesize() sysconf(_SC_PAGESIZE)
2058 # else /* no _SC_PAGESIZE */
2059 #  ifdef HAVE_SYS_PARAM_H
2060 #   include <sys/param.h>
2061 #   ifdef EXEC_PAGESIZE
2062 #    define getpagesize() EXEC_PAGESIZE
2063 #   else /* no EXEC_PAGESIZE */
2064 #    ifdef NBPG
2065 #     define getpagesize() NBPG * CLSIZE
2066 #     ifndef CLSIZE
2067 #      define CLSIZE 1
2068 #     endif /* no CLSIZE */
2069 #    else /* no NBPG */
2070 #     ifdef NBPC
2071 #      define getpagesize() NBPC
2072 #     else /* no NBPC */
2073 #      ifdef PAGESIZE
2074 #       define getpagesize() PAGESIZE
2075 #      endif /* PAGESIZE */
2076 #     endif /* no NBPC */
2077 #    endif /* no NBPG */
2078 #   endif /* no EXEC_PAGESIZE */
2079 #  else /* no HAVE_SYS_PARAM_H */
2080 #   define getpagesize() 8192   /* punt totally */
2081 #  endif /* no HAVE_SYS_PARAM_H */
2082 # endif /* no _SC_PAGESIZE */
2083
2084 #endif /* no HAVE_GETPAGESIZE */
2085
2086 #ifdef __cplusplus
2087 extern "C" { void *malloc(unsigned); }
2088 #else
2089 char *malloc();
2090 #endif
2091
2092 int
2093 main()
2094 {
2095         char *data, *data2, *data3;
2096         int i, pagesize;
2097         int fd;
2098
2099         pagesize = getpagesize();
2100
2101         /*
2102          * First, make a file with some known garbage in it.
2103          */
2104         data = malloc(pagesize);
2105         if (!data)
2106                 exit(1);
2107         for (i = 0; i < pagesize; ++i)
2108                 *(data + i) = rand();
2109         umask(0);
2110         fd = creat("conftestmmap", 0600);
2111         if (fd < 0)
2112                 exit(1);
2113         if (write(fd, data, pagesize) != pagesize)
2114                 exit(1);
2115         close(fd);
2116
2117         /*
2118          * Next, try to mmap the file at a fixed address which
2119          * already has something else allocated at it.  If we can,
2120          * also make sure that we see the same garbage.
2121          */
2122         fd = open("conftestmmap", O_RDWR);
2123         if (fd < 0)
2124                 exit(1);
2125         data2 = malloc(2 * pagesize);
2126         if (!data2)
2127                 exit(1);
2128         data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
2129         if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
2130             MAP_PRIVATE | MAP_FIXED, fd, 0L))
2131                 exit(1);
2132         for (i = 0; i < pagesize; ++i)
2133                 if (*(data + i) != *(data2 + i))
2134                         exit(1);
2135
2136         /*
2137          * Finally, make sure that changes to the mapped area
2138          * do not percolate back to the file as seen by read().
2139          * (This is a bug on some variants of i386 svr4.0.)
2140          */
2141         for (i = 0; i < pagesize; ++i)
2142                 *(data2 + i) = *(data2 + i) + 1;
2143         data3 = malloc(pagesize);
2144         if (!data3)
2145                 exit(1);
2146         if (read(fd, data3, pagesize) != pagesize)
2147                 exit(1);
2148         for (i = 0; i < pagesize; ++i)
2149                 if (*(data + i) != *(data3 + i))
2150                         exit(1);
2151         close(fd);
2152         unlink("conftestmmap");
2153         exit(0);
2154 }
2155
2156 EOF
2157 if { (eval echo configure:2158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2158 then
2159   ac_cv_func_mmap_fixed_mapped=yes
2160 else
2161   echo "configure: failed program was:" >&5
2162   cat conftest.$ac_ext >&5
2163   rm -fr conftest*
2164   ac_cv_func_mmap_fixed_mapped=no
2165 fi
2166 rm -fr conftest*
2167 fi
2168
2169 fi
2170
2171 echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
2172 if test $ac_cv_func_mmap_fixed_mapped = yes; then
2173   cat >> confdefs.h <<\EOF
2174 #define HAVE_MMAP 1
2175 EOF
2176
2177 fi
2178
2179
2180     echo $ac_n "checking whether we are using the GNU C Library 2.1 or newer""... $ac_c" 1>&6
2181 echo "configure:2182: checking whether we are using the GNU C Library 2.1 or newer" >&5
2182 if eval "test \"`echo '$''{'ac_cv_gnu_library_2_1'+set}'`\" = set"; then
2183   echo $ac_n "(cached) $ac_c" 1>&6
2184 else
2185   cat > conftest.$ac_ext <<EOF
2186 #line 2187 "configure"
2187 #include "confdefs.h"
2188
2189 #include <features.h>
2190 #ifdef __GNU_LIBRARY__
2191  #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
2192   Lucky GNU user
2193  #endif
2194 #endif
2195         
2196 EOF
2197 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2198   egrep "Lucky GNU user" >/dev/null 2>&1; then
2199   rm -rf conftest*
2200   ac_cv_gnu_library_2_1=yes
2201 else
2202   rm -rf conftest*
2203   ac_cv_gnu_library_2_1=no
2204 fi
2205 rm -f conftest*
2206
2207       
2208     
2209 fi
2210
2211 echo "$ac_t""$ac_cv_gnu_library_2_1" 1>&6
2212     
2213     GLIBC21="$ac_cv_gnu_library_2_1"
2214   
2215
2216                                     
2217    for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h stddef.h \
2218 stdlib.h string.h unistd.h sys/param.h
2219 do
2220 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2221 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2222 echo "configure:2223: checking for $ac_hdr" >&5
2223 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2224   echo $ac_n "(cached) $ac_c" 1>&6
2225 else
2226   cat > conftest.$ac_ext <<EOF
2227 #line 2228 "configure"
2228 #include "confdefs.h"
2229 #include <$ac_hdr>
2230 EOF
2231 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2232 { (eval echo configure:2233: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2233 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2234 if test -z "$ac_err"; then
2235   rm -rf conftest*
2236   eval "ac_cv_header_$ac_safe=yes"
2237 else
2238   echo "$ac_err" >&5
2239   echo "configure: failed program was:" >&5
2240   cat conftest.$ac_ext >&5
2241   rm -rf conftest*
2242   eval "ac_cv_header_$ac_safe=no"
2243 fi
2244 rm -f conftest*
2245 fi
2246 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2247   echo "$ac_t""yes" 1>&6
2248     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2249   cat >> confdefs.h <<EOF
2250 #define $ac_tr_hdr 1
2251 EOF
2252  
2253 else
2254   echo "$ac_t""no" 1>&6
2255 fi
2256 done
2257
2258    for ac_func in feof_unlocked fgets_unlocked getcwd getegid geteuid \
2259 getgid getuid mempcpy munmap putenv setenv setlocale stpcpy strchr strcasecmp \
2260 strdup strtoul tsearch __argz_count __argz_stringify __argz_next
2261 do
2262 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2263 echo "configure:2264: checking for $ac_func" >&5
2264 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2265   echo $ac_n "(cached) $ac_c" 1>&6
2266 else
2267   cat > conftest.$ac_ext <<EOF
2268 #line 2269 "configure"
2269 #include "confdefs.h"
2270 /* System header to define __stub macros and hopefully few prototypes,
2271     which can conflict with char $ac_func(); below.  */
2272 #include <assert.h>
2273 /* Override any gcc2 internal prototype to avoid an error.  */
2274 /* We use char because int might match the return type of a gcc2
2275     builtin and then its argument prototype would still apply.  */
2276 char $ac_func();
2277
2278 int main() {
2279
2280 /* The GNU C library defines this for functions which it implements
2281     to always fail with ENOSYS.  Some functions are actually named
2282     something starting with __ and the normal name is an alias.  */
2283 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2284 choke me
2285 #else
2286 $ac_func();
2287 #endif
2288
2289 ; return 0; }
2290 EOF
2291 if { (eval echo configure:2292: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2292   rm -rf conftest*
2293   eval "ac_cv_func_$ac_func=yes"
2294 else
2295   echo "configure: failed program was:" >&5
2296   cat conftest.$ac_ext >&5
2297   rm -rf conftest*
2298   eval "ac_cv_func_$ac_func=no"
2299 fi
2300 rm -f conftest*
2301 fi
2302
2303 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2304   echo "$ac_t""yes" 1>&6
2305     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2306   cat >> confdefs.h <<EOF
2307 #define $ac_tr_func 1
2308 EOF
2309  
2310 else
2311   echo "$ac_t""no" 1>&6
2312 fi
2313 done
2314
2315
2316    
2317     
2318   # Check whether --with-libiconv-prefix or --without-libiconv-prefix was given.
2319 if test "${with_libiconv_prefix+set}" = set; then
2320   withval="$with_libiconv_prefix"
2321   
2322     for dir in `echo "$withval" | tr : ' '`; do
2323       if test -d $dir/include; then CPPFLAGS="$CPPFLAGS -I$dir/include"; fi
2324       if test -d $dir/lib; then LDFLAGS="$LDFLAGS -L$dir/lib"; fi
2325     done
2326    
2327 fi
2328
2329
2330   echo $ac_n "checking for iconv""... $ac_c" 1>&6
2331 echo "configure:2332: checking for iconv" >&5
2332 if eval "test \"`echo '$''{'am_cv_func_iconv'+set}'`\" = set"; then
2333   echo $ac_n "(cached) $ac_c" 1>&6
2334 else
2335   
2336     am_cv_func_iconv="no, consider installing GNU libiconv"
2337     am_cv_lib_iconv=no
2338     cat > conftest.$ac_ext <<EOF
2339 #line 2340 "configure"
2340 #include "confdefs.h"
2341 #include <stdlib.h>
2342 #include <iconv.h>
2343 int main() {
2344 iconv_t cd = iconv_open("","");
2345        iconv(cd,NULL,NULL,NULL,NULL);
2346        iconv_close(cd);
2347 ; return 0; }
2348 EOF
2349 if { (eval echo configure:2350: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2350   rm -rf conftest*
2351   am_cv_func_iconv=yes
2352 else
2353   echo "configure: failed program was:" >&5
2354   cat conftest.$ac_ext >&5
2355 fi
2356 rm -f conftest*
2357     if test "$am_cv_func_iconv" != yes; then
2358       am_save_LIBS="$LIBS"
2359       LIBS="$LIBS -liconv"
2360       cat > conftest.$ac_ext <<EOF
2361 #line 2362 "configure"
2362 #include "confdefs.h"
2363 #include <stdlib.h>
2364 #include <iconv.h>
2365 int main() {
2366 iconv_t cd = iconv_open("","");
2367          iconv(cd,NULL,NULL,NULL,NULL);
2368          iconv_close(cd);
2369 ; return 0; }
2370 EOF
2371 if { (eval echo configure:2372: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2372   rm -rf conftest*
2373   am_cv_lib_iconv=yes
2374         am_cv_func_iconv=yes
2375 else
2376   echo "configure: failed program was:" >&5
2377   cat conftest.$ac_ext >&5
2378 fi
2379 rm -f conftest*
2380       LIBS="$am_save_LIBS"
2381     fi
2382   
2383 fi
2384
2385 echo "$ac_t""$am_cv_func_iconv" 1>&6
2386   if test "$am_cv_func_iconv" = yes; then
2387     cat >> confdefs.h <<\EOF
2388 #define HAVE_ICONV 1
2389 EOF
2390
2391     echo $ac_n "checking for iconv declaration""... $ac_c" 1>&6
2392 echo "configure:2393: checking for iconv declaration" >&5
2393     if eval "test \"`echo '$''{'am_cv_proto_iconv'+set}'`\" = set"; then
2394   echo $ac_n "(cached) $ac_c" 1>&6
2395 else
2396   
2397       cat > conftest.$ac_ext <<EOF
2398 #line 2399 "configure"
2399 #include "confdefs.h"
2400
2401 #include <stdlib.h>
2402 #include <iconv.h>
2403 extern
2404 #ifdef __cplusplus
2405 "C"
2406 #endif
2407 #if defined(__STDC__) || defined(__cplusplus)
2408 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
2409 #else
2410 size_t iconv();
2411 #endif
2412
2413 int main() {
2414
2415 ; return 0; }
2416 EOF
2417 if { (eval echo configure:2418: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2418   rm -rf conftest*
2419   am_cv_proto_iconv_arg1=""
2420 else
2421   echo "configure: failed program was:" >&5
2422   cat conftest.$ac_ext >&5
2423   rm -rf conftest*
2424   am_cv_proto_iconv_arg1="const"
2425 fi
2426 rm -f conftest*
2427       am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"
2428 fi
2429
2430     am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
2431     echo "$ac_t""${ac_t:-
2432          }$am_cv_proto_iconv" 1>&6
2433     cat >> confdefs.h <<EOF
2434 #define ICONV_CONST $am_cv_proto_iconv_arg1
2435 EOF
2436
2437   fi
2438   LIBICONV=
2439   if test "$am_cv_lib_iconv" = yes; then
2440     LIBICONV="-liconv"
2441   fi
2442   
2443
2444    
2445   echo $ac_n "checking for nl_langinfo and CODESET""... $ac_c" 1>&6
2446 echo "configure:2447: checking for nl_langinfo and CODESET" >&5
2447 if eval "test \"`echo '$''{'am_cv_langinfo_codeset'+set}'`\" = set"; then
2448   echo $ac_n "(cached) $ac_c" 1>&6
2449 else
2450   cat > conftest.$ac_ext <<EOF
2451 #line 2452 "configure"
2452 #include "confdefs.h"
2453 #include <langinfo.h>
2454 int main() {
2455 char* cs = nl_langinfo(CODESET);
2456 ; return 0; }
2457 EOF
2458 if { (eval echo configure:2459: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2459   rm -rf conftest*
2460   am_cv_langinfo_codeset=yes
2461 else
2462   echo "configure: failed program was:" >&5
2463   cat conftest.$ac_ext >&5
2464   rm -rf conftest*
2465   am_cv_langinfo_codeset=no
2466 fi
2467 rm -f conftest*
2468     
2469 fi
2470
2471 echo "$ac_t""$am_cv_langinfo_codeset" 1>&6
2472   if test $am_cv_langinfo_codeset = yes; then
2473     cat >> confdefs.h <<\EOF
2474 #define HAVE_LANGINFO_CODESET 1
2475 EOF
2476
2477   fi
2478
2479    if test $ac_cv_header_locale_h = yes; then
2480     echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
2481 echo "configure:2482: checking for LC_MESSAGES" >&5
2482 if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
2483   echo $ac_n "(cached) $ac_c" 1>&6
2484 else
2485   cat > conftest.$ac_ext <<EOF
2486 #line 2487 "configure"
2487 #include "confdefs.h"
2488 #include <locale.h>
2489 int main() {
2490 return LC_MESSAGES
2491 ; return 0; }
2492 EOF
2493 if { (eval echo configure:2494: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2494   rm -rf conftest*
2495   am_cv_val_LC_MESSAGES=yes
2496 else
2497   echo "configure: failed program was:" >&5
2498   cat conftest.$ac_ext >&5
2499   rm -rf conftest*
2500   am_cv_val_LC_MESSAGES=no
2501 fi
2502 rm -f conftest*
2503 fi
2504
2505 echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
2506     if test $am_cv_val_LC_MESSAGES = yes; then
2507       cat >> confdefs.h <<\EOF
2508 #define HAVE_LC_MESSAGES 1
2509 EOF
2510
2511     fi
2512   fi
2513    echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
2514 echo "configure:2515: checking whether NLS is requested" >&5
2515         # Check whether --enable-nls or --disable-nls was given.
2516 if test "${enable_nls+set}" = set; then
2517   enableval="$enable_nls"
2518   USE_NLS=$enableval
2519 else
2520   USE_NLS=yes
2521 fi
2522
2523     echo "$ac_t""$USE_NLS" 1>&6
2524     
2525
2526     BUILD_INCLUDED_LIBINTL=no
2527     USE_INCLUDED_LIBINTL=no
2528     INTLLIBS=
2529
2530         if test "$USE_NLS" = "yes"; then
2531       cat >> confdefs.h <<\EOF
2532 #define ENABLE_NLS 1
2533 EOF
2534
2535       echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
2536 echo "configure:2537: checking whether included gettext is requested" >&5
2537       # Check whether --with-included-gettext or --without-included-gettext was given.
2538 if test "${with_included_gettext+set}" = set; then
2539   withval="$with_included_gettext"
2540   nls_cv_force_use_gnu_gettext=$withval
2541 else
2542   nls_cv_force_use_gnu_gettext=no
2543 fi
2544
2545       echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
2546
2547       nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
2548       if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
2549                                 CATOBJEXT=NONE
2550
2551                 
2552         
2553
2554         ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
2555 echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
2556 echo "configure:2557: checking for libintl.h" >&5
2557 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2558   echo $ac_n "(cached) $ac_c" 1>&6
2559 else
2560   cat > conftest.$ac_ext <<EOF
2561 #line 2562 "configure"
2562 #include "confdefs.h"
2563 #include <libintl.h>
2564 EOF
2565 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2566 { (eval echo configure:2567: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2567 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2568 if test -z "$ac_err"; then
2569   rm -rf conftest*
2570   eval "ac_cv_header_$ac_safe=yes"
2571 else
2572   echo "$ac_err" >&5
2573   echo "configure: failed program was:" >&5
2574   cat conftest.$ac_ext >&5
2575   rm -rf conftest*
2576   eval "ac_cv_header_$ac_safe=no"
2577 fi
2578 rm -f conftest*
2579 fi
2580 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2581   echo "$ac_t""yes" 1>&6
2582   echo $ac_n "checking for GNU gettext in libc""... $ac_c" 1>&6
2583 echo "configure:2584: checking for GNU gettext in libc" >&5
2584 if eval "test \"`echo '$''{'gt_cv_func_gnugettext1_libc'+set}'`\" = set"; then
2585   echo $ac_n "(cached) $ac_c" 1>&6
2586 else
2587   cat > conftest.$ac_ext <<EOF
2588 #line 2589 "configure"
2589 #include "confdefs.h"
2590 #include <libintl.h>
2591 extern int _nl_msg_cat_cntr;
2592 int main() {
2593 bindtextdomain ("", "");
2594 return (int) gettext ("") + _nl_msg_cat_cntr
2595 ; return 0; }
2596 EOF
2597 if { (eval echo configure:2598: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2598   rm -rf conftest*
2599   gt_cv_func_gnugettext1_libc=yes
2600 else
2601   echo "configure: failed program was:" >&5
2602   cat conftest.$ac_ext >&5
2603   rm -rf conftest*
2604   gt_cv_func_gnugettext1_libc=no
2605 fi
2606 rm -f conftest*
2607 fi
2608
2609 echo "$ac_t""$gt_cv_func_gnugettext1_libc" 1>&6
2610
2611            if test "$gt_cv_func_gnugettext1_libc" != "yes"; then
2612              echo $ac_n "checking for GNU gettext in libintl""... $ac_c" 1>&6
2613 echo "configure:2614: checking for GNU gettext in libintl" >&5
2614 if eval "test \"`echo '$''{'gt_cv_func_gnugettext1_libintl'+set}'`\" = set"; then
2615   echo $ac_n "(cached) $ac_c" 1>&6
2616 else
2617   gt_save_LIBS="$LIBS"
2618                 LIBS="$LIBS -lintl $LIBICONV"
2619                 cat > conftest.$ac_ext <<EOF
2620 #line 2621 "configure"
2621 #include "confdefs.h"
2622 #include <libintl.h>
2623 extern int _nl_msg_cat_cntr;
2624 int main() {
2625 bindtextdomain ("", "");
2626 return (int) gettext ("") + _nl_msg_cat_cntr
2627 ; return 0; }
2628 EOF
2629 if { (eval echo configure:2630: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2630   rm -rf conftest*
2631   gt_cv_func_gnugettext1_libintl=yes
2632 else
2633   echo "configure: failed program was:" >&5
2634   cat conftest.$ac_ext >&5
2635   rm -rf conftest*
2636   gt_cv_func_gnugettext1_libintl=no
2637 fi
2638 rm -f conftest*
2639                 LIBS="$gt_save_LIBS"
2640 fi
2641
2642 echo "$ac_t""$gt_cv_func_gnugettext1_libintl" 1>&6
2643            fi
2644
2645                                            if test "$gt_cv_func_gnugettext1_libc" = "yes" \
2646               || { test "$gt_cv_func_gnugettext1_libintl" = "yes" \
2647                    && test "$PACKAGE" != gettext; }; then
2648              cat >> confdefs.h <<\EOF
2649 #define HAVE_GETTEXT 1
2650 EOF
2651
2652
2653              if test "$gt_cv_func_gnugettext1_libintl" = "yes"; then
2654                                        INTLLIBS="-lintl $LIBICONV"
2655              fi
2656
2657              gt_save_LIBS="$LIBS"
2658              LIBS="$LIBS $INTLLIBS"
2659              for ac_func in dcgettext
2660 do
2661 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2662 echo "configure:2663: checking for $ac_func" >&5
2663 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2664   echo $ac_n "(cached) $ac_c" 1>&6
2665 else
2666   cat > conftest.$ac_ext <<EOF
2667 #line 2668 "configure"
2668 #include "confdefs.h"
2669 /* System header to define __stub macros and hopefully few prototypes,
2670     which can conflict with char $ac_func(); below.  */
2671 #include <assert.h>
2672 /* Override any gcc2 internal prototype to avoid an error.  */
2673 /* We use char because int might match the return type of a gcc2
2674     builtin and then its argument prototype would still apply.  */
2675 char $ac_func();
2676
2677 int main() {
2678
2679 /* The GNU C library defines this for functions which it implements
2680     to always fail with ENOSYS.  Some functions are actually named
2681     something starting with __ and the normal name is an alias.  */
2682 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2683 choke me
2684 #else
2685 $ac_func();
2686 #endif
2687
2688 ; return 0; }
2689 EOF
2690 if { (eval echo configure:2691: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2691   rm -rf conftest*
2692   eval "ac_cv_func_$ac_func=yes"
2693 else
2694   echo "configure: failed program was:" >&5
2695   cat conftest.$ac_ext >&5
2696   rm -rf conftest*
2697   eval "ac_cv_func_$ac_func=no"
2698 fi
2699 rm -f conftest*
2700 fi
2701
2702 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2703   echo "$ac_t""yes" 1>&6
2704     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2705   cat >> confdefs.h <<EOF
2706 #define $ac_tr_func 1
2707 EOF
2708  
2709 else
2710   echo "$ac_t""no" 1>&6
2711 fi
2712 done
2713
2714              LIBS="$gt_save_LIBS"
2715
2716                      # Extract the first word of "msgfmt", so it can be a program name with args.
2717 set dummy msgfmt; ac_word=$2
2718 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2719 echo "configure:2720: checking for $ac_word" >&5
2720 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
2721   echo $ac_n "(cached) $ac_c" 1>&6
2722 else
2723   case "$MSGFMT" in
2724   /*)
2725   ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
2726   ;;
2727   *)
2728   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2729   for ac_dir in $PATH; do
2730     test -z "$ac_dir" && ac_dir=.
2731     if test -f $ac_dir/$ac_word; then
2732       if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1; then
2733         ac_cv_path_MSGFMT="$ac_dir/$ac_word"
2734         break
2735       fi
2736     fi
2737   done
2738   IFS="$ac_save_ifs"
2739   test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
2740   ;;
2741 esac
2742 fi
2743 MSGFMT="$ac_cv_path_MSGFMT"
2744 if test "$MSGFMT" != ":"; then
2745   echo "$ac_t""$MSGFMT" 1>&6
2746 else
2747   echo "$ac_t""no" 1>&6
2748 fi
2749
2750              # Extract the first word of "gmsgfmt", so it can be a program name with args.
2751 set dummy gmsgfmt; ac_word=$2
2752 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2753 echo "configure:2754: checking for $ac_word" >&5
2754 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
2755   echo $ac_n "(cached) $ac_c" 1>&6
2756 else
2757   case "$GMSGFMT" in
2758   /*)
2759   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
2760   ;;
2761   ?:/*)                  
2762   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
2763   ;;
2764   *)
2765   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
2766   ac_dummy="$PATH"
2767   for ac_dir in $ac_dummy; do 
2768     test -z "$ac_dir" && ac_dir=.
2769     if test -f $ac_dir/$ac_word; then
2770       ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
2771       break
2772     fi
2773   done
2774   IFS="$ac_save_ifs"
2775   test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
2776   ;;
2777 esac
2778 fi
2779 GMSGFMT="$ac_cv_path_GMSGFMT"
2780 if test -n "$GMSGFMT"; then
2781   echo "$ac_t""$GMSGFMT" 1>&6
2782 else
2783   echo "$ac_t""no" 1>&6
2784 fi
2785
2786
2787                      # Extract the first word of "xgettext", so it can be a program name with args.
2788 set dummy xgettext; ac_word=$2
2789 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2790 echo "configure:2791: checking for $ac_word" >&5
2791 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
2792   echo $ac_n "(cached) $ac_c" 1>&6
2793 else
2794   case "$XGETTEXT" in
2795   /*)
2796   ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
2797   ;;
2798   *)
2799   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2800   for ac_dir in $PATH; do
2801     test -z "$ac_dir" && ac_dir=.
2802     if test -f $ac_dir/$ac_word; then
2803       if $ac_dir/$ac_word --omit-header /dev/null >/dev/null 2>&1; then
2804         ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
2805         break
2806       fi
2807     fi
2808   done
2809   IFS="$ac_save_ifs"
2810   test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
2811   ;;
2812 esac
2813 fi
2814 XGETTEXT="$ac_cv_path_XGETTEXT"
2815 if test "$XGETTEXT" != ":"; then
2816   echo "$ac_t""$XGETTEXT" 1>&6
2817 else
2818   echo "$ac_t""no" 1>&6
2819 fi
2820
2821
2822              CATOBJEXT=.gmo
2823            fi
2824         
2825 else
2826   echo "$ac_t""no" 1>&6
2827 fi
2828
2829
2830         if test "$CATOBJEXT" = "NONE"; then
2831                           nls_cv_use_gnu_gettext=yes
2832         fi
2833       fi
2834
2835       if test "$nls_cv_use_gnu_gettext" = "yes"; then
2836                 INTLOBJS="\$(GETTOBJS)"
2837         # Extract the first word of "msgfmt", so it can be a program name with args.
2838 set dummy msgfmt; ac_word=$2
2839 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2840 echo "configure:2841: checking for $ac_word" >&5
2841 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
2842   echo $ac_n "(cached) $ac_c" 1>&6
2843 else
2844   case "$MSGFMT" in
2845   /*)
2846   ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
2847   ;;
2848   *)
2849   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2850   for ac_dir in $PATH; do
2851     test -z "$ac_dir" && ac_dir=.
2852     if test -f $ac_dir/$ac_word; then
2853       if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1; then
2854         ac_cv_path_MSGFMT="$ac_dir/$ac_word"
2855         break
2856       fi
2857     fi
2858   done
2859   IFS="$ac_save_ifs"
2860   test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
2861   ;;
2862 esac
2863 fi
2864 MSGFMT="$ac_cv_path_MSGFMT"
2865 if test "$MSGFMT" != ":"; then
2866   echo "$ac_t""$MSGFMT" 1>&6
2867 else
2868   echo "$ac_t""no" 1>&6
2869 fi
2870
2871         # Extract the first word of "gmsgfmt", so it can be a program name with args.
2872 set dummy gmsgfmt; ac_word=$2
2873 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2874 echo "configure:2875: checking for $ac_word" >&5
2875 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
2876   echo $ac_n "(cached) $ac_c" 1>&6
2877 else
2878   case "$GMSGFMT" in
2879   /*)
2880   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
2881   ;;
2882   ?:/*)                  
2883   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
2884   ;;
2885   *)
2886   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
2887   ac_dummy="$PATH"
2888   for ac_dir in $ac_dummy; do 
2889     test -z "$ac_dir" && ac_dir=.
2890     if test -f $ac_dir/$ac_word; then
2891       ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
2892       break
2893     fi
2894   done
2895   IFS="$ac_save_ifs"
2896   test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
2897   ;;
2898 esac
2899 fi
2900 GMSGFMT="$ac_cv_path_GMSGFMT"
2901 if test -n "$GMSGFMT"; then
2902   echo "$ac_t""$GMSGFMT" 1>&6
2903 else
2904   echo "$ac_t""no" 1>&6
2905 fi
2906
2907         # Extract the first word of "xgettext", so it can be a program name with args.
2908 set dummy xgettext; ac_word=$2
2909 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2910 echo "configure:2911: checking for $ac_word" >&5
2911 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
2912   echo $ac_n "(cached) $ac_c" 1>&6
2913 else
2914   case "$XGETTEXT" in
2915   /*)
2916   ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
2917   ;;
2918   *)
2919   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2920   for ac_dir in $PATH; do
2921     test -z "$ac_dir" && ac_dir=.
2922     if test -f $ac_dir/$ac_word; then
2923       if $ac_dir/$ac_word --omit-header /dev/null >/dev/null 2>&1; then
2924         ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
2925         break
2926       fi
2927     fi
2928   done
2929   IFS="$ac_save_ifs"
2930   test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
2931   ;;
2932 esac
2933 fi
2934 XGETTEXT="$ac_cv_path_XGETTEXT"
2935 if test "$XGETTEXT" != ":"; then
2936   echo "$ac_t""$XGETTEXT" 1>&6
2937 else
2938   echo "$ac_t""no" 1>&6
2939 fi
2940
2941         
2942         BUILD_INCLUDED_LIBINTL=yes
2943         USE_INCLUDED_LIBINTL=yes
2944         CATOBJEXT=.gmo
2945         INTLLIBS="\$(top_builddir)/intl/libintl.a $LIBICONV"
2946         LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'`
2947       fi
2948
2949                   if test "$GMSGFMT" != ":"; then
2950                         if $GMSGFMT --statistics /dev/null >/dev/null 2>&1; then
2951           : ;
2952         else
2953           echo "$ac_t""found msgfmt program is not GNU msgfmt; ignore it" 1>&6
2954           GMSGFMT=":"
2955         fi
2956       fi
2957
2958                   if test "$XGETTEXT" != ":"; then
2959                         if $XGETTEXT --omit-header /dev/null >/dev/null 2>&1; then
2960           : ;
2961         else
2962           echo "$ac_t""found xgettext program is not GNU xgettext; ignore it" 1>&6
2963           XGETTEXT=":"
2964         fi
2965       fi
2966
2967             POSUB=po
2968     fi
2969     
2970
2971
2972             if test "$PACKAGE" = gettext; then
2973       BUILD_INCLUDED_LIBINTL=yes
2974     fi
2975
2976                                             for ac_prog in bison
2977 do
2978 # Extract the first word of "$ac_prog", so it can be a program name with args.
2979 set dummy $ac_prog; ac_word=$2
2980 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2981 echo "configure:2982: checking for $ac_word" >&5
2982 if eval "test \"`echo '$''{'ac_cv_prog_INTLBISON'+set}'`\" = set"; then
2983   echo $ac_n "(cached) $ac_c" 1>&6
2984 else
2985   if test -n "$INTLBISON"; then
2986   ac_cv_prog_INTLBISON="$INTLBISON" # Let the user override the test.
2987 else
2988   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
2989   ac_dummy="$PATH"
2990   for ac_dir in $ac_dummy; do
2991     test -z "$ac_dir" && ac_dir=.
2992     if test -f $ac_dir/$ac_word; then
2993       ac_cv_prog_INTLBISON="$ac_prog"
2994       break
2995     fi
2996   done
2997   IFS="$ac_save_ifs"
2998 fi
2999 fi
3000 INTLBISON="$ac_cv_prog_INTLBISON"
3001 if test -n "$INTLBISON"; then
3002   echo "$ac_t""$INTLBISON" 1>&6
3003 else
3004   echo "$ac_t""no" 1>&6
3005 fi
3006
3007 test -n "$INTLBISON" && break
3008 done
3009
3010     if test -z "$INTLBISON"; then
3011       ac_verc_fail=yes
3012     else
3013             echo $ac_n "checking version of bison""... $ac_c" 1>&6
3014 echo "configure:3015: checking version of bison" >&5
3015       ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
3016       case $ac_prog_version in
3017         '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
3018         1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*)
3019            ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
3020         *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
3021       esac
3022       echo "$ac_t""$ac_prog_version" 1>&6
3023     fi
3024     if test $ac_verc_fail = yes; then
3025       INTLBISON=:
3026     fi
3027
3028                 for lang in $ALL_LINGUAS; do
3029       GMOFILES="$GMOFILES $lang.gmo"
3030       POFILES="$POFILES $lang.po"
3031     done
3032
3033         
3034     
3035     
3036     
3037     
3038     
3039     
3040     
3041     
3042
3043         nls_cv_header_intl=
3044     nls_cv_header_libgt=
3045
3046         DATADIRNAME=share
3047     
3048
3049         INSTOBJEXT=.mo
3050     
3051
3052         GENCAT=gencat
3053     
3054   
3055
3056    if test "x$CATOBJEXT" != "x"; then
3057      if test "x$ALL_LINGUAS" = "x"; then
3058        LINGUAS=
3059      else
3060        echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
3061 echo "configure:3062: checking for catalogs to be installed" >&5
3062        NEW_LINGUAS=
3063        for presentlang in $ALL_LINGUAS; do
3064          useit=no
3065          for desiredlang in ${LINGUAS-$ALL_LINGUAS}; do
3066            # Use the presentlang catalog if desiredlang is
3067            #   a. equal to presentlang, or
3068            #   b. a variant of presentlang (because in this case,
3069            #      presentlang can be used as a fallback for messages
3070            #      which are not translated in the desiredlang catalog).
3071            case "$desiredlang" in
3072              "$presentlang"*) useit=yes;;
3073            esac
3074          done
3075          if test $useit = yes; then
3076            NEW_LINGUAS="$NEW_LINGUAS $presentlang"
3077          fi
3078        done
3079        LINGUAS=$NEW_LINGUAS
3080        echo "$ac_t""$LINGUAS" 1>&6
3081      fi
3082
3083           if test -n "$LINGUAS"; then
3084        for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
3085      fi
3086    fi
3087
3088             MKINSTALLDIRS=
3089    if test -n "$ac_aux_dir"; then
3090      MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
3091    fi
3092    if test -z "$MKINSTALLDIRS"; then
3093      MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
3094    fi
3095    
3096
3097       INTL_LIBTOOL_SUFFIX_PREFIX=
3098    
3099   
3100
3101 # Find a good install program.  We prefer a C program (faster),
3102 # so one script is as good as another.  But avoid the broken or
3103 # incompatible versions:
3104 # SysV /etc/install, /usr/sbin/install
3105 # SunOS /usr/etc/install
3106 # IRIX /sbin/install
3107 # AIX /bin/install
3108 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3109 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3110 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3111 # ./install, which can be erroneously created by make from ./install.sh.
3112 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
3113 echo "configure:3114: checking for a BSD compatible install" >&5
3114 if test -z "$INSTALL"; then
3115 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
3116   echo $ac_n "(cached) $ac_c" 1>&6
3117 else
3118     IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
3119   for ac_dir in $PATH; do
3120     # Account for people who put trailing slashes in PATH elements.
3121     case "$ac_dir/" in
3122     /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
3123     *)
3124       # OSF1 and SCO ODT 3.0 have their own names for install.
3125       # Don't use installbsd from OSF since it installs stuff as root
3126       # by default.
3127       for ac_prog in ginstall scoinst install; do
3128         if test -f $ac_dir/$ac_prog; then
3129           if test $ac_prog = install &&
3130             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
3131             # AIX install.  It has an incompatible calling convention.
3132             :
3133           else
3134             ac_cv_path_install="$ac_dir/$ac_prog -c"
3135             break 2
3136           fi
3137         fi
3138       done
3139       ;;
3140     esac
3141   done
3142   IFS="$ac_save_IFS"
3143
3144 fi
3145   if test "${ac_cv_path_install+set}" = set; then
3146     INSTALL="$ac_cv_path_install"
3147   else
3148     # As a last resort, use the slow shell script.  We don't cache a
3149     # path for INSTALL within a source directory, because that will
3150     # break other packages using the cache if that directory is
3151     # removed, or if the path is relative.
3152     INSTALL="$ac_install_sh"
3153   fi
3154 fi
3155 echo "$ac_t""$INSTALL" 1>&6
3156
3157 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3158 # It thinks the first close brace ends the variable substitution.
3159 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3160
3161 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
3162
3163 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3164
3165
3166 case x"${target_os}" in
3167   x)
3168     SYS=unknown
3169     ;;
3170   xlinux*)
3171     SYS=linux
3172     ;;
3173   xbsdi*)
3174     SYS=bsdi
3175     save_CFLAGS="${save_CFLAGS} -pthread"
3176     dvd_LDFLAGS="${dvd_LDFLAGS} -ldvd"
3177     vcd_LDFLAGS="${vcd_LDFLAGS} -ldvd"
3178     ;;
3179   x*bsd*)
3180     SYS="${target_os}"
3181     save_CFLAGS="${save_CFLAGS} -pthread"
3182     ;;
3183   xdarwin*)
3184     SYS=darwin
3185     save_CFLAGS="${save_CFLAGS} -no-cpp-precomp"
3186     ;;
3187   x*mingw32*)
3188     SYS=mingw32
3189     # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
3190 set dummy ${ac_tool_prefix}windres; ac_word=$2
3191 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3192 echo "configure:3193: checking for $ac_word" >&5
3193 if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
3194   echo $ac_n "(cached) $ac_c" 1>&6
3195 else
3196   if test -n "$WINDRES"; then
3197   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
3198 else
3199   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
3200   ac_dummy="$PATH"
3201   for ac_dir in $ac_dummy; do
3202     test -z "$ac_dir" && ac_dir=.
3203     if test -f $ac_dir/$ac_word; then
3204       ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
3205       break
3206     fi
3207   done
3208   IFS="$ac_save_ifs"
3209 fi
3210 fi
3211 WINDRES="$ac_cv_prog_WINDRES"
3212 if test -n "$WINDRES"; then
3213   echo "$ac_t""$WINDRES" 1>&6
3214 else
3215   echo "$ac_t""no" 1>&6
3216 fi
3217
3218
3219 if test -z "$ac_cv_prog_WINDRES"; then
3220 if test -n "$ac_tool_prefix"; then
3221   # Extract the first word of "windres", so it can be a program name with args.
3222 set dummy windres; ac_word=$2
3223 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3224 echo "configure:3225: checking for $ac_word" >&5
3225 if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
3226   echo $ac_n "(cached) $ac_c" 1>&6
3227 else
3228   if test -n "$WINDRES"; then
3229   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
3230 else
3231   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
3232   ac_dummy="$PATH"
3233   for ac_dir in $ac_dummy; do
3234     test -z "$ac_dir" && ac_dir=.
3235     if test -f $ac_dir/$ac_word; then
3236       ac_cv_prog_WINDRES="windres"
3237       break
3238     fi
3239   done
3240   IFS="$ac_save_ifs"
3241   test -z "$ac_cv_prog_WINDRES" && ac_cv_prog_WINDRES=":"
3242 fi
3243 fi
3244 WINDRES="$ac_cv_prog_WINDRES"
3245 if test -n "$WINDRES"; then
3246   echo "$ac_t""$WINDRES" 1>&6
3247 else
3248   echo "$ac_t""no" 1>&6
3249 fi
3250
3251 else
3252   WINDRES=":"
3253 fi
3254 fi
3255
3256     save_CFLAGS="${save_CFLAGS} -fnative-struct -D_OFF_T_ -D_off_t=long"
3257     vlc_LDFLAGS="${vlc_LDFLAGS} -mwindows -Xlinker --force-exe-suffix"
3258     vlc_LDFLAGS="${vlc_LDFLAGS} -lws2_32 -lnetapi32"
3259     ipv4_LDFLAGS="${ipv4_LDFLAGS} -lws2_32"
3260     rc_LDFLAGS="${rc_LDFLAGS} -lws2_32"
3261     ;;
3262   x*nto*)
3263     SYS=nto
3264     x11_LDFLAGS="${x11_LDFLAGS} -lsocket"
3265     xvideo_LDFLAGS="${xvideo_LDFLAGS} -lsocket"
3266     ;;
3267   xbeos)
3268     SYS=beos
3269     save_CFLAGS="${save_CFLAGS} -Wno-multichar -Wno-ctor-dtor-privacy -Woverloaded-virtual"
3270     vlc_LDFLAGS="${vlc_LDFLAGS} -lbe"
3271     plugins_LDFLAGS="${plugins_LDFLAGS} -nostart"
3272     beos_LDFLAGS="${beos_LDFLAGS} -lbe -lgame -lroot -ltracker"
3273     ipv4_LDFLAGS="${ipv4_LDFLAGS} -lbind"
3274     ;;
3275   x*)
3276     SYS="${target_os}"
3277     ;;
3278 esac
3279
3280 if test x"${SYS}" = xmingw32
3281 then
3282   plugins_CFLAGS="${plugins_CFLAGS} -fnative-struct"
3283 else
3284   plugins_CFLAGS="${plugins_CFLAGS} -fPIC"
3285 fi
3286
3287 save_CFLAGS="${save_CFLAGS} -DSYS_`echo ${SYS} | sed -e 's/-.*//' | tr 'abcdefghijklmnopqrstuvwxyz.' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`"
3288
3289 for ac_func in gettimeofday select strerror strtod strtol isatty vasprintf swab sigrelse getpwuid memalign posix_memalign gethostbyname2
3290 do
3291 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3292 echo "configure:3293: checking for $ac_func" >&5
3293 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3294   echo $ac_n "(cached) $ac_c" 1>&6
3295 else
3296   cat > conftest.$ac_ext <<EOF
3297 #line 3298 "configure"
3298 #include "confdefs.h"
3299 /* System header to define __stub macros and hopefully few prototypes,
3300     which can conflict with char $ac_func(); below.  */
3301 #include <assert.h>
3302 /* Override any gcc2 internal prototype to avoid an error.  */
3303 /* We use char because int might match the return type of a gcc2
3304     builtin and then its argument prototype would still apply.  */
3305 char $ac_func();
3306
3307 int main() {
3308
3309 /* The GNU C library defines this for functions which it implements
3310     to always fail with ENOSYS.  Some functions are actually named
3311     something starting with __ and the normal name is an alias.  */
3312 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3313 choke me
3314 #else
3315 $ac_func();
3316 #endif
3317
3318 ; return 0; }
3319 EOF
3320 if { (eval echo configure:3321: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3321   rm -rf conftest*
3322   eval "ac_cv_func_$ac_func=yes"
3323 else
3324   echo "configure: failed program was:" >&5
3325   cat conftest.$ac_ext >&5
3326   rm -rf conftest*
3327   eval "ac_cv_func_$ac_func=no"
3328 fi
3329 rm -f conftest*
3330 fi
3331
3332 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3333   echo "$ac_t""yes" 1>&6
3334     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3335   cat >> confdefs.h <<EOF
3336 #define $ac_tr_func 1
3337 EOF
3338  
3339 else
3340   echo "$ac_t""no" 1>&6
3341 fi
3342 done
3343
3344
3345 echo $ac_n "checking for connect""... $ac_c" 1>&6
3346 echo "configure:3347: checking for connect" >&5
3347 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
3348   echo $ac_n "(cached) $ac_c" 1>&6
3349 else
3350   cat > conftest.$ac_ext <<EOF
3351 #line 3352 "configure"
3352 #include "confdefs.h"
3353 /* System header to define __stub macros and hopefully few prototypes,
3354     which can conflict with char connect(); below.  */
3355 #include <assert.h>
3356 /* Override any gcc2 internal prototype to avoid an error.  */
3357 /* We use char because int might match the return type of a gcc2
3358     builtin and then its argument prototype would still apply.  */
3359 char connect();
3360
3361 int main() {
3362
3363 /* The GNU C library defines this for functions which it implements
3364     to always fail with ENOSYS.  Some functions are actually named
3365     something starting with __ and the normal name is an alias.  */
3366 #if defined (__stub_connect) || defined (__stub___connect)
3367 choke me
3368 #else
3369 connect();
3370 #endif
3371
3372 ; return 0; }
3373 EOF
3374 if { (eval echo configure:3375: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3375   rm -rf conftest*
3376   eval "ac_cv_func_connect=yes"
3377 else
3378   echo "configure: failed program was:" >&5
3379   cat conftest.$ac_ext >&5
3380   rm -rf conftest*
3381   eval "ac_cv_func_connect=no"
3382 fi
3383 rm -f conftest*
3384 fi
3385
3386 if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
3387   echo "$ac_t""yes" 1>&6
3388   :
3389 else
3390   echo "$ac_t""no" 1>&6
3391
3392   echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
3393 echo "configure:3394: checking for connect in -lsocket" >&5
3394 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
3395 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3396   echo $ac_n "(cached) $ac_c" 1>&6
3397 else
3398   ac_save_LIBS="$LIBS"
3399 LIBS="-lsocket  $LIBS"
3400 cat > conftest.$ac_ext <<EOF
3401 #line 3402 "configure"
3402 #include "confdefs.h"
3403 /* Override any gcc2 internal prototype to avoid an error.  */
3404 /* We use char because int might match the return type of a gcc2
3405     builtin and then its argument prototype would still apply.  */
3406 char connect();
3407
3408 int main() {
3409 connect()
3410 ; return 0; }
3411 EOF
3412 if { (eval echo configure:3413: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3413   rm -rf conftest*
3414   eval "ac_cv_lib_$ac_lib_var=yes"
3415 else
3416   echo "configure: failed program was:" >&5
3417   cat conftest.$ac_ext >&5
3418   rm -rf conftest*
3419   eval "ac_cv_lib_$ac_lib_var=no"
3420 fi
3421 rm -f conftest*
3422 LIBS="$ac_save_LIBS"
3423
3424 fi
3425 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3426   echo "$ac_t""yes" 1>&6
3427   ipv4_LDFLAGS="${ipv4_LDFLAGS} -lsocket"
3428     vlc_LDFLAGS="${vlc_LDFLAGS} -lsocket"
3429
3430 else
3431   echo "$ac_t""no" 1>&6
3432 fi
3433
3434 fi
3435
3436 echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
3437 echo "configure:3438: checking for gethostbyname" >&5
3438 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
3439   echo $ac_n "(cached) $ac_c" 1>&6
3440 else
3441   cat > conftest.$ac_ext <<EOF
3442 #line 3443 "configure"
3443 #include "confdefs.h"
3444 /* System header to define __stub macros and hopefully few prototypes,
3445     which can conflict with char gethostbyname(); below.  */
3446 #include <assert.h>
3447 /* Override any gcc2 internal prototype to avoid an error.  */
3448 /* We use char because int might match the return type of a gcc2
3449     builtin and then its argument prototype would still apply.  */
3450 char gethostbyname();
3451
3452 int main() {
3453
3454 /* The GNU C library defines this for functions which it implements
3455     to always fail with ENOSYS.  Some functions are actually named
3456     something starting with __ and the normal name is an alias.  */
3457 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
3458 choke me
3459 #else
3460 gethostbyname();
3461 #endif
3462
3463 ; return 0; }
3464 EOF
3465 if { (eval echo configure:3466: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3466   rm -rf conftest*
3467   eval "ac_cv_func_gethostbyname=yes"
3468 else
3469   echo "configure: failed program was:" >&5
3470   cat conftest.$ac_ext >&5
3471   rm -rf conftest*
3472   eval "ac_cv_func_gethostbyname=no"
3473 fi
3474 rm -f conftest*
3475 fi
3476
3477 if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
3478   echo "$ac_t""yes" 1>&6
3479   :
3480 else
3481   echo "$ac_t""no" 1>&6
3482
3483   echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
3484 echo "configure:3485: checking for gethostbyname in -lnsl" >&5
3485 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
3486 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3487   echo $ac_n "(cached) $ac_c" 1>&6
3488 else
3489   ac_save_LIBS="$LIBS"
3490 LIBS="-lnsl  $LIBS"
3491 cat > conftest.$ac_ext <<EOF
3492 #line 3493 "configure"
3493 #include "confdefs.h"
3494 /* Override any gcc2 internal prototype to avoid an error.  */
3495 /* We use char because int might match the return type of a gcc2
3496     builtin and then its argument prototype would still apply.  */
3497 char gethostbyname();
3498
3499 int main() {
3500 gethostbyname()
3501 ; return 0; }
3502 EOF
3503 if { (eval echo configure:3504: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3504   rm -rf conftest*
3505   eval "ac_cv_lib_$ac_lib_var=yes"
3506 else
3507   echo "configure: failed program was:" >&5
3508   cat conftest.$ac_ext >&5
3509   rm -rf conftest*
3510   eval "ac_cv_lib_$ac_lib_var=no"
3511 fi
3512 rm -f conftest*
3513 LIBS="$ac_save_LIBS"
3514
3515 fi
3516 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3517   echo "$ac_t""yes" 1>&6
3518   ipv4_LDFLAGS="${ipv4_LDFLAGS} -lnsl"
3519 else
3520   echo "$ac_t""no" 1>&6
3521 fi
3522
3523
3524 fi
3525
3526 echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
3527 echo "configure:3528: checking for gethostbyname" >&5
3528 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
3529   echo $ac_n "(cached) $ac_c" 1>&6
3530 else
3531   cat > conftest.$ac_ext <<EOF
3532 #line 3533 "configure"
3533 #include "confdefs.h"
3534 /* System header to define __stub macros and hopefully few prototypes,
3535     which can conflict with char gethostbyname(); below.  */
3536 #include <assert.h>
3537 /* Override any gcc2 internal prototype to avoid an error.  */
3538 /* We use char because int might match the return type of a gcc2
3539     builtin and then its argument prototype would still apply.  */
3540 char gethostbyname();
3541
3542 int main() {
3543
3544 /* The GNU C library defines this for functions which it implements
3545     to always fail with ENOSYS.  Some functions are actually named
3546     something starting with __ and the normal name is an alias.  */
3547 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
3548 choke me
3549 #else
3550 gethostbyname();
3551 #endif
3552
3553 ; return 0; }
3554 EOF
3555 if { (eval echo configure:3556: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3556   rm -rf conftest*
3557   eval "ac_cv_func_gethostbyname=yes"
3558 else
3559   echo "configure: failed program was:" >&5
3560   cat conftest.$ac_ext >&5
3561   rm -rf conftest*
3562   eval "ac_cv_func_gethostbyname=no"
3563 fi
3564 rm -f conftest*
3565 fi
3566
3567 if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
3568   echo "$ac_t""yes" 1>&6
3569   :
3570 else
3571   echo "$ac_t""no" 1>&6
3572
3573   echo $ac_n "checking for gethostbyname in -lbind""... $ac_c" 1>&6
3574 echo "configure:3575: checking for gethostbyname in -lbind" >&5
3575 ac_lib_var=`echo bind'_'gethostbyname | sed 'y%./+-%__p_%'`
3576 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3577   echo $ac_n "(cached) $ac_c" 1>&6
3578 else
3579   ac_save_LIBS="$LIBS"
3580 LIBS="-lbind  $LIBS"
3581 cat > conftest.$ac_ext <<EOF
3582 #line 3583 "configure"
3583 #include "confdefs.h"
3584 /* Override any gcc2 internal prototype to avoid an error.  */
3585 /* We use char because int might match the return type of a gcc2
3586     builtin and then its argument prototype would still apply.  */
3587 char gethostbyname();
3588
3589 int main() {
3590 gethostbyname()
3591 ; return 0; }
3592 EOF
3593 if { (eval echo configure:3594: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3594   rm -rf conftest*
3595   eval "ac_cv_lib_$ac_lib_var=yes"
3596 else
3597   echo "configure: failed program was:" >&5
3598   cat conftest.$ac_ext >&5
3599   rm -rf conftest*
3600   eval "ac_cv_lib_$ac_lib_var=no"
3601 fi
3602 rm -f conftest*
3603 LIBS="$ac_save_LIBS"
3604
3605 fi
3606 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3607   echo "$ac_t""yes" 1>&6
3608   ipv4_LDFLAGS="${ipv4_LDFLAGS} -lbind"
3609 else
3610   echo "$ac_t""no" 1>&6
3611 fi
3612
3613
3614 fi
3615
3616 for ac_func in nanosleep
3617 do
3618 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3619 echo "configure:3620: checking for $ac_func" >&5
3620 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3621   echo $ac_n "(cached) $ac_c" 1>&6
3622 else
3623   cat > conftest.$ac_ext <<EOF
3624 #line 3625 "configure"
3625 #include "confdefs.h"
3626 /* System header to define __stub macros and hopefully few prototypes,
3627     which can conflict with char $ac_func(); below.  */
3628 #include <assert.h>
3629 /* Override any gcc2 internal prototype to avoid an error.  */
3630 /* We use char because int might match the return type of a gcc2
3631     builtin and then its argument prototype would still apply.  */
3632 char $ac_func();
3633
3634 int main() {
3635
3636 /* The GNU C library defines this for functions which it implements
3637     to always fail with ENOSYS.  Some functions are actually named
3638     something starting with __ and the normal name is an alias.  */
3639 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3640 choke me
3641 #else
3642 $ac_func();
3643 #endif
3644
3645 ; return 0; }
3646 EOF
3647 if { (eval echo configure:3648: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3648   rm -rf conftest*
3649   eval "ac_cv_func_$ac_func=yes"
3650 else
3651   echo "configure: failed program was:" >&5
3652   cat conftest.$ac_ext >&5
3653   rm -rf conftest*
3654   eval "ac_cv_func_$ac_func=no"
3655 fi
3656 rm -f conftest*
3657 fi
3658
3659 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3660   echo "$ac_t""yes" 1>&6
3661     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3662   cat >> confdefs.h <<EOF
3663 #define $ac_tr_func 1
3664 EOF
3665  
3666 else
3667   echo "$ac_t""no" 1>&6
3668 echo $ac_n "checking for nanosleep in -lrt""... $ac_c" 1>&6
3669 echo "configure:3670: checking for nanosleep in -lrt" >&5
3670 ac_lib_var=`echo rt'_'nanosleep | sed 'y%./+-%__p_%'`
3671 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3672   echo $ac_n "(cached) $ac_c" 1>&6
3673 else
3674   ac_save_LIBS="$LIBS"
3675 LIBS="-lrt  $LIBS"
3676 cat > conftest.$ac_ext <<EOF
3677 #line 3678 "configure"
3678 #include "confdefs.h"
3679 /* Override any gcc2 internal prototype to avoid an error.  */
3680 /* We use char because int might match the return type of a gcc2
3681     builtin and then its argument prototype would still apply.  */
3682 char nanosleep();
3683
3684 int main() {
3685 nanosleep()
3686 ; return 0; }
3687 EOF
3688 if { (eval echo configure:3689: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3689   rm -rf conftest*
3690   eval "ac_cv_lib_$ac_lib_var=yes"
3691 else
3692   echo "configure: failed program was:" >&5
3693   cat conftest.$ac_ext >&5
3694   rm -rf conftest*
3695   eval "ac_cv_lib_$ac_lib_var=no"
3696 fi
3697 rm -f conftest*
3698 LIBS="$ac_save_LIBS"
3699
3700 fi
3701 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3702   echo "$ac_t""yes" 1>&6
3703   vlc_LDFLAGS="${vlc_LDFLAGS} -lrt"
3704 else
3705   echo "$ac_t""no" 1>&6
3706 echo $ac_n "checking for nanosleep in -lposix4""... $ac_c" 1>&6
3707 echo "configure:3708: checking for nanosleep in -lposix4" >&5
3708 ac_lib_var=`echo posix4'_'nanosleep | sed 'y%./+-%__p_%'`
3709 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3710   echo $ac_n "(cached) $ac_c" 1>&6
3711 else
3712   ac_save_LIBS="$LIBS"
3713 LIBS="-lposix4  $LIBS"
3714 cat > conftest.$ac_ext <<EOF
3715 #line 3716 "configure"
3716 #include "confdefs.h"
3717 /* Override any gcc2 internal prototype to avoid an error.  */
3718 /* We use char because int might match the return type of a gcc2
3719     builtin and then its argument prototype would still apply.  */
3720 char nanosleep();
3721
3722 int main() {
3723 nanosleep()
3724 ; return 0; }
3725 EOF
3726 if { (eval echo configure:3727: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3727   rm -rf conftest*
3728   eval "ac_cv_lib_$ac_lib_var=yes"
3729 else
3730   echo "configure: failed program was:" >&5
3731   cat conftest.$ac_ext >&5
3732   rm -rf conftest*
3733   eval "ac_cv_lib_$ac_lib_var=no"
3734 fi
3735 rm -f conftest*
3736 LIBS="$ac_save_LIBS"
3737
3738 fi
3739 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3740   echo "$ac_t""yes" 1>&6
3741   vlc_LDFLAGS="${vlc_LDFLAGS} -lposix4"
3742 else
3743   echo "$ac_t""no" 1>&6
3744 fi
3745
3746   
3747 fi
3748
3749
3750 fi
3751 done
3752
3753 echo $ac_n "checking for inet_aton""... $ac_c" 1>&6
3754 echo "configure:3755: checking for inet_aton" >&5
3755 if eval "test \"`echo '$''{'ac_cv_func_inet_aton'+set}'`\" = set"; then
3756   echo $ac_n "(cached) $ac_c" 1>&6
3757 else
3758   cat > conftest.$ac_ext <<EOF
3759 #line 3760 "configure"
3760 #include "confdefs.h"
3761 /* System header to define __stub macros and hopefully few prototypes,
3762     which can conflict with char inet_aton(); below.  */
3763 #include <assert.h>
3764 /* Override any gcc2 internal prototype to avoid an error.  */
3765 /* We use char because int might match the return type of a gcc2
3766     builtin and then its argument prototype would still apply.  */
3767 char inet_aton();
3768
3769 int main() {
3770
3771 /* The GNU C library defines this for functions which it implements
3772     to always fail with ENOSYS.  Some functions are actually named
3773     something starting with __ and the normal name is an alias.  */
3774 #if defined (__stub_inet_aton) || defined (__stub___inet_aton)
3775 choke me
3776 #else
3777 inet_aton();
3778 #endif
3779
3780 ; return 0; }
3781 EOF
3782 if { (eval echo configure:3783: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3783   rm -rf conftest*
3784   eval "ac_cv_func_inet_aton=yes"
3785 else
3786   echo "configure: failed program was:" >&5
3787   cat conftest.$ac_ext >&5
3788   rm -rf conftest*
3789   eval "ac_cv_func_inet_aton=no"
3790 fi
3791 rm -f conftest*
3792 fi
3793
3794 if eval "test \"`echo '$ac_cv_func_'inet_aton`\" = yes"; then
3795   echo "$ac_t""yes" 1>&6
3796   :
3797 else
3798   echo "$ac_t""no" 1>&6
3799
3800   echo $ac_n "checking for inet_aton in -lresolv""... $ac_c" 1>&6
3801 echo "configure:3802: checking for inet_aton in -lresolv" >&5
3802 ac_lib_var=`echo resolv'_'inet_aton | sed 'y%./+-%__p_%'`
3803 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3804   echo $ac_n "(cached) $ac_c" 1>&6
3805 else
3806   ac_save_LIBS="$LIBS"
3807 LIBS="-lresolv  $LIBS"
3808 cat > conftest.$ac_ext <<EOF
3809 #line 3810 "configure"
3810 #include "confdefs.h"
3811 /* Override any gcc2 internal prototype to avoid an error.  */
3812 /* We use char because int might match the return type of a gcc2
3813     builtin and then its argument prototype would still apply.  */
3814 char inet_aton();
3815
3816 int main() {
3817 inet_aton()
3818 ; return 0; }
3819 EOF
3820 if { (eval echo configure:3821: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3821   rm -rf conftest*
3822   eval "ac_cv_lib_$ac_lib_var=yes"
3823 else
3824   echo "configure: failed program was:" >&5
3825   cat conftest.$ac_ext >&5
3826   rm -rf conftest*
3827   eval "ac_cv_lib_$ac_lib_var=no"
3828 fi
3829 rm -f conftest*
3830 LIBS="$ac_save_LIBS"
3831
3832 fi
3833 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3834   echo "$ac_t""yes" 1>&6
3835   ipv4_LDFLAGS="${ipv4_LDFLAGS} -lresolv"
3836 else
3837   echo "$ac_t""no" 1>&6
3838 fi
3839
3840
3841 fi
3842
3843 echo $ac_n "checking for textdomain""... $ac_c" 1>&6
3844 echo "configure:3845: checking for textdomain" >&5
3845 if eval "test \"`echo '$''{'ac_cv_func_textdomain'+set}'`\" = set"; then
3846   echo $ac_n "(cached) $ac_c" 1>&6
3847 else
3848   cat > conftest.$ac_ext <<EOF
3849 #line 3850 "configure"
3850 #include "confdefs.h"
3851 /* System header to define __stub macros and hopefully few prototypes,
3852     which can conflict with char textdomain(); below.  */
3853 #include <assert.h>
3854 /* Override any gcc2 internal prototype to avoid an error.  */
3855 /* We use char because int might match the return type of a gcc2
3856     builtin and then its argument prototype would still apply.  */
3857 char textdomain();
3858
3859 int main() {
3860
3861 /* The GNU C library defines this for functions which it implements
3862     to always fail with ENOSYS.  Some functions are actually named
3863     something starting with __ and the normal name is an alias.  */
3864 #if defined (__stub_textdomain) || defined (__stub___textdomain)
3865 choke me
3866 #else
3867 textdomain();
3868 #endif
3869
3870 ; return 0; }
3871 EOF
3872 if { (eval echo configure:3873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3873   rm -rf conftest*
3874   eval "ac_cv_func_textdomain=yes"
3875 else
3876   echo "configure: failed program was:" >&5
3877   cat conftest.$ac_ext >&5
3878   rm -rf conftest*
3879   eval "ac_cv_func_textdomain=no"
3880 fi
3881 rm -f conftest*
3882 fi
3883
3884 if eval "test \"`echo '$ac_cv_func_'textdomain`\" = yes"; then
3885   echo "$ac_t""yes" 1>&6
3886   :
3887 else
3888   echo "$ac_t""no" 1>&6
3889
3890   echo $ac_n "checking for textdomain in -lintl""... $ac_c" 1>&6
3891 echo "configure:3892: checking for textdomain in -lintl" >&5
3892 ac_lib_var=`echo intl'_'textdomain | sed 'y%./+-%__p_%'`
3893 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3894   echo $ac_n "(cached) $ac_c" 1>&6
3895 else
3896   ac_save_LIBS="$LIBS"
3897 LIBS="-lintl  $LIBS"
3898 cat > conftest.$ac_ext <<EOF
3899 #line 3900 "configure"
3900 #include "confdefs.h"
3901 /* Override any gcc2 internal prototype to avoid an error.  */
3902 /* We use char because int might match the return type of a gcc2
3903     builtin and then its argument prototype would still apply.  */
3904 char textdomain();
3905
3906 int main() {
3907 textdomain()
3908 ; return 0; }
3909 EOF
3910 if { (eval echo configure:3911: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3911   rm -rf conftest*
3912   eval "ac_cv_lib_$ac_lib_var=yes"
3913 else
3914   echo "configure: failed program was:" >&5
3915   cat conftest.$ac_ext >&5
3916   rm -rf conftest*
3917   eval "ac_cv_lib_$ac_lib_var=no"
3918 fi
3919 rm -f conftest*
3920 LIBS="$ac_save_LIBS"
3921
3922 fi
3923 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3924   echo "$ac_t""yes" 1>&6
3925   save_LDFLAGS="${save_LDFLAGS} -lintl"
3926 else
3927   echo "$ac_t""no" 1>&6
3928 fi
3929
3930
3931 fi
3932
3933
3934 NEED_GETOPT=0
3935 echo $ac_n "checking for getopt_long""... $ac_c" 1>&6
3936 echo "configure:3937: checking for getopt_long" >&5
3937 if eval "test \"`echo '$''{'ac_cv_func_getopt_long'+set}'`\" = set"; then
3938   echo $ac_n "(cached) $ac_c" 1>&6
3939 else
3940   cat > conftest.$ac_ext <<EOF
3941 #line 3942 "configure"
3942 #include "confdefs.h"
3943 /* System header to define __stub macros and hopefully few prototypes,
3944     which can conflict with char getopt_long(); below.  */
3945 #include <assert.h>
3946 /* Override any gcc2 internal prototype to avoid an error.  */
3947 /* We use char because int might match the return type of a gcc2
3948     builtin and then its argument prototype would still apply.  */
3949 char getopt_long();
3950
3951 int main() {
3952
3953 /* The GNU C library defines this for functions which it implements
3954     to always fail with ENOSYS.  Some functions are actually named
3955     something starting with __ and the normal name is an alias.  */
3956 #if defined (__stub_getopt_long) || defined (__stub___getopt_long)
3957 choke me
3958 #else
3959 getopt_long();
3960 #endif
3961
3962 ; return 0; }
3963 EOF
3964 if { (eval echo configure:3965: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3965   rm -rf conftest*
3966   eval "ac_cv_func_getopt_long=yes"
3967 else
3968   echo "configure: failed program was:" >&5
3969   cat conftest.$ac_ext >&5
3970   rm -rf conftest*
3971   eval "ac_cv_func_getopt_long=no"
3972 fi
3973 rm -f conftest*
3974 fi
3975
3976 if eval "test \"`echo '$ac_cv_func_'getopt_long`\" = yes"; then
3977   echo "$ac_t""yes" 1>&6
3978   cat >> confdefs.h <<\EOF
3979 #define HAVE_GETOPT_LONG 1
3980 EOF
3981
3982 else
3983   echo "$ac_t""no" 1>&6
3984  # FreeBSD has a gnugetopt library for this:
3985   echo $ac_n "checking for getopt_long in -lgnugetopt""... $ac_c" 1>&6
3986 echo "configure:3987: checking for getopt_long in -lgnugetopt" >&5
3987 ac_lib_var=`echo gnugetopt'_'getopt_long | sed 'y%./+-%__p_%'`
3988 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3989   echo $ac_n "(cached) $ac_c" 1>&6
3990 else
3991   ac_save_LIBS="$LIBS"
3992 LIBS="-lgnugetopt  $LIBS"
3993 cat > conftest.$ac_ext <<EOF
3994 #line 3995 "configure"
3995 #include "confdefs.h"
3996 /* Override any gcc2 internal prototype to avoid an error.  */
3997 /* We use char because int might match the return type of a gcc2
3998     builtin and then its argument prototype would still apply.  */
3999 char getopt_long();
4000
4001 int main() {
4002 getopt_long()
4003 ; return 0; }
4004 EOF
4005 if { (eval echo configure:4006: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4006   rm -rf conftest*
4007   eval "ac_cv_lib_$ac_lib_var=yes"
4008 else
4009   echo "configure: failed program was:" >&5
4010   cat conftest.$ac_ext >&5
4011   rm -rf conftest*
4012   eval "ac_cv_lib_$ac_lib_var=no"
4013 fi
4014 rm -f conftest*
4015 LIBS="$ac_save_LIBS"
4016
4017 fi
4018 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4019   echo "$ac_t""yes" 1>&6
4020   cat >> confdefs.h <<\EOF
4021 #define HAVE_GETOPT_LONG 1
4022 EOF
4023  vlc_LDFLAGS="${vlc_LDFLAGS} -lgnugetopt"
4024 else
4025   echo "$ac_t""no" 1>&6
4026 NEED_GETOPT=1
4027 fi
4028
4029 fi
4030
4031
4032 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
4033 echo "configure:4034: checking return type of signal handlers" >&5
4034 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
4035   echo $ac_n "(cached) $ac_c" 1>&6
4036 else
4037   cat > conftest.$ac_ext <<EOF
4038 #line 4039 "configure"
4039 #include "confdefs.h"
4040 #include <sys/types.h>
4041 #include <signal.h>
4042 #ifdef signal
4043 #undef signal
4044 #endif
4045 #ifdef __cplusplus
4046 extern "C" void (*signal (int, void (*)(int)))(int);
4047 #else
4048 void (*signal ()) ();
4049 #endif
4050
4051 int main() {
4052 int i;
4053 ; return 0; }
4054 EOF
4055 if { (eval echo configure:4056: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4056   rm -rf conftest*
4057   ac_cv_type_signal=void
4058 else
4059   echo "configure: failed program was:" >&5
4060   cat conftest.$ac_ext >&5
4061   rm -rf conftest*
4062   ac_cv_type_signal=int
4063 fi
4064 rm -f conftest*
4065 fi
4066
4067 echo "$ac_t""$ac_cv_type_signal" 1>&6
4068 cat >> confdefs.h <<EOF
4069 #define RETSIGTYPE $ac_cv_type_signal
4070 EOF
4071
4072
4073 echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
4074 echo "configure:4075: checking for dlopen in -ldl" >&5
4075 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
4076 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4077   echo $ac_n "(cached) $ac_c" 1>&6
4078 else
4079   ac_save_LIBS="$LIBS"
4080 LIBS="-ldl  $LIBS"
4081 cat > conftest.$ac_ext <<EOF
4082 #line 4083 "configure"
4083 #include "confdefs.h"
4084 /* Override any gcc2 internal prototype to avoid an error.  */
4085 /* We use char because int might match the return type of a gcc2
4086     builtin and then its argument prototype would still apply.  */
4087 char dlopen();
4088
4089 int main() {
4090 dlopen()
4091 ; return 0; }
4092 EOF
4093 if { (eval echo configure:4094: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4094   rm -rf conftest*
4095   eval "ac_cv_lib_$ac_lib_var=yes"
4096 else
4097   echo "configure: failed program was:" >&5
4098   cat conftest.$ac_ext >&5
4099   rm -rf conftest*
4100   eval "ac_cv_lib_$ac_lib_var=no"
4101 fi
4102 rm -f conftest*
4103 LIBS="$ac_save_LIBS"
4104
4105 fi
4106 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4107   echo "$ac_t""yes" 1>&6
4108   vlc_LDFLAGS="${vlc_LDFLAGS} -ldl"
4109 else
4110   echo "$ac_t""no" 1>&6
4111 fi
4112
4113 echo $ac_n "checking for cos in -lm""... $ac_c" 1>&6
4114 echo "configure:4115: checking for cos in -lm" >&5
4115 ac_lib_var=`echo m'_'cos | sed 'y%./+-%__p_%'`
4116 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4117   echo $ac_n "(cached) $ac_c" 1>&6
4118 else
4119   ac_save_LIBS="$LIBS"
4120 LIBS="-lm  $LIBS"
4121 cat > conftest.$ac_ext <<EOF
4122 #line 4123 "configure"
4123 #include "confdefs.h"
4124 /* Override any gcc2 internal prototype to avoid an error.  */
4125 /* We use char because int might match the return type of a gcc2
4126     builtin and then its argument prototype would still apply.  */
4127 char cos();
4128
4129 int main() {
4130 cos()
4131 ; return 0; }
4132 EOF
4133 if { (eval echo configure:4134: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4134   rm -rf conftest*
4135   eval "ac_cv_lib_$ac_lib_var=yes"
4136 else
4137   echo "configure: failed program was:" >&5
4138   cat conftest.$ac_ext >&5
4139   rm -rf conftest*
4140   eval "ac_cv_lib_$ac_lib_var=no"
4141 fi
4142 rm -f conftest*
4143 LIBS="$ac_save_LIBS"
4144
4145 fi
4146 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4147   echo "$ac_t""yes" 1>&6
4148   imdct_LDFLAGS="${imdct_LDFLAGS} -lm"
4149   filter_distort_LDFLAGS="${filter_distort_LDFLAGS} -lm"
4150 else
4151   echo "$ac_t""no" 1>&6
4152 fi
4153
4154 echo $ac_n "checking for pow in -lm""... $ac_c" 1>&6
4155 echo "configure:4156: checking for pow in -lm" >&5
4156 ac_lib_var=`echo m'_'pow | sed 'y%./+-%__p_%'`
4157 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4158   echo $ac_n "(cached) $ac_c" 1>&6
4159 else
4160   ac_save_LIBS="$LIBS"
4161 LIBS="-lm  $LIBS"
4162 cat > conftest.$ac_ext <<EOF
4163 #line 4164 "configure"
4164 #include "confdefs.h"
4165 /* Override any gcc2 internal prototype to avoid an error.  */
4166 /* We use char because int might match the return type of a gcc2
4167     builtin and then its argument prototype would still apply.  */
4168 char pow();
4169
4170 int main() {
4171 pow()
4172 ; return 0; }
4173 EOF
4174 if { (eval echo configure:4175: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4175   rm -rf conftest*
4176   eval "ac_cv_lib_$ac_lib_var=yes"
4177 else
4178   echo "configure: failed program was:" >&5
4179   cat conftest.$ac_ext >&5
4180   rm -rf conftest*
4181   eval "ac_cv_lib_$ac_lib_var=no"
4182 fi
4183 rm -f conftest*
4184 LIBS="$ac_save_LIBS"
4185
4186 fi
4187 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4188   echo "$ac_t""yes" 1>&6
4189   imdct_LDFLAGS="${imdct_LDFLAGS} -lm"
4190   imdct3dn_LDFLAGS="${imdct3dn_LDFLAGS} -lm"
4191   imdctsse_LDFLAGS="${imdctsse_LDFLAGS} -lm"
4192   chroma_i420_rgb_LDFLAGS="${chroma_i420_rgb_LDFLAGS} -lm"
4193
4194 else
4195   echo "$ac_t""no" 1>&6
4196 fi
4197
4198
4199 THREAD_LIB=error
4200 if test "x${THREAD_LIB}" = xerror; then
4201   echo $ac_n "checking for pthread_attr_init in -lpthread""... $ac_c" 1>&6
4202 echo "configure:4203: checking for pthread_attr_init in -lpthread" >&5
4203 ac_lib_var=`echo pthread'_'pthread_attr_init | sed 'y%./+-%__p_%'`
4204 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4205   echo $ac_n "(cached) $ac_c" 1>&6
4206 else
4207   ac_save_LIBS="$LIBS"
4208 LIBS="-lpthread  $LIBS"
4209 cat > conftest.$ac_ext <<EOF
4210 #line 4211 "configure"
4211 #include "confdefs.h"
4212 /* Override any gcc2 internal prototype to avoid an error.  */
4213 /* We use char because int might match the return type of a gcc2
4214     builtin and then its argument prototype would still apply.  */
4215 char pthread_attr_init();
4216
4217 int main() {
4218 pthread_attr_init()
4219 ; return 0; }
4220 EOF
4221 if { (eval echo configure:4222: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4222   rm -rf conftest*
4223   eval "ac_cv_lib_$ac_lib_var=yes"
4224 else
4225   echo "configure: failed program was:" >&5
4226   cat conftest.$ac_ext >&5
4227   rm -rf conftest*
4228   eval "ac_cv_lib_$ac_lib_var=no"
4229 fi
4230 rm -f conftest*
4231 LIBS="$ac_save_LIBS"
4232
4233 fi
4234 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4235   echo "$ac_t""yes" 1>&6
4236   THREAD_LIB="-lpthread"
4237 else
4238   echo "$ac_t""no" 1>&6
4239 fi
4240
4241 fi
4242 if test "x${THREAD_LIB}" = xerror; then
4243   echo $ac_n "checking for pthread_attr_init in -lpthreads""... $ac_c" 1>&6
4244 echo "configure:4245: checking for pthread_attr_init in -lpthreads" >&5
4245 ac_lib_var=`echo pthreads'_'pthread_attr_init | sed 'y%./+-%__p_%'`
4246 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4247   echo $ac_n "(cached) $ac_c" 1>&6
4248 else
4249   ac_save_LIBS="$LIBS"
4250 LIBS="-lpthreads  $LIBS"
4251 cat > conftest.$ac_ext <<EOF
4252 #line 4253 "configure"
4253 #include "confdefs.h"
4254 /* Override any gcc2 internal prototype to avoid an error.  */
4255 /* We use char because int might match the return type of a gcc2
4256     builtin and then its argument prototype would still apply.  */
4257 char pthread_attr_init();
4258
4259 int main() {
4260 pthread_attr_init()
4261 ; return 0; }
4262 EOF
4263 if { (eval echo configure:4264: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4264   rm -rf conftest*
4265   eval "ac_cv_lib_$ac_lib_var=yes"
4266 else
4267   echo "configure: failed program was:" >&5
4268   cat conftest.$ac_ext >&5
4269   rm -rf conftest*
4270   eval "ac_cv_lib_$ac_lib_var=no"
4271 fi
4272 rm -f conftest*
4273 LIBS="$ac_save_LIBS"
4274
4275 fi
4276 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4277   echo "$ac_t""yes" 1>&6
4278   THREAD_LIB="-lpthreads"
4279 else
4280   echo "$ac_t""no" 1>&6
4281 fi
4282
4283 fi
4284 if test "x${THREAD_LIB}" = xerror; then
4285   echo $ac_n "checking for pthread_attr_init in -lc_r""... $ac_c" 1>&6
4286 echo "configure:4287: checking for pthread_attr_init in -lc_r" >&5
4287 ac_lib_var=`echo c_r'_'pthread_attr_init | sed 'y%./+-%__p_%'`
4288 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4289   echo $ac_n "(cached) $ac_c" 1>&6
4290 else
4291   ac_save_LIBS="$LIBS"
4292 LIBS="-lc_r  $LIBS"
4293 cat > conftest.$ac_ext <<EOF
4294 #line 4295 "configure"
4295 #include "confdefs.h"
4296 /* Override any gcc2 internal prototype to avoid an error.  */
4297 /* We use char because int might match the return type of a gcc2
4298     builtin and then its argument prototype would still apply.  */
4299 char pthread_attr_init();
4300
4301 int main() {
4302 pthread_attr_init()
4303 ; return 0; }
4304 EOF
4305 if { (eval echo configure:4306: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4306   rm -rf conftest*
4307   eval "ac_cv_lib_$ac_lib_var=yes"
4308 else
4309   echo "configure: failed program was:" >&5
4310   cat conftest.$ac_ext >&5
4311   rm -rf conftest*
4312   eval "ac_cv_lib_$ac_lib_var=no"
4313 fi
4314 rm -f conftest*
4315 LIBS="$ac_save_LIBS"
4316
4317 fi
4318 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4319   echo "$ac_t""yes" 1>&6
4320   THREAD_LIB="-lc_r"
4321 else
4322   echo "$ac_t""no" 1>&6
4323 fi
4324
4325 fi
4326 if test "x${THREAD_LIB}" = xerror; then
4327   echo $ac_n "checking for pthread_attr_init""... $ac_c" 1>&6
4328 echo "configure:4329: checking for pthread_attr_init" >&5
4329 if eval "test \"`echo '$''{'ac_cv_func_pthread_attr_init'+set}'`\" = set"; then
4330   echo $ac_n "(cached) $ac_c" 1>&6
4331 else
4332   cat > conftest.$ac_ext <<EOF
4333 #line 4334 "configure"
4334 #include "confdefs.h"
4335 /* System header to define __stub macros and hopefully few prototypes,
4336     which can conflict with char pthread_attr_init(); below.  */
4337 #include <assert.h>
4338 /* Override any gcc2 internal prototype to avoid an error.  */
4339 /* We use char because int might match the return type of a gcc2
4340     builtin and then its argument prototype would still apply.  */
4341 char pthread_attr_init();
4342
4343 int main() {
4344
4345 /* The GNU C library defines this for functions which it implements
4346     to always fail with ENOSYS.  Some functions are actually named
4347     something starting with __ and the normal name is an alias.  */
4348 #if defined (__stub_pthread_attr_init) || defined (__stub___pthread_attr_init)
4349 choke me
4350 #else
4351 pthread_attr_init();
4352 #endif
4353
4354 ; return 0; }
4355 EOF
4356 if { (eval echo configure:4357: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4357   rm -rf conftest*
4358   eval "ac_cv_func_pthread_attr_init=yes"
4359 else
4360   echo "configure: failed program was:" >&5
4361   cat conftest.$ac_ext >&5
4362   rm -rf conftest*
4363   eval "ac_cv_func_pthread_attr_init=no"
4364 fi
4365 rm -f conftest*
4366 fi
4367
4368 if eval "test \"`echo '$ac_cv_func_'pthread_attr_init`\" = yes"; then
4369   echo "$ac_t""yes" 1>&6
4370   :
4371 else
4372   echo "$ac_t""no" 1>&6
4373 fi
4374
4375   THREAD_LIB=""
4376 fi
4377
4378 echo $ac_n "checking for cthread_fork in -lthreads""... $ac_c" 1>&6
4379 echo "configure:4380: checking for cthread_fork in -lthreads" >&5
4380 ac_lib_var=`echo threads'_'cthread_fork | sed 'y%./+-%__p_%'`
4381 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4382   echo $ac_n "(cached) $ac_c" 1>&6
4383 else
4384   ac_save_LIBS="$LIBS"
4385 LIBS="-lthreads  $LIBS"
4386 cat > conftest.$ac_ext <<EOF
4387 #line 4388 "configure"
4388 #include "confdefs.h"
4389 /* Override any gcc2 internal prototype to avoid an error.  */
4390 /* We use char because int might match the return type of a gcc2
4391     builtin and then its argument prototype would still apply.  */
4392 char cthread_fork();
4393
4394 int main() {
4395 cthread_fork()
4396 ; return 0; }
4397 EOF
4398 if { (eval echo configure:4399: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4399   rm -rf conftest*
4400   eval "ac_cv_lib_$ac_lib_var=yes"
4401 else
4402   echo "configure: failed program was:" >&5
4403   cat conftest.$ac_ext >&5
4404   rm -rf conftest*
4405   eval "ac_cv_lib_$ac_lib_var=no"
4406 fi
4407 rm -f conftest*
4408 LIBS="$ac_save_LIBS"
4409
4410 fi
4411 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4412   echo "$ac_t""yes" 1>&6
4413   THREAD_LIB="-lthreads"
4414 else
4415   echo "$ac_t""no" 1>&6
4416 fi
4417
4418
4419 cat > conftest.$ac_ext <<EOF
4420 #line 4421 "configure"
4421 #include "confdefs.h"
4422 #include <pthread.h>
4423 EOF
4424 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4425   egrep "pthread_cond_t" >/dev/null 2>&1; then
4426   rm -rf conftest*
4427   
4428   cat >> confdefs.h <<\EOF
4429 #define PTHREAD_COND_T_IN_PTHREAD_H 1
4430 EOF
4431
4432 fi
4433 rm -f conftest*
4434
4435 cat > conftest.$ac_ext <<EOF
4436 #line 4437 "configure"
4437 #include "confdefs.h"
4438 #include <strings.h>
4439 EOF
4440 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4441   egrep "strncasecmp" >/dev/null 2>&1; then
4442   rm -rf conftest*
4443   
4444   cat >> confdefs.h <<\EOF
4445 #define STRNCASECMP_IN_STRINGS_H 1
4446 EOF
4447
4448 fi
4449 rm -f conftest*
4450
4451
4452 for ac_hdr in getopt.h strings.h
4453 do
4454 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4455 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4456 echo "configure:4457: checking for $ac_hdr" >&5
4457 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4458   echo $ac_n "(cached) $ac_c" 1>&6
4459 else
4460   cat > conftest.$ac_ext <<EOF
4461 #line 4462 "configure"
4462 #include "confdefs.h"
4463 #include <$ac_hdr>
4464 EOF
4465 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4466 { (eval echo configure:4467: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4467 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4468 if test -z "$ac_err"; then
4469   rm -rf conftest*
4470   eval "ac_cv_header_$ac_safe=yes"
4471 else
4472   echo "$ac_err" >&5
4473   echo "configure: failed program was:" >&5
4474   cat conftest.$ac_ext >&5
4475   rm -rf conftest*
4476   eval "ac_cv_header_$ac_safe=no"
4477 fi
4478 rm -f conftest*
4479 fi
4480 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4481   echo "$ac_t""yes" 1>&6
4482     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4483   cat >> confdefs.h <<EOF
4484 #define $ac_tr_hdr 1
4485 EOF
4486  
4487 else
4488   echo "$ac_t""no" 1>&6
4489 fi
4490 done
4491
4492 for ac_hdr in sys/sockio.h fcntl.h sys/types.h sys/time.h sys/times.h
4493 do
4494 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4495 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4496 echo "configure:4497: checking for $ac_hdr" >&5
4497 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4498   echo $ac_n "(cached) $ac_c" 1>&6
4499 else
4500   cat > conftest.$ac_ext <<EOF
4501 #line 4502 "configure"
4502 #include "confdefs.h"
4503 #include <$ac_hdr>
4504 EOF
4505 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4506 { (eval echo configure:4507: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4507 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4508 if test -z "$ac_err"; then
4509   rm -rf conftest*
4510   eval "ac_cv_header_$ac_safe=yes"
4511 else
4512   echo "$ac_err" >&5
4513   echo "configure: failed program was:" >&5
4514   cat conftest.$ac_ext >&5
4515   rm -rf conftest*
4516   eval "ac_cv_header_$ac_safe=no"
4517 fi
4518 rm -f conftest*
4519 fi
4520 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4521   echo "$ac_t""yes" 1>&6
4522     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4523   cat >> confdefs.h <<EOF
4524 #define $ac_tr_hdr 1
4525 EOF
4526  
4527 else
4528   echo "$ac_t""no" 1>&6
4529 fi
4530 done
4531
4532 for ac_hdr in dlfcn.h image.h
4533 do
4534 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4535 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4536 echo "configure:4537: checking for $ac_hdr" >&5
4537 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4538   echo $ac_n "(cached) $ac_c" 1>&6
4539 else
4540   cat > conftest.$ac_ext <<EOF
4541 #line 4542 "configure"
4542 #include "confdefs.h"
4543 #include <$ac_hdr>
4544 EOF
4545 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4546 { (eval echo configure:4547: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4547 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4548 if test -z "$ac_err"; then
4549   rm -rf conftest*
4550   eval "ac_cv_header_$ac_safe=yes"
4551 else
4552   echo "$ac_err" >&5
4553   echo "configure: failed program was:" >&5
4554   cat conftest.$ac_ext >&5
4555   rm -rf conftest*
4556   eval "ac_cv_header_$ac_safe=no"
4557 fi
4558 rm -f conftest*
4559 fi
4560 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4561   echo "$ac_t""yes" 1>&6
4562     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4563   cat >> confdefs.h <<EOF
4564 #define $ac_tr_hdr 1
4565 EOF
4566  
4567 else
4568   echo "$ac_t""no" 1>&6
4569 fi
4570 done
4571
4572 for ac_hdr in arpa/inet.h net/if.h netinet/in.h sys/socket.h
4573 do
4574 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4575 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4576 echo "configure:4577: checking for $ac_hdr" >&5
4577 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4578   echo $ac_n "(cached) $ac_c" 1>&6
4579 else
4580   cat > conftest.$ac_ext <<EOF
4581 #line 4582 "configure"
4582 #include "confdefs.h"
4583 #include <$ac_hdr>
4584 EOF
4585 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4586 { (eval echo configure:4587: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4587 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4588 if test -z "$ac_err"; then
4589   rm -rf conftest*
4590   eval "ac_cv_header_$ac_safe=yes"
4591 else
4592   echo "$ac_err" >&5
4593   echo "configure: failed program was:" >&5
4594   cat conftest.$ac_ext >&5
4595   rm -rf conftest*
4596   eval "ac_cv_header_$ac_safe=no"
4597 fi
4598 rm -f conftest*
4599 fi
4600 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4601   echo "$ac_t""yes" 1>&6
4602     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4603   cat >> confdefs.h <<EOF
4604 #define $ac_tr_hdr 1
4605 EOF
4606  
4607 else
4608   echo "$ac_t""no" 1>&6
4609 fi
4610 done
4611
4612 for ac_hdr in machine/param.h sys/shm.h
4613 do
4614 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4615 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4616 echo "configure:4617: checking for $ac_hdr" >&5
4617 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4618   echo $ac_n "(cached) $ac_c" 1>&6
4619 else
4620   cat > conftest.$ac_ext <<EOF
4621 #line 4622 "configure"
4622 #include "confdefs.h"
4623 #include <$ac_hdr>
4624 EOF
4625 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4626 { (eval echo configure:4627: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4627 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4628 if test -z "$ac_err"; then
4629   rm -rf conftest*
4630   eval "ac_cv_header_$ac_safe=yes"
4631 else
4632   echo "$ac_err" >&5
4633   echo "configure: failed program was:" >&5
4634   cat conftest.$ac_ext >&5
4635   rm -rf conftest*
4636   eval "ac_cv_header_$ac_safe=no"
4637 fi
4638 rm -f conftest*
4639 fi
4640 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4641   echo "$ac_t""yes" 1>&6
4642     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4643   cat >> confdefs.h <<EOF
4644 #define $ac_tr_hdr 1
4645 EOF
4646  
4647 else
4648   echo "$ac_t""no" 1>&6
4649 fi
4650 done
4651
4652 for ac_hdr in linux/version.h
4653 do
4654 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4655 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4656 echo "configure:4657: checking for $ac_hdr" >&5
4657 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4658   echo $ac_n "(cached) $ac_c" 1>&6
4659 else
4660   cat > conftest.$ac_ext <<EOF
4661 #line 4662 "configure"
4662 #include "confdefs.h"
4663 #include <$ac_hdr>
4664 EOF
4665 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4666 { (eval echo configure:4667: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4667 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4668 if test -z "$ac_err"; then
4669   rm -rf conftest*
4670   eval "ac_cv_header_$ac_safe=yes"
4671 else
4672   echo "$ac_err" >&5
4673   echo "configure: failed program was:" >&5
4674   cat conftest.$ac_ext >&5
4675   rm -rf conftest*
4676   eval "ac_cv_header_$ac_safe=no"
4677 fi
4678 rm -f conftest*
4679 fi
4680 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4681   echo "$ac_t""yes" 1>&6
4682     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4683   cat >> confdefs.h <<EOF
4684 #define $ac_tr_hdr 1
4685 EOF
4686  
4687 else
4688   echo "$ac_t""no" 1>&6
4689 fi
4690 done
4691
4692
4693 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
4694 echo "configure:4695: checking whether time.h and sys/time.h may both be included" >&5
4695 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
4696   echo $ac_n "(cached) $ac_c" 1>&6
4697 else
4698   cat > conftest.$ac_ext <<EOF
4699 #line 4700 "configure"
4700 #include "confdefs.h"
4701 #include <sys/types.h>
4702 #include <sys/time.h>
4703 #include <time.h>
4704 int main() {
4705 struct tm *tp;
4706 ; return 0; }
4707 EOF
4708 if { (eval echo configure:4709: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4709   rm -rf conftest*
4710   ac_cv_header_time=yes
4711 else
4712   echo "configure: failed program was:" >&5
4713   cat conftest.$ac_ext >&5
4714   rm -rf conftest*
4715   ac_cv_header_time=no
4716 fi
4717 rm -f conftest*
4718 fi
4719
4720 echo "$ac_t""$ac_cv_header_time" 1>&6
4721 if test $ac_cv_header_time = yes; then
4722   cat >> confdefs.h <<\EOF
4723 #define TIME_WITH_SYS_TIME 1
4724 EOF
4725
4726 fi
4727
4728
4729 cat > conftest.$ac_ext <<EOF
4730 #line 4731 "configure"
4731 #include "confdefs.h"
4732 #include <time.h>
4733 EOF
4734 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4735   egrep "nanosleep" >/dev/null 2>&1; then
4736   rm -rf conftest*
4737   
4738   cat >> confdefs.h <<\EOF
4739 #define HAVE_DECL_NANOSLEEP 1
4740 EOF
4741
4742
4743 fi
4744 rm -f conftest*
4745
4746
4747 cat > conftest.$ac_ext <<EOF
4748 #line 4749 "configure"
4749 #include "confdefs.h"
4750 #include <sys/time.h>
4751 EOF
4752 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4753   egrep "timespec" >/dev/null 2>&1; then
4754   rm -rf conftest*
4755   
4756   cat >> confdefs.h <<\EOF
4757 #define HAVE_STRUCT_TIMESPEC 1
4758 EOF
4759
4760
4761 fi
4762 rm -f conftest*
4763
4764
4765 for ac_hdr in cthreads.h pthread.h kernel/scheduler.h kernel/OS.h
4766 do
4767 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4768 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4769 echo "configure:4770: checking for $ac_hdr" >&5
4770 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4771   echo $ac_n "(cached) $ac_c" 1>&6
4772 else
4773   cat > conftest.$ac_ext <<EOF
4774 #line 4775 "configure"
4775 #include "confdefs.h"
4776 #include <$ac_hdr>
4777 EOF
4778 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4779 { (eval echo configure:4780: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4780 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4781 if test -z "$ac_err"; then
4782   rm -rf conftest*
4783   eval "ac_cv_header_$ac_safe=yes"
4784 else
4785   echo "$ac_err" >&5
4786   echo "configure: failed program was:" >&5
4787   cat conftest.$ac_ext >&5
4788   rm -rf conftest*
4789   eval "ac_cv_header_$ac_safe=no"
4790 fi
4791 rm -f conftest*
4792 fi
4793 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4794   echo "$ac_t""yes" 1>&6
4795     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4796   cat >> confdefs.h <<EOF
4797 #define $ac_tr_hdr 1
4798 EOF
4799  
4800 else
4801   echo "$ac_t""no" 1>&6
4802 fi
4803 done
4804
4805
4806 if test x$SYS != xmingw32
4807 then
4808   if test x$x_includes = xNONE; then
4809     x_includes=/usr/X11R6/include
4810   fi
4811   if test x$x_libraries = xNONE; then
4812     x_libraries=/usr/X11R6/lib
4813   fi
4814   CPPFLAGS="$save_CPPFLAGS -I$x_includes"
4815   for ac_hdr in X11/extensions/dpms.h
4816 do
4817 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4818 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4819 echo "configure:4820: checking for $ac_hdr" >&5
4820 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4821   echo $ac_n "(cached) $ac_c" 1>&6
4822 else
4823   cat > conftest.$ac_ext <<EOF
4824 #line 4825 "configure"
4825 #include "confdefs.h"
4826 #include <$ac_hdr>
4827 EOF
4828 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4829 { (eval echo configure:4830: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4830 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4831 if test -z "$ac_err"; then
4832   rm -rf conftest*
4833   eval "ac_cv_header_$ac_safe=yes"
4834 else
4835   echo "$ac_err" >&5
4836   echo "configure: failed program was:" >&5
4837   cat conftest.$ac_ext >&5
4838   rm -rf conftest*
4839   eval "ac_cv_header_$ac_safe=no"
4840 fi
4841 rm -f conftest*
4842 fi
4843 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4844   echo "$ac_t""yes" 1>&6
4845     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4846   cat >> confdefs.h <<EOF
4847 #define $ac_tr_hdr 1
4848 EOF
4849  
4850     cat > conftest.$ac_ext <<EOF
4851 #line 4852 "configure"
4852 #include "confdefs.h"
4853 #include <X11/extensions/dpms.h>
4854 EOF
4855 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4856   egrep "DPMSInfo" >/dev/null 2>&1; then
4857   rm -rf conftest*
4858   
4859       cat >> confdefs.h <<\EOF
4860 #define DPMSINFO_IN_DPMS_H 1
4861 EOF
4862
4863     
4864 fi
4865 rm -f conftest*
4866
4867   
4868 else
4869   echo "$ac_t""no" 1>&6
4870 fi
4871 done
4872
4873   CPPFLAGS="$save_CPPFLAGS"
4874 fi
4875
4876 echo $ac_n "checking for ntohl in sys/param.h""... $ac_c" 1>&6
4877 echo "configure:4878: checking for ntohl in sys/param.h" >&5
4878 if eval "test \"`echo '$''{'ac_cv_c_ntohl_sys_param_h'+set}'`\" = set"; then
4879   echo $ac_n "(cached) $ac_c" 1>&6
4880 else
4881   CFLAGS="${save_CFLAGS} -Wall -Werror"
4882      cat > conftest.$ac_ext <<EOF
4883 #line 4884 "configure"
4884 #include "confdefs.h"
4885 #include <sys/param.h>
4886 int main() {
4887 void foo() { int meuh; ntohl(meuh); }
4888 ; return 0; }
4889 EOF
4890 if { (eval echo configure:4891: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4891   rm -rf conftest*
4892   ac_cv_c_ntohl_sys_param_h=yes
4893 else
4894   echo "configure: failed program was:" >&5
4895   cat conftest.$ac_ext >&5
4896   rm -rf conftest*
4897   ac_cv_c_ntohl_sys_param_h=no
4898 fi
4899 rm -f conftest*
4900 fi
4901
4902 echo "$ac_t""$ac_cv_c_ntohl_sys_param_h" 1>&6
4903 if test x"$ac_cv_c_ntohl_sys_param_h" != x"no"; then
4904     cat >> confdefs.h <<\EOF
4905 #define NTOHL_IN_SYS_PARAM_H 1
4906 EOF
4907
4908 fi
4909
4910 echo $ac_n "checking if \$CC accepts -finline-limit""... $ac_c" 1>&6
4911 echo "configure:4912: checking if \$CC accepts -finline-limit" >&5
4912 if eval "test \"`echo '$''{'ac_cv_c_inline_limit'+set}'`\" = set"; then
4913   echo $ac_n "(cached) $ac_c" 1>&6
4914 else
4915   CFLAGS="${save_CFLAGS} -finline-limit-30000"
4916      cat > conftest.$ac_ext <<EOF
4917 #line 4918 "configure"
4918 #include "confdefs.h"
4919
4920 int main() {
4921
4922 ; return 0; }
4923 EOF
4924 if { (eval echo configure:4925: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4925   rm -rf conftest*
4926   ac_cv_c_inline_limit=yes
4927 else
4928   echo "configure: failed program was:" >&5
4929   cat conftest.$ac_ext >&5
4930   rm -rf conftest*
4931   ac_cv_c_inline_limit=no
4932 fi
4933 rm -f conftest*
4934 fi
4935
4936 echo "$ac_t""$ac_cv_c_inline_limit" 1>&6
4937 if test x"$ac_cv_c_inline_limit" != x"no"; then
4938     save_CFLAGS="${save_CFLAGS} -finline-limit-30000"
4939 fi
4940
4941 echo $ac_n "checking if \$CC accepts -Wall -Winline""... $ac_c" 1>&6
4942 echo "configure:4943: checking if \$CC accepts -Wall -Winline" >&5
4943 if eval "test \"`echo '$''{'ac_cv_c_Wall_Winline'+set}'`\" = set"; then
4944   echo $ac_n "(cached) $ac_c" 1>&6
4945 else
4946   CFLAGS="${save_CFLAGS} -Wall -Winline"
4947      cat > conftest.$ac_ext <<EOF
4948 #line 4949 "configure"
4949 #include "confdefs.h"
4950
4951 int main() {
4952
4953 ; return 0; }
4954 EOF
4955 if { (eval echo configure:4956: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4956   rm -rf conftest*
4957   ac_cv_c_Wall_Winline=yes
4958 else
4959   echo "configure: failed program was:" >&5
4960   cat conftest.$ac_ext >&5
4961   rm -rf conftest*
4962   ac_cv_c_Wall_Winline=no
4963 fi
4964 rm -f conftest*
4965 fi
4966
4967 echo "$ac_t""$ac_cv_c_Wall_Winline" 1>&6
4968 if test x"$ac_cv_c_Wall_Winline" != x"no"; then
4969     save_CFLAGS="${save_CFLAGS} -Wall -Winline"
4970 else
4971     echo $ac_n "checking if \$CC accepts -wall -winline""... $ac_c" 1>&6
4972 echo "configure:4973: checking if \$CC accepts -wall -winline" >&5
4973 if eval "test \"`echo '$''{'ac_cv_c_wall_winline'+set}'`\" = set"; then
4974   echo $ac_n "(cached) $ac_c" 1>&6
4975 else
4976   CFLAGS="${save_CFLAGS} -wall -winline"
4977          cat > conftest.$ac_ext <<EOF
4978 #line 4979 "configure"
4979 #include "confdefs.h"
4980
4981 int main() {
4982
4983 ; return 0; }
4984 EOF
4985 if { (eval echo configure:4986: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4986   rm -rf conftest*
4987   ac_cv_c_wall_winline=yes
4988 else
4989   echo "configure: failed program was:" >&5
4990   cat conftest.$ac_ext >&5
4991   rm -rf conftest*
4992   ac_cv_c_wall_winline=no
4993 fi
4994 rm -f conftest*
4995 fi
4996
4997 echo "$ac_t""$ac_cv_c_wall_winline" 1>&6
4998     if test x"$ac_cv_c_wall_winline" != x"no"; then
4999         save_CFLAGS="${save_CFLAGS} -wall -winline"
5000     fi
5001 fi
5002
5003 echo $ac_n "checking if \$CC accepts -pipe""... $ac_c" 1>&6
5004 echo "configure:5005: checking if \$CC accepts -pipe" >&5
5005 if eval "test \"`echo '$''{'ac_cv_c_pipe'+set}'`\" = set"; then
5006   echo $ac_n "(cached) $ac_c" 1>&6
5007 else
5008   CFLAGS="${save_CFLAGS} -pipe"
5009      cat > conftest.$ac_ext <<EOF
5010 #line 5011 "configure"
5011 #include "confdefs.h"
5012
5013 int main() {
5014
5015 ; return 0; }
5016 EOF
5017 if { (eval echo configure:5018: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5018   rm -rf conftest*
5019   ac_cv_c_pipe=yes
5020 else
5021   echo "configure: failed program was:" >&5
5022   cat conftest.$ac_ext >&5
5023   rm -rf conftest*
5024   ac_cv_c_pipe=no
5025 fi
5026 rm -f conftest*
5027 fi
5028
5029 echo "$ac_t""$ac_cv_c_pipe" 1>&6
5030 if test x"$ac_cv_c_pipe" != x"no"; then
5031     save_CFLAGS="${save_CFLAGS} -pipe"
5032 fi
5033
5034 echo $ac_n "checking if \$CC accepts -O3""... $ac_c" 1>&6
5035 echo "configure:5036: checking if \$CC accepts -O3" >&5
5036 if eval "test \"`echo '$''{'ac_cv_c_o3'+set}'`\" = set"; then
5037   echo $ac_n "(cached) $ac_c" 1>&6
5038 else
5039   CFLAGS="${save_CFLAGS} -O3"
5040      cat > conftest.$ac_ext <<EOF
5041 #line 5042 "configure"
5042 #include "confdefs.h"
5043
5044 int main() {
5045
5046 ; return 0; }
5047 EOF
5048 if { (eval echo configure:5049: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5049   rm -rf conftest*
5050   ac_cv_c_o3=yes
5051 else
5052   echo "configure: failed program was:" >&5
5053   cat conftest.$ac_ext >&5
5054   rm -rf conftest*
5055   ac_cv_c_o3=no
5056 fi
5057 rm -f conftest*
5058 fi
5059
5060 echo "$ac_t""$ac_cv_c_o3" 1>&6
5061 if test x"$ac_cv_c_o3" != x"no"; then
5062     CFLAGS_OPTIM="${CFLAGS_OPTIM} -O3"
5063 else
5064     echo $ac_n "checking if \$CC accepts -O2""... $ac_c" 1>&6
5065 echo "configure:5066: checking if \$CC accepts -O2" >&5
5066 if eval "test \"`echo '$''{'ac_cv_c_o2'+set}'`\" = set"; then
5067   echo $ac_n "(cached) $ac_c" 1>&6
5068 else
5069   CFLAGS="${save_CFLAGS} -O2"
5070          cat > conftest.$ac_ext <<EOF
5071 #line 5072 "configure"
5072 #include "confdefs.h"
5073
5074 int main() {
5075
5076 ; return 0; }
5077 EOF
5078 if { (eval echo configure:5079: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5079   rm -rf conftest*
5080   ac_cv_c_o2=yes
5081 else
5082   echo "configure: failed program was:" >&5
5083   cat conftest.$ac_ext >&5
5084   rm -rf conftest*
5085   ac_cv_c_o2=no
5086 fi
5087 rm -f conftest*
5088 fi
5089
5090 echo "$ac_t""$ac_cv_c_o2" 1>&6
5091     if test x"$ac_cv_c_o2" != x"no"; then
5092         CFLAGS_OPTIM="${CFLAGS_OPTIM} -O2"
5093     else
5094         echo $ac_n "checking if \$CC accepts -O""... $ac_c" 1>&6
5095 echo "configure:5096: checking if \$CC accepts -O" >&5
5096 if eval "test \"`echo '$''{'ac_cv_c_o'+set}'`\" = set"; then
5097   echo $ac_n "(cached) $ac_c" 1>&6
5098 else
5099   CFLAGS="${save_CFLAGS} -O"
5100              cat > conftest.$ac_ext <<EOF
5101 #line 5102 "configure"
5102 #include "confdefs.h"
5103
5104 int main() {
5105
5106 ; return 0; }
5107 EOF
5108 if { (eval echo configure:5109: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5109   rm -rf conftest*
5110   ac_cv_c_o=yes
5111 else
5112   echo "configure: failed program was:" >&5
5113   cat conftest.$ac_ext >&5
5114   rm -rf conftest*
5115   ac_cv_c_o=no
5116 fi
5117 rm -f conftest*
5118 fi
5119
5120 echo "$ac_t""$ac_cv_c_o" 1>&6
5121         if test x"$ac_cv_c_o" != x"no"; then
5122             CFLAGS_OPTIM="${CFLAGS_OPTIM} -O"
5123         fi
5124     fi
5125 fi
5126
5127 echo $ac_n "checking if \$CC accepts -ffast-math""... $ac_c" 1>&6
5128 echo "configure:5129: checking if \$CC accepts -ffast-math" >&5
5129 if eval "test \"`echo '$''{'ac_cv_c_fast_math'+set}'`\" = set"; then
5130   echo $ac_n "(cached) $ac_c" 1>&6
5131 else
5132   CFLAGS="${save_CFLAGS} -ffast-math"
5133      cat > conftest.$ac_ext <<EOF
5134 #line 5135 "configure"
5135 #include "confdefs.h"
5136
5137 int main() {
5138
5139 ; return 0; }
5140 EOF
5141 if { (eval echo configure:5142: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5142   rm -rf conftest*
5143   ac_cv_c_fast_math=yes
5144 else
5145   echo "configure: failed program was:" >&5
5146   cat conftest.$ac_ext >&5
5147   rm -rf conftest*
5148   ac_cv_c_fast_math=no
5149 fi
5150 rm -f conftest*
5151 fi
5152
5153 echo "$ac_t""$ac_cv_c_fast_math" 1>&6
5154 if test x"$ac_cv_c_fast_math" != x"no"; then
5155     CFLAGS_OPTIM="${CFLAGS_OPTIM} -ffast-math"
5156 fi
5157
5158 echo $ac_n "checking if \$CC accepts -funroll-loops""... $ac_c" 1>&6
5159 echo "configure:5160: checking if \$CC accepts -funroll-loops" >&5
5160 if eval "test \"`echo '$''{'ac_cv_c_unroll_loops'+set}'`\" = set"; then
5161   echo $ac_n "(cached) $ac_c" 1>&6
5162 else
5163   CFLAGS="${save_CFLAGS} -funroll-loops"
5164      cat > conftest.$ac_ext <<EOF
5165 #line 5166 "configure"
5166 #include "confdefs.h"
5167
5168 int main() {
5169
5170 ; return 0; }
5171 EOF
5172 if { (eval echo configure:5173: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5173   rm -rf conftest*
5174   ac_cv_c_unroll_loops=yes
5175 else
5176   echo "configure: failed program was:" >&5
5177   cat conftest.$ac_ext >&5
5178   rm -rf conftest*
5179   ac_cv_c_unroll_loops=no
5180 fi
5181 rm -f conftest*
5182 fi
5183
5184 echo "$ac_t""$ac_cv_c_unroll_loops" 1>&6
5185 if test x"$ac_cv_c_unroll_loops" != x"no"; then
5186     CFLAGS_OPTIM="${CFLAGS_OPTIM} -funroll-loops"
5187 fi
5188
5189 echo $ac_n "checking if \$CC accepts -fomit-frame-pointer""... $ac_c" 1>&6
5190 echo "configure:5191: checking if \$CC accepts -fomit-frame-pointer" >&5
5191 if eval "test \"`echo '$''{'ac_cv_c_omit_frame_pointer'+set}'`\" = set"; then
5192   echo $ac_n "(cached) $ac_c" 1>&6
5193 else
5194   CFLAGS="${save_CFLAGS} -fomit-frame-pointer"
5195      cat > conftest.$ac_ext <<EOF
5196 #line 5197 "configure"
5197 #include "confdefs.h"
5198
5199 int main() {
5200
5201 ; return 0; }
5202 EOF
5203 if { (eval echo configure:5204: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5204   rm -rf conftest*
5205   ac_cv_c_omit_frame_pointer=yes
5206 else
5207   echo "configure: failed program was:" >&5
5208   cat conftest.$ac_ext >&5
5209   rm -rf conftest*
5210   ac_cv_c_omit_frame_pointer=no
5211 fi
5212 rm -f conftest*
5213 fi
5214
5215 echo "$ac_t""$ac_cv_c_omit_frame_pointer" 1>&6
5216 if test x"$ac_cv_c_omit_frame_pointer" != x"no"; then
5217     CFLAGS_OPTIM_NODEBUG="${CFLAGS_OPTIM_NODEBUG} -fomit-frame-pointer"
5218 fi
5219
5220 echo $ac_n "checking if \$CC accepts -bundle -undefined error -lcc_dynamic""... $ac_c" 1>&6
5221 echo "configure:5222: checking if \$CC accepts -bundle -undefined error -lcc_dynamic" >&5
5222 if eval "test \"`echo '$''{'ac_cv_ld_darwin'+set}'`\" = set"; then
5223   echo $ac_n "(cached) $ac_c" 1>&6
5224 else
5225   CFLAGS="${save_CFLAGS} -bundle -undefined error -lcc_dynamic"
5226      cat > conftest.$ac_ext <<EOF
5227 #line 5228 "configure"
5228 #include "confdefs.h"
5229
5230 int main() {
5231
5232 ; return 0; }
5233 EOF
5234 if { (eval echo configure:5235: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5235   rm -rf conftest*
5236   ac_cv_ld_darwin=yes
5237 else
5238   echo "configure: failed program was:" >&5
5239   cat conftest.$ac_ext >&5
5240   rm -rf conftest*
5241   ac_cv_ld_darwin=no
5242 fi
5243 rm -f conftest*
5244 fi
5245
5246 echo "$ac_t""$ac_cv_ld_darwin" 1>&6
5247 if test x"$ac_cv_ld_darwin" != x"no"; then
5248     plugins_LDFLAGS="${plugins_LDFLAGS} -bundle -undefined error -lcc_dynamic"
5249 fi
5250
5251 echo $ac_n "checking if \$CC accepts -shared""... $ac_c" 1>&6
5252 echo "configure:5253: checking if \$CC accepts -shared" >&5
5253 if eval "test \"`echo '$''{'ac_cv_ld_plugins'+set}'`\" = set"; then
5254   echo $ac_n "(cached) $ac_c" 1>&6
5255 else
5256   CFLAGS="${save_CFLAGS} -shared"
5257      cat > conftest.$ac_ext <<EOF
5258 #line 5259 "configure"
5259 #include "confdefs.h"
5260
5261 int main() {
5262
5263 ; return 0; }
5264 EOF
5265 if { (eval echo configure:5266: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5266   rm -rf conftest*
5267   ac_cv_ld_plugins=yes
5268 else
5269   echo "configure: failed program was:" >&5
5270   cat conftest.$ac_ext >&5
5271   rm -rf conftest*
5272   ac_cv_ld_plugins=no
5273 fi
5274 rm -f conftest*
5275 fi
5276
5277 echo "$ac_t""$ac_cv_ld_plugins" 1>&6
5278 if test x"$ac_cv_ld_plugins" != x"no"; then
5279     plugins_LDFLAGS="${plugins_LDFLAGS} -shared"
5280 fi
5281         
5282 echo $ac_n "checking for variadic cpp macros""... $ac_c" 1>&6
5283 echo "configure:5284: checking for variadic cpp macros" >&5
5284 if eval "test \"`echo '$''{'ac_cv_cpp_variadic_macros'+set}'`\" = set"; then
5285   echo $ac_n "(cached) $ac_c" 1>&6
5286 else
5287   CFLAGS="${save_CFLAGS}"
5288      cat > conftest.$ac_ext <<EOF
5289 #line 5290 "configure"
5290 #include "confdefs.h"
5291 #include <stdio.h>
5292           #define a(b,c...) printf(b,##c)
5293 int main() {
5294 a("foo");a("%s","bar");a("%s%s","baz","quux");
5295 ; return 0; }
5296 EOF
5297 if { (eval echo configure:5298: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5298   rm -rf conftest*
5299   ac_cv_cpp_variadic_macros=yes
5300 else
5301   echo "configure: failed program was:" >&5
5302   cat conftest.$ac_ext >&5
5303   rm -rf conftest*
5304   ac_cv_cpp_variadic_macros=no
5305 fi
5306 rm -f conftest*
5307 fi
5308
5309 echo "$ac_t""$ac_cv_cpp_variadic_macros" 1>&6
5310 if test x"$ac_cv_cpp_variadic_macros" != x"no"; then
5311     cat >> confdefs.h <<\EOF
5312 #define HAVE_VARIADIC_MACROS 1
5313 EOF
5314
5315 fi
5316
5317 echo $ac_n "checking __attribute__ ((aligned ())) support""... $ac_c" 1>&6
5318 echo "configure:5319: checking __attribute__ ((aligned ())) support" >&5
5319 if eval "test \"`echo '$''{'ac_cv_c_attribute_aligned'+set}'`\" = set"; then
5320   echo $ac_n "(cached) $ac_c" 1>&6
5321 else
5322   ac_cv_c_attribute_aligned=0
5323         CFLAGS="${save_CFLAGS} -Werror"
5324     for ac_cv_c_attr_align_try in 2 4 8 16 32 64; do
5325         cat > conftest.$ac_ext <<EOF
5326 #line 5327 "configure"
5327 #include "confdefs.h"
5328
5329 int main() {
5330 static char c __attribute__ ((aligned($ac_cv_c_attr_align_try))) = 0; return c;
5331 ; return 0; }
5332 EOF
5333 if { (eval echo configure:5334: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5334   rm -rf conftest*
5335   ac_cv_c_attribute_aligned=$ac_cv_c_attr_align_try
5336 else
5337   echo "configure: failed program was:" >&5
5338   cat conftest.$ac_ext >&5
5339 fi
5340 rm -f conftest*
5341     done
5342 fi
5343
5344 echo "$ac_t""$ac_cv_c_attribute_aligned" 1>&6
5345 if test x"$ac_cv_c_attribute_aligned" != x"0"; then
5346     cat >> confdefs.h <<EOF
5347 #define ATTRIBUTE_ALIGNED_MAX $ac_cv_c_attribute_aligned
5348 EOF
5349
5350 fi
5351
5352 CFLAGS="${save_CFLAGS}"
5353 CPPFLAGS="${save_CPPFLAGS}"
5354 LDFLAGS="${save_LDFLAGS}"
5355
5356 echo $ac_n "checking for boolean_t in sys/types.h""... $ac_c" 1>&6
5357 echo "configure:5358: checking for boolean_t in sys/types.h" >&5
5358 if eval "test \"`echo '$''{'ac_cv_c_boolean_t_sys_types_h'+set}'`\" = set"; then
5359   echo $ac_n "(cached) $ac_c" 1>&6
5360 else
5361   cat > conftest.$ac_ext <<EOF
5362 #line 5363 "configure"
5363 #include "confdefs.h"
5364 #include <sys/types.h>
5365 int main() {
5366 boolean_t foo;
5367 ; return 0; }
5368 EOF
5369 if { (eval echo configure:5370: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5370   rm -rf conftest*
5371   ac_cv_c_boolean_t_sys_types_h=yes
5372 else
5373   echo "configure: failed program was:" >&5
5374   cat conftest.$ac_ext >&5
5375   rm -rf conftest*
5376   ac_cv_c_boolean_t_sys_types_h=no
5377 fi
5378 rm -f conftest*
5379 fi
5380
5381 echo "$ac_t""$ac_cv_c_boolean_t_sys_types_h" 1>&6
5382 if test x"$ac_cv_c_boolean_t_sys_types_h" != x"no"; then
5383     cat >> confdefs.h <<\EOF
5384 #define BOOLEAN_T_IN_SYS_TYPES_H 1
5385 EOF
5386
5387 fi
5388
5389 echo $ac_n "checking for boolean_t in pthread.h""... $ac_c" 1>&6
5390 echo "configure:5391: checking for boolean_t in pthread.h" >&5
5391 if eval "test \"`echo '$''{'ac_cv_c_boolean_t_pthread_h'+set}'`\" = set"; then
5392   echo $ac_n "(cached) $ac_c" 1>&6
5393 else
5394   cat > conftest.$ac_ext <<EOF
5395 #line 5396 "configure"
5396 #include "confdefs.h"
5397 #include <pthread.h>
5398 int main() {
5399 boolean_t foo;
5400 ; return 0; }
5401 EOF
5402 if { (eval echo configure:5403: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5403   rm -rf conftest*
5404   ac_cv_c_boolean_t_pthread_h=yes
5405 else
5406   echo "configure: failed program was:" >&5
5407   cat conftest.$ac_ext >&5
5408   rm -rf conftest*
5409   ac_cv_c_boolean_t_pthread_h=no
5410 fi
5411 rm -f conftest*
5412 fi
5413
5414 echo "$ac_t""$ac_cv_c_boolean_t_pthread_h" 1>&6
5415 if test x"$ac_cv_c_boolean_t_pthread_h" != x"no"; then
5416     cat >> confdefs.h <<\EOF
5417 #define BOOLEAN_T_IN_PTHREAD_H 1
5418 EOF
5419
5420 fi
5421
5422 echo $ac_n "checking for boolean_t in cthreads.h""... $ac_c" 1>&6
5423 echo "configure:5424: checking for boolean_t in cthreads.h" >&5
5424 if eval "test \"`echo '$''{'ac_cv_c_boolean_t_cthreads_h'+set}'`\" = set"; then
5425   echo $ac_n "(cached) $ac_c" 1>&6
5426 else
5427   cat > conftest.$ac_ext <<EOF
5428 #line 5429 "configure"
5429 #include "confdefs.h"
5430 #include <cthreads.h>
5431 int main() {
5432 boolean_t foo;
5433 ; return 0; }
5434 EOF
5435 if { (eval echo configure:5436: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5436   rm -rf conftest*
5437   ac_cv_c_boolean_t_cthreads_h=yes
5438 else
5439   echo "configure: failed program was:" >&5
5440   cat conftest.$ac_ext >&5
5441   rm -rf conftest*
5442   ac_cv_c_boolean_t_cthreads_h=no
5443 fi
5444 rm -f conftest*
5445 fi
5446
5447 echo "$ac_t""$ac_cv_c_boolean_t_cthreads_h" 1>&6
5448 if test x"$ac_cv_c_boolean_t_cthreads_h" != x"no"; then
5449     cat >> confdefs.h <<\EOF
5450 #define BOOLEAN_T_IN_CTHREADS_H 1
5451 EOF
5452
5453 fi
5454
5455 case x"${target_cpu}" in
5456   x)
5457     ARCH=unknown
5458     ;;
5459   *)
5460     ARCH="${target_cpu}"
5461     ;;
5462 esac
5463
5464 BUILTINS="${BUILTINS} idct idctclassic motion imdct downmix chroma_i420_rgb chroma_i420_yuy2 chroma_i422_yuy2 chroma_i420_ymga mpeg_adec ac3_adec mpeg_vdec"
5465 PLUGINS="${PLUGINS} dummy null rc logger mpeg_es mpeg_ps mpeg_ts mpeg_audio file udp http ipv4 memcpy lpcm_adec ac3_spdif spudec filter_deinterlace filter_invert filter_wall filter_transform filter_distort filter_clone fx_scope"
5466
5467 MMX_MODULES="memcpymmx idctmmx motionmmx chroma_i420_rgb_mmx chroma_i420_yuy2_mmx chroma_i422_yuy2_mmx chroma_i420_ymga_mmx"
5468 MMXEXT_MODULES="memcpymmxext idctmmxext motionmmxext"
5469 THREEDNOW_MODULES="memcpy3dn imdct3dn downmix3dn"
5470 SSE_MODULES="imdctsse downmixsse"
5471 ALTIVEC_MODULES="idctaltivec motionaltivec memcpyaltivec"
5472
5473 echo $ac_n "checking if \$CC groks MMX inline assembly""... $ac_c" 1>&6
5474 echo "configure:5475: checking if \$CC groks MMX inline assembly" >&5
5475 if eval "test \"`echo '$''{'ac_cv_mmx_inline'+set}'`\" = set"; then
5476   echo $ac_n "(cached) $ac_c" 1>&6
5477 else
5478   cat > conftest.$ac_ext <<EOF
5479 #line 5480 "configure"
5480 #include "confdefs.h"
5481
5482 int main() {
5483 void *p;asm volatile("packuswb %%mm1,%%mm2"::"r"(p));
5484 ; return 0; }
5485 EOF
5486 if { (eval echo configure:5487: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5487   rm -rf conftest*
5488   ac_cv_mmx_inline=yes
5489 else
5490   echo "configure: failed program was:" >&5
5491   cat conftest.$ac_ext >&5
5492   rm -rf conftest*
5493   ac_cv_mmx_inline=no
5494 fi
5495 rm -f conftest*
5496 fi
5497
5498 echo "$ac_t""$ac_cv_mmx_inline" 1>&6
5499 if test x"$ac_cv_mmx_inline" != x"no"; then
5500   ACCEL_MODULES="${ACCEL_MODULES} ${MMX_MODULES}"
5501 fi
5502
5503 echo $ac_n "checking if \$CC groks MMX EXT inline assembly""... $ac_c" 1>&6
5504 echo "configure:5505: checking if \$CC groks MMX EXT inline assembly" >&5
5505 if eval "test \"`echo '$''{'ac_cv_mmxext_inline'+set}'`\" = set"; then
5506   echo $ac_n "(cached) $ac_c" 1>&6
5507 else
5508   cat > conftest.$ac_ext <<EOF
5509 #line 5510 "configure"
5510 #include "confdefs.h"
5511
5512 int main() {
5513 void *p;asm volatile("maskmovq %%mm1,%%mm2"::"r"(p));
5514 ; return 0; }
5515 EOF
5516 if { (eval echo configure:5517: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5517   rm -rf conftest*
5518   ac_cv_mmxext_inline=yes
5519 else
5520   echo "configure: failed program was:" >&5
5521   cat conftest.$ac_ext >&5
5522   rm -rf conftest*
5523   ac_cv_mmxext_inline=no
5524 fi
5525 rm -f conftest*
5526 fi
5527
5528 echo "$ac_t""$ac_cv_mmxext_inline" 1>&6
5529 if test x"$ac_cv_mmxext_inline" != x"no"; then
5530   ACCEL_MODULES="${ACCEL_MODULES} ${MMXEXT_MODULES}"
5531 fi
5532
5533 echo $ac_n "checking if \$CC groks 3D Now! inline assembly""... $ac_c" 1>&6
5534 echo "configure:5535: checking if \$CC groks 3D Now! inline assembly" >&5
5535 if eval "test \"`echo '$''{'ac_cv_3dnow_inline'+set}'`\" = set"; then
5536   echo $ac_n "(cached) $ac_c" 1>&6
5537 else
5538   cat > conftest.$ac_ext <<EOF
5539 #line 5540 "configure"
5540 #include "confdefs.h"
5541
5542 int main() {
5543 void *p;asm volatile("pfadd %%mm1,%%mm2"::"r"(p));
5544 ; return 0; }
5545 EOF
5546 if { (eval echo configure:5547: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5547   rm -rf conftest*
5548   ac_cv_3dnow_inline=yes
5549 else
5550   echo "configure: failed program was:" >&5
5551   cat conftest.$ac_ext >&5
5552   rm -rf conftest*
5553   ac_cv_3dnow_inline=no
5554 fi
5555 rm -f conftest*
5556 fi
5557
5558 echo "$ac_t""$ac_cv_3dnow_inline" 1>&6
5559 if test x"$ac_cv_3dnow_inline" != x"no"; then
5560   cat >> confdefs.h <<\EOF
5561 #define CAN_COMPILE_3DNOW 1
5562 EOF
5563
5564   ACCEL_MODULES="${ACCEL_MODULES} ${THREEDNOW_MODULES}"
5565 fi
5566
5567 echo $ac_n "checking if \$CC groks SSE inline assembly""... $ac_c" 1>&6
5568 echo "configure:5569: checking if \$CC groks SSE inline assembly" >&5
5569 if eval "test \"`echo '$''{'ac_cv_sse_inline'+set}'`\" = set"; then
5570   echo $ac_n "(cached) $ac_c" 1>&6
5571 else
5572   cat > conftest.$ac_ext <<EOF
5573 #line 5574 "configure"
5574 #include "confdefs.h"
5575
5576 int main() {
5577 void *p;asm volatile("xorps %%xmm1,%%xmm2"::"r"(p));
5578 ; return 0; }
5579 EOF
5580 if { (eval echo configure:5581: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5581   rm -rf conftest*
5582   ac_cv_sse_inline=yes
5583 else
5584   echo "configure: failed program was:" >&5
5585   cat conftest.$ac_ext >&5
5586   rm -rf conftest*
5587   ac_cv_sse_inline=no
5588 fi
5589 rm -f conftest*
5590 fi
5591
5592 echo "$ac_t""$ac_cv_sse_inline" 1>&6
5593 if test x"$ac_cv_sse_inline" != x"no" -a x$SYS != xmingw32; then
5594   cat >> confdefs.h <<\EOF
5595 #define CAN_COMPILE_SSE 1
5596 EOF
5597
5598   ACCEL_MODULES="${ACCEL_MODULES} ${SSE_MODULES}"
5599 fi
5600
5601 # don't try to grok altivec with native mingw32 it doesn't work right now
5602 # we should be able to remove this test with future versions of mingw32
5603 if test x$SYS != xmingw32; then
5604 echo $ac_n "checking if \$CC groks Altivec inline assembly""... $ac_c" 1>&6
5605 echo "configure:5606: checking if \$CC groks Altivec inline assembly" >&5
5606 if eval "test \"`echo '$''{'ac_cv_altivec_inline'+set}'`\" = set"; then
5607   echo $ac_n "(cached) $ac_c" 1>&6
5608 else
5609   cat > conftest.$ac_ext <<EOF
5610 #line 5611 "configure"
5611 #include "confdefs.h"
5612
5613 int main() {
5614 asm volatile("vperm 0,1,2,3");
5615 ; return 0; }
5616 EOF
5617 if { (eval echo configure:5618: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5618   rm -rf conftest*
5619   ac_cv_altivec_inline=yes
5620 else
5621   echo "configure: failed program was:" >&5
5622   cat conftest.$ac_ext >&5
5623   rm -rf conftest*
5624   save_CFLAGS=$CFLAGS
5625           CFLAGS="$CFLAGS -Wa,-m7400"
5626           cat > conftest.$ac_ext <<EOF
5627 #line 5628 "configure"
5628 #include "confdefs.h"
5629
5630 int main() {
5631 asm volatile("vperm 0,1,2,3");
5632 ; return 0; }
5633 EOF
5634 if { (eval echo configure:5635: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5635   rm -rf conftest*
5636   ac_cv_altivec_inline="-Wa,-m7400"
5637 else
5638   echo "configure: failed program was:" >&5
5639   cat conftest.$ac_ext >&5
5640   rm -rf conftest*
5641   ac_cv_altivec_inline=no
5642 fi
5643 rm -f conftest*
5644           CFLAGS=$save_CFLAGS
5645          
5646 fi
5647 rm -f conftest*
5648 fi
5649
5650 echo "$ac_t""$ac_cv_altivec_inline" 1>&6
5651 if test x"$ac_cv_altivec_inline" != x"no"; then
5652   cat >> confdefs.h <<\EOF
5653 #define CAN_COMPILE_ALTIVEC 1
5654 EOF
5655
5656   if test x"$ac_cv_altivec_inline" != x"yes"; then
5657     idctaltivec_CFLAGS="$idctaltivec_CFLAGS $ac_cv_altivec_inline"
5658     motionaltivec_CFLAGS="$motionaltivec_CFLAGS $ac_cv_altivec_inline"
5659     memcpyaltivec_CFLAGS="$memcpyaltivec_CFLAGS $ac_cv_altivec_inline"
5660     vlc_CFLAGS="$vlc_CFLAGS $ac_cv_altivec_inline"
5661   fi
5662   ACCEL_MODULES="${ACCEL_MODULES} ${ALTIVEC_MODULES}"
5663 fi
5664
5665 echo $ac_n "checking if \$CC groks Altivec C extensions""... $ac_c" 1>&6
5666 echo "configure:5667: checking if \$CC groks Altivec C extensions" >&5
5667 if eval "test \"`echo '$''{'ac_cv_c_altivec'+set}'`\" = set"; then
5668   echo $ac_n "(cached) $ac_c" 1>&6
5669 else
5670   save_CFLAGS=$CFLAGS
5671      CFLAGS="$CFLAGS -faltivec"
5672      # Darwin test
5673      cat > conftest.$ac_ext <<EOF
5674 #line 5675 "configure"
5675 #include "confdefs.h"
5676
5677 int main() {
5678 vec_mtvscr((vector unsigned int)(0));
5679 ; return 0; }
5680 EOF
5681 if { (eval echo configure:5682: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5682   rm -rf conftest*
5683   ac_cv_c_altivec=-faltivec
5684 else
5685   echo "configure: failed program was:" >&5
5686   cat conftest.$ac_ext >&5
5687   rm -rf conftest*
5688   
5689         # Linux/PPC test
5690         CFLAGS="$save_CFLAGS $idctaltivec_CFLAGS -fvec"
5691         cat > conftest.$ac_ext <<EOF
5692 #line 5693 "configure"
5693 #include "confdefs.h"
5694
5695 int main() {
5696 vec_mtvscr((vector unsigned int)(0));
5697 ; return 0; }
5698 EOF
5699 if { (eval echo configure:5700: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5700   rm -rf conftest*
5701   ac_cv_c_altivec="-fvec"
5702 else
5703   echo "configure: failed program was:" >&5
5704   cat conftest.$ac_ext >&5
5705   rm -rf conftest*
5706   ac_cv_c_altivec=no
5707 fi
5708 rm -f conftest*
5709         
5710 fi
5711 rm -f conftest*
5712      CFLAGS=$save_CFLAGS
5713     
5714 fi
5715
5716 echo "$ac_t""$ac_cv_c_altivec" 1>&6
5717 if test x"$ac_cv_c_altivec" != x"no"; then
5718   cat >> confdefs.h <<\EOF
5719 #define CAN_COMPILE_C_ALTIVEC 1
5720 EOF
5721
5722   idctaltivec_CFLAGS="$idctaltivec_CFLAGS $ac_cv_c_altivec"
5723   motionaltivec_CFLAGS="$motionaltivec_CFLAGS $ac_cv_c_altivec"
5724   memcpyaltivec_CFLAGS="$memcpyaltivec_CFLAGS $ac_cv_c_altivec"
5725   vlc_CFLAGS="$vlc_CFLAGS $ac_cv_c_altivec"
5726   ACCEL_MODULES="${ACCEL_MODULES} ${ALTIVEC_MODULES}"
5727 fi
5728
5729 echo $ac_n "checking if linker needs -framework vecLib""... $ac_c" 1>&6
5730 echo "configure:5731: checking if linker needs -framework vecLib" >&5
5731 if eval "test \"`echo '$''{'ac_cv_ld_altivec'+set}'`\" = set"; then
5732   echo $ac_n "(cached) $ac_c" 1>&6
5733 else
5734   save_LDFLAGS=$LDFLAGS
5735      LDFLAGS="$LDFLAGS -framework vecLib"
5736      cat > conftest.$ac_ext <<EOF
5737 #line 5738 "configure"
5738 #include "confdefs.h"
5739
5740 int main() {
5741
5742 ; return 0; }
5743 EOF
5744 if { (eval echo configure:5745: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5745   rm -rf conftest*
5746   ac_cv_ld_altivec=yes
5747 else
5748   echo "configure: failed program was:" >&5
5749   cat conftest.$ac_ext >&5
5750   rm -rf conftest*
5751   ac_cv_ld_altivec=no
5752 fi
5753 rm -f conftest*
5754      LDFLAGS=$save_LDFLAGS
5755     
5756 fi
5757
5758 echo "$ac_t""$ac_cv_ld_altivec" 1>&6
5759 if test x"$ac_cv_ld_altivec" != x"no"; then
5760   idctaltivec_LDFLAGS="${idctaltivec_LDFLAGS} -framework vecLib"
5761   motionaltivec_LDFLAGS="${motionaltivec_LDFLAGS} -framework vecLib"
5762   memcpyaltivec_LDFLAGS="${memcpyaltivec_LDFLAGS} -framework vecLib"
5763   vlc_LDFLAGS="${vlc_LDFLAGS} -framework vecLib"
5764 fi
5765 fi # end if mingw32
5766
5767
5768 # Check whether --with- or --without- was given.
5769 if test "${with_+set}" = set; then
5770   withval="$with_"
5771   :
5772 fi
5773
5774 # Check whether --with- or --without- was given.
5775 if test "${with_+set}" = set; then
5776   withval="$with_"
5777   :
5778 fi
5779
5780
5781 # Check whether --with-tuning or --without-tuning was given.
5782 if test "${with_tuning+set}" = set; then
5783   withval="$with_tuning"
5784   :
5785 fi
5786
5787 if test "x$with_tuning" != "x"; then
5788     TUNING="$with_tuning"
5789 else
5790     if test x${target_cpu} = xi686 -o x${target_cpu} = xi586 -o x${target_cpu} = xi486 -o x${target_cpu} = xi386; then TUNING="pentiumpro"
5791     else
5792         if test x${target_cpu} = xpowerpc; then TUNING="750"; fi
5793     fi
5794 fi
5795
5796 if test x${target_cpu} = xi686 -o x${target_cpu} = xi586 -o x${target_cpu} = xx86 -o x${target_cpu} = xi386
5797 then
5798     ARCH="${ARCH} mmx"
5799     BUILTINS="${BUILTINS} ${ACCEL_MODULES}"
5800 fi
5801
5802 # Check whether --enable-optimizations or --disable-optimizations was given.
5803 if test "${enable_optimizations+set}" = set; then
5804   enableval="$enable_optimizations"
5805    if test x$enable_optimizations = xno; then OPTIMS=0; fi 
5806 else
5807    OPTIMS=1 
5808 fi
5809
5810
5811 # Check whether --enable-altivec or --disable-altivec was given.
5812 if test "${enable_altivec+set}" = set; then
5813   enableval="$enable_altivec"
5814    if test x$enable_altivec = xyes; then ARCH="${ARCH} altivec";
5815     BUILTINS="${BUILTINS} ${ACCEL_MODULES}"; fi 
5816 else
5817    if test x${target_cpu} = xpowerpc; then ARCH="${ARCH} altivec";
5818     BUILTINS="${BUILTINS} ${ACCEL_MODULES}"; fi 
5819 fi
5820
5821
5822 DEBUG=0
5823 # Check whether --enable-debug or --disable-debug was given.
5824 if test "${enable_debug+set}" = set; then
5825   enableval="$enable_debug"
5826    if test x$enable_debug = xyes; then DEBUG=1; fi 
5827 fi
5828
5829
5830 RELEASE=0
5831 # Check whether --enable-release or --disable-release was given.
5832 if test "${enable_release+set}" = set; then
5833   enableval="$enable_release"
5834    if test x$enable_release = xyes; then RELEASE=1; fi 
5835 else
5836    VERSION="${VERSION}_`date +%Y-%m-%d`" 
5837 fi
5838
5839
5840
5841 # Check whether --with- or --without- was given.
5842 if test "${with_+set}" = set; then
5843   withval="$with_"
5844   :
5845 fi
5846
5847
5848 # Check whether --enable-dvd or --disable-dvd was given.
5849 if test "${enable_dvd+set}" = set; then
5850   enableval="$enable_dvd"
5851   :
5852 fi
5853
5854 if test "x$enable_dvd" != "xno"
5855 then
5856   # Check whether --with-dvdcss or --without-dvdcss was given.
5857 if test "${with_dvdcss+set}" = set; then
5858   withval="$with_dvdcss"
5859   :
5860 fi
5861
5862   # Check whether --with-dvdcss-tree or --without-dvdcss-tree was given.
5863 if test "${with_dvdcss_tree+set}" = set; then
5864   withval="$with_dvdcss_tree"
5865   :
5866 fi
5867
5868   case "x$with_dvdcss" in
5869   x|xyes)
5870     if test "x$with_dvdcss_tree" = x
5871     then
5872       for ac_hdr in dvdcss/dvdcss.h
5873 do
5874 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5875 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5876 echo "configure:5877: checking for $ac_hdr" >&5
5877 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5878   echo $ac_n "(cached) $ac_c" 1>&6
5879 else
5880   cat > conftest.$ac_ext <<EOF
5881 #line 5882 "configure"
5882 #include "confdefs.h"
5883 #include <$ac_hdr>
5884 EOF
5885 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5886 { (eval echo configure:5887: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5887 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5888 if test -z "$ac_err"; then
5889   rm -rf conftest*
5890   eval "ac_cv_header_$ac_safe=yes"
5891 else
5892   echo "$ac_err" >&5
5893   echo "configure: failed program was:" >&5
5894   cat conftest.$ac_ext >&5
5895   rm -rf conftest*
5896   eval "ac_cv_header_$ac_safe=no"
5897 fi
5898 rm -f conftest*
5899 fi
5900 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5901   echo "$ac_t""yes" 1>&6
5902     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5903   cat >> confdefs.h <<EOF
5904 #define $ac_tr_hdr 1
5905 EOF
5906   PLUGINS="${PLUGINS} dvd"
5907           dvd_LDFLAGS="${dvd_LDFLAGS} -ldvdcss" 
5908 else
5909   echo "$ac_t""no" 1>&6
5910 echo "configure: warning: libdvdcss is no longer provided with vlc; please get libdvdcss from http://www.videolan.org/libdvdcss/ and build it. Then either use --with-dvdcss=<path/where/libdvdcss/was/installed> for dynamic linking (recommended under Unix) or --with-dvdcss-tree=<path/where/libdvdcss/was/built> for static linking (recommended under BeOS, Windows, MacOS X). Alternatively you can use --disable-dvd to disable the DVD plugin." 1>&2
5911           { echo "configure: error: cannot find libdvdcss headers" 1>&2; exit 1; } 
5912 fi
5913 done
5914
5915     else
5916       echo $ac_n "checking for libdvdcss.a in ${with_dvdcss_tree}""... $ac_c" 1>&6
5917 echo "configure:5918: checking for libdvdcss.a in ${with_dvdcss_tree}" >&5
5918       real_dvdcss_tree="`cd ${with_dvdcss_tree} 2>/dev/null && pwd`"
5919       if test "x$real_dvdcss_tree" = x
5920       then
5921                 echo "$ac_t""no" 1>&6
5922         { echo "configure: error: cannot cd to ${with_dvdcss_tree}" 1>&2; exit 1; }
5923       fi
5924       if test -f "${real_dvdcss_tree}/src/.libs/libdvdcss.a"
5925       then
5926                 echo "$ac_t""${real_dvdcss_tree}/src/.libs/libdvdcss.a" 1>&6
5927         BUILTINS="${BUILTINS} dvd"
5928         dvd_LDFLAGS="${dvd_LDFLAGS} ${real_dvdcss_tree}/src/.libs/libdvdcss.a"
5929         dvd_CFLAGS="${dvd_CFLAGS} -I${real_dvdcss_tree}/src"
5930       else
5931                 echo "$ac_t""no" 1>&6
5932         { echo "configure: error: cannot find ${real_dvdcss_tree}/src/.libs/libdvdcss.a, make sure you compiled libdvdcss in ${with_dvdcss_tree}" 1>&2; exit 1; }
5933       fi
5934     fi
5935   ;;
5936   xno)
5937         PLUGINS="${PLUGINS} dvd"
5938     dvd_CFLAGS="${dvd_CFLAGS} -DGOD_DAMN_DMCA"
5939     dvd_LDFLAGS="${dvd_LDFLAGS} -ldl"
5940   ;;
5941   *)
5942     echo $ac_n "checking for dvdcss headers in ${with_dvdcss}""... $ac_c" 1>&6
5943 echo "configure:5944: checking for dvdcss headers in ${with_dvdcss}" >&5
5944     if test -f ${with_dvdcss}/include/dvdcss/dvdcss.h
5945     then
5946             echo "$ac_t""yes" 1>&6
5947       PLUGINS="${PLUGINS} dvd"
5948       dvd_LDFLAGS="${dvd_LDFLAGS} -L${with_dvdcss}/lib -ldvdcss"
5949       dvd_CFLAGS="${dvd_CFLAGS} -I${with_dvdcss}/include"
5950     else
5951             echo "$ac_t""no" 1>&6
5952       { echo "configure: error: cannot find ${with_dvdcss}/include/dvdcss/dvdcss.h" 1>&2; exit 1; }
5953     fi
5954   ;;
5955   esac
5956 fi
5957
5958 # Check whether --enable-dvdread or --disable-dvdread was given.
5959 if test "${enable_dvdread+set}" = set; then
5960   enableval="$enable_dvdread"
5961   :
5962 fi
5963
5964 if test "x$enable_dvdread" != "xno"
5965 then
5966   # Check whether --with-dvdread or --without-dvdread was given.
5967 if test "${with_dvdread+set}" = set; then
5968   withval="$with_dvdread"
5969   :
5970 fi
5971
5972   if test "x$with_dvdread" = x
5973   then
5974     test_LDFLAGS=""
5975     test_CFLAGS=""
5976   else
5977     test_LDFLAGS="-L${with_dvdread}/lib"
5978     test_CFLAGS="-I${with_dvdread}/include"
5979   fi
5980   CPPFLAGS="$save_CPPFLAGS $test_CFLAGS"
5981   for ac_hdr in dvdread/dvd_reader.h
5982 do
5983 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5984 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5985 echo "configure:5986: checking for $ac_hdr" >&5
5986 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5987   echo $ac_n "(cached) $ac_c" 1>&6
5988 else
5989   cat > conftest.$ac_ext <<EOF
5990 #line 5991 "configure"
5991 #include "confdefs.h"
5992 #include <$ac_hdr>
5993 EOF
5994 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5995 { (eval echo configure:5996: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5996 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5997 if test -z "$ac_err"; then
5998   rm -rf conftest*
5999   eval "ac_cv_header_$ac_safe=yes"
6000 else
6001   echo "$ac_err" >&5
6002   echo "configure: failed program was:" >&5
6003   cat conftest.$ac_ext >&5
6004   rm -rf conftest*
6005   eval "ac_cv_header_$ac_safe=no"
6006 fi
6007 rm -f conftest*
6008 fi
6009 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6010   echo "$ac_t""yes" 1>&6
6011     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6012   cat >> confdefs.h <<EOF
6013 #define $ac_tr_hdr 1
6014 EOF
6015  
6016      cat > conftest.$ac_ext <<EOF
6017 #line 6018 "configure"
6018 #include "confdefs.h"
6019 #include <dvdread/dvd_reader.h>
6020 int main() {
6021 void foo() { int i=DVD_VIDEO_LB_LEN; }
6022 ; return 0; }
6023 EOF
6024 if { (eval echo configure:6025: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6025   rm -rf conftest*
6026   
6027           PLUGINS="${PLUGINS} dvdread"
6028           dvdread_LDFLAGS="${dvdread_LDFLAGS} ${test_LDFLAGS} -ldvdread"
6029           dvdread_CFLAGS="${dvdread_CFLAGS} ${test_CFLAGS}"
6030         
6031 else
6032   echo "configure: failed program was:" >&5
6033   cat conftest.$ac_ext >&5
6034   rm -rf conftest*
6035   
6036           if test "x$enable_dvdread" != x
6037           then
6038             { echo "configure: error: Cannot find DVD_VIDEO_LB_LEN in dvdread/dvd_reader.h, please install libdvdread version 0.9.2 or later" 1>&2; exit 1; }
6039           fi
6040         
6041 fi
6042 rm -f conftest*
6043   
6044 else
6045   echo "$ac_t""no" 1>&6
6046 if test "x$enable_dvdread" != x
6047     then
6048       if test "x$with_dvdread" != x
6049       then
6050         { echo "configure: error: Cannot find dvdread/dvd_reader.h in ${with_dvdread}/include" 1>&2; exit 1; }
6051       else
6052         { echo "configure: error: Cannot find dvdread/dvd_reader.h" 1>&2; exit 1; }
6053       fi
6054     fi
6055   
6056 fi
6057 done
6058
6059   CPPFLAGS="$save_CPPFLAGS"
6060 fi
6061
6062 # Check whether --enable-dvbpsi or --disable-dvbpsi was given.
6063 if test "${enable_dvbpsi+set}" = set; then
6064   enableval="$enable_dvbpsi"
6065   :
6066 fi
6067
6068 if test "x$enable_dvbpsi" != "xno"
6069 then
6070   # Check whether --with-dvbpsi or --without-dvbpsi was given.
6071 if test "${with_dvbpsi+set}" = set; then
6072   withval="$with_dvbpsi"
6073   :
6074 fi
6075
6076   if test "x$with_dvbpsi" = x
6077   then
6078     test_LDFLAGS=""
6079     test_CFLAGS=""
6080   else
6081     test_LDFLAGS="-L${with_dvbpsi}/lib"
6082     test_CFLAGS="-I${with_dvbpsi}/include"
6083   fi
6084   CPPFLAGS="$save_CPPFLAGS $test_CFLAGS"
6085   ac_safe=`echo "dvbpsi/dr.h" | sed 'y%./+-%__p_%'`
6086 echo $ac_n "checking for dvbpsi/dr.h""... $ac_c" 1>&6
6087 echo "configure:6088: checking for dvbpsi/dr.h" >&5
6088 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
6089   echo $ac_n "(cached) $ac_c" 1>&6
6090 else
6091   cat > conftest.$ac_ext <<EOF
6092 #line 6093 "configure"
6093 #include "confdefs.h"
6094 #include <dvbpsi/dr.h>
6095 EOF
6096 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6097 { (eval echo configure:6098: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6098 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6099 if test -z "$ac_err"; then
6100   rm -rf conftest*
6101   eval "ac_cv_header_$ac_safe=yes"
6102 else
6103   echo "$ac_err" >&5
6104   echo "configure: failed program was:" >&5
6105   cat conftest.$ac_ext >&5
6106   rm -rf conftest*
6107   eval "ac_cv_header_$ac_safe=no"
6108 fi
6109 rm -f conftest*
6110 fi
6111 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6112   echo "$ac_t""yes" 1>&6
6113   
6114     PLUGINS="${PLUGINS} mpeg_ts_dvbpsi"
6115     mpeg_ts_dvbpsi_LDFLAGS="${mpeg_ts_dvbpsi_LDFLAGS} ${test_LDFLAGS} -ldvbpsi"
6116     mpeg_ts_dvbpsi_CFLAGS="${mpeg_ts_dvbpsi_CFLAGS} ${test_CFLAGS}"
6117     
6118 else
6119   echo "$ac_t""no" 1>&6
6120
6121     if test "x$enable_dvbpsi" != x
6122     then
6123       { echo "configure: error: Could not find libdvbpsi on your system: you may get it from www.videolan.org, you'll need at least version 0.1.1" 1>&2; exit 1; }
6124     fi
6125   
6126 fi
6127
6128   CPPFLAGS="$save_CPPFLAGS"
6129 fi
6130  
6131 # Check whether --enable-vcd or --disable-vcd was given.
6132 if test "${enable_vcd+set}" = set; then
6133   enableval="$enable_vcd"
6134   :
6135 fi
6136
6137
6138 if test x$enable_vcd != xno
6139 then
6140   cat > conftest.$ac_ext <<EOF
6141 #line 6142 "configure"
6142 #include "confdefs.h"
6143 #include <linux/cdrom.h>
6144 EOF
6145 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6146   egrep "cdrom_msf0" >/dev/null 2>&1; then
6147   rm -rf conftest*
6148   
6149     PLUGINS="${PLUGINS} vcd"
6150   
6151 fi
6152 rm -f conftest*
6153
6154   
6155   cat > conftest.$ac_ext <<EOF
6156 #line 6157 "configure"
6157 #include "confdefs.h"
6158 #include <sys/cdio.h>
6159 EOF
6160 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6161   egrep "ioc_toc_header " >/dev/null 2>&1; then
6162   rm -rf conftest*
6163   
6164     PLUGINS="${PLUGINS} vcd"
6165     cat >> confdefs.h <<\EOF
6166 #define HAVE_IOC_TOC_HEADER_IN_SYS_CDIO_H 1
6167 EOF
6168
6169   
6170 fi
6171 rm -f conftest*
6172
6173   
6174   if test "x${SYS}" = "xbsdi"
6175   then
6176     PLUGINS="${PLUGINS} vcd"
6177   fi
6178
6179   if test "x${SYS}" = "xdarwin"
6180   then
6181     # No need to add vcd to PLUGINS, Darwin is already based on FreeBSD
6182     vcd_LDFLAGS="${vcd_LDFLAGS} -framework IOKit -framework CoreFoundation" 
6183   fi
6184 fi
6185
6186 # Check whether --enable-satellite or --disable-satellite was given.
6187 if test "${enable_satellite+set}" = set; then
6188   enableval="$enable_satellite"
6189    if test x$enable_satellite = xyes
6190     then
6191       PLUGINS="${PLUGINS} satellite"
6192     fi
6193 fi
6194
6195
6196 if test x$SYS != xnto
6197 then
6198   echo $ac_n "checking for inet_pton""... $ac_c" 1>&6
6199 echo "configure:6200: checking for inet_pton" >&5
6200 if eval "test \"`echo '$''{'ac_cv_func_inet_pton'+set}'`\" = set"; then
6201   echo $ac_n "(cached) $ac_c" 1>&6
6202 else
6203   cat > conftest.$ac_ext <<EOF
6204 #line 6205 "configure"
6205 #include "confdefs.h"
6206 /* System header to define __stub macros and hopefully few prototypes,
6207     which can conflict with char inet_pton(); below.  */
6208 #include <assert.h>
6209 /* Override any gcc2 internal prototype to avoid an error.  */
6210 /* We use char because int might match the return type of a gcc2
6211     builtin and then its argument prototype would still apply.  */
6212 char inet_pton();
6213
6214 int main() {
6215
6216 /* The GNU C library defines this for functions which it implements
6217     to always fail with ENOSYS.  Some functions are actually named
6218     something starting with __ and the normal name is an alias.  */
6219 #if defined (__stub_inet_pton) || defined (__stub___inet_pton)
6220 choke me
6221 #else
6222 inet_pton();
6223 #endif
6224
6225 ; return 0; }
6226 EOF
6227 if { (eval echo configure:6228: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6228   rm -rf conftest*
6229   eval "ac_cv_func_inet_pton=yes"
6230 else
6231   echo "configure: failed program was:" >&5
6232   cat conftest.$ac_ext >&5
6233   rm -rf conftest*
6234   eval "ac_cv_func_inet_pton=no"
6235 fi
6236 rm -f conftest*
6237 fi
6238
6239 if eval "test \"`echo '$ac_cv_func_'inet_pton`\" = yes"; then
6240   echo "$ac_t""yes" 1>&6
6241   PLUGINS="${PLUGINS} ipv6"
6242 else
6243   echo "$ac_t""no" 1>&6
6244 fi
6245
6246 fi
6247
6248 # Check whether --enable-avi or --disable-avi was given.
6249 if test "${enable_avi+set}" = set; then
6250   enableval="$enable_avi"
6251   :
6252 fi
6253
6254 if test x$enable_avi != xno
6255 then
6256   PLUGINS="${PLUGINS} avi"
6257 fi
6258
6259
6260 # Check whether --with- or --without- was given.
6261 if test "${with_+set}" = set; then
6262   withval="$with_"
6263   :
6264 fi
6265
6266
6267 # Check whether --enable-mad or --disable-mad was given.
6268 if test "${enable_mad+set}" = set; then
6269   enableval="$enable_mad"
6270   :
6271 fi
6272
6273 if test x$enable_mad = xyes
6274 then
6275   # Check whether --with-mad or --without-mad was given.
6276 if test "${with_mad+set}" = set; then
6277   withval="$with_mad"
6278   :
6279 fi
6280
6281   if test "x$with_mad" != "xno" -a "x$with_mad" != "x"
6282   then
6283     mad_CFLAGS="${mad_CFLAGS} -I$with_mad/include"
6284     mad_LDFLAGS="${mad_LDFLAGS} -L$with_mad/lib"
6285   fi
6286
6287   # Check whether --with-mad-tree or --without-mad-tree was given.
6288 if test "${with_mad_tree+set}" = set; then
6289   withval="$with_mad_tree"
6290   :
6291 fi
6292
6293   if test "x$with_mad_tree" != "xno" -a "x$with_mad_tree" != "x"
6294   then
6295     real_mad_tree="`cd ${with_mad_tree} 2>/dev/null && pwd`"
6296     if test "x$real_mad_tree" = x
6297     then
6298             echo "$ac_t""no" 1>&6
6299       { echo "configure: error: ${with_mad_tree} directory doesn't exist" 1>&2; exit 1; }
6300     fi
6301         echo $ac_n "checking for mad.h in ${real_mad_tree}/libmad""... $ac_c" 1>&6
6302 echo "configure:6303: checking for mad.h in ${real_mad_tree}/libmad" >&5
6303     if test -f ${real_mad_tree}/libmad/mad.h
6304     then
6305       echo "$ac_t""yes" 1>&6
6306       mad_CFLAGS="${mad_CFLAGS} -I${real_mad_tree}/libmad"
6307       mad_LDFLAGS="${mad_LDFLAGS} -L${real_mad_tree}/libmad/.libs"
6308       save_LDFLAGS=$LDFLAGS
6309       LDFLAGS=$mad_LDFLAGS
6310       echo $ac_n "checking for mad_bit_init in -lmad""... $ac_c" 1>&6
6311 echo "configure:6312: checking for mad_bit_init in -lmad" >&5
6312 ac_lib_var=`echo mad'_'mad_bit_init | sed 'y%./+-%__p_%'`
6313 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6314   echo $ac_n "(cached) $ac_c" 1>&6
6315 else
6316   ac_save_LIBS="$LIBS"
6317 LIBS="-lmad  $LIBS"
6318 cat > conftest.$ac_ext <<EOF
6319 #line 6320 "configure"
6320 #include "confdefs.h"
6321 /* Override any gcc2 internal prototype to avoid an error.  */
6322 /* We use char because int might match the return type of a gcc2
6323     builtin and then its argument prototype would still apply.  */
6324 char mad_bit_init();
6325
6326 int main() {
6327 mad_bit_init()
6328 ; return 0; }
6329 EOF
6330 if { (eval echo configure:6331: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6331   rm -rf conftest*
6332   eval "ac_cv_lib_$ac_lib_var=yes"
6333 else
6334   echo "configure: failed program was:" >&5
6335   cat conftest.$ac_ext >&5
6336   rm -rf conftest*
6337   eval "ac_cv_lib_$ac_lib_var=no"
6338 fi
6339 rm -f conftest*
6340 LIBS="$ac_save_LIBS"
6341
6342 fi
6343 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6344   echo "$ac_t""yes" 1>&6
6345   
6346         BUILTINS="${BUILTINS} mad"
6347         mad_LDFLAGS="${mad_LDFLAGS} -lmad"
6348         
6349 else
6350   echo "$ac_t""no" 1>&6
6351  { echo "configure: error: the specified tree hasn't been compiled " 1>&2; exit 1; }
6352       
6353 fi
6354
6355       LDFLAGS=$save_LDFLAGS
6356     else
6357       echo "$ac_t""no" 1>&6
6358       { echo "configure: error: the specified tree doesn't have mad.h" 1>&2; exit 1; }
6359     fi
6360   else
6361     save_CFLAGS=$CFLAGS
6362     save_LDFLAGS=$LDFLAGS
6363     CFLAGS="$CFLAGS $mad_CFLAGS"
6364     LDFLAGS="$LDFLAGS $mad_LDFLAGS"
6365     for ac_hdr in mad.h
6366 do
6367 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6368 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6369 echo "configure:6370: checking for $ac_hdr" >&5
6370 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
6371   echo $ac_n "(cached) $ac_c" 1>&6
6372 else
6373   cat > conftest.$ac_ext <<EOF
6374 #line 6375 "configure"
6375 #include "confdefs.h"
6376 #include <$ac_hdr>
6377 EOF
6378 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6379 { (eval echo configure:6380: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6380 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6381 if test -z "$ac_err"; then
6382   rm -rf conftest*
6383   eval "ac_cv_header_$ac_safe=yes"
6384 else
6385   echo "$ac_err" >&5
6386   echo "configure: failed program was:" >&5
6387   cat conftest.$ac_ext >&5
6388   rm -rf conftest*
6389   eval "ac_cv_header_$ac_safe=no"
6390 fi
6391 rm -f conftest*
6392 fi
6393 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6394   echo "$ac_t""yes" 1>&6
6395     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6396   cat >> confdefs.h <<EOF
6397 #define $ac_tr_hdr 1
6398 EOF
6399  
6400 else
6401   echo "$ac_t""no" 1>&6
6402 { echo "configure: error: Cannot find development headers for libmad..." 1>&2; exit 1; } 
6403 fi
6404 done
6405
6406     echo $ac_n "checking for mad_bit_init in -lmad""... $ac_c" 1>&6
6407 echo "configure:6408: checking for mad_bit_init in -lmad" >&5
6408 ac_lib_var=`echo mad'_'mad_bit_init | sed 'y%./+-%__p_%'`
6409 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6410   echo $ac_n "(cached) $ac_c" 1>&6
6411 else
6412   ac_save_LIBS="$LIBS"
6413 LIBS="-lmad  $LIBS"
6414 cat > conftest.$ac_ext <<EOF
6415 #line 6416 "configure"
6416 #include "confdefs.h"
6417 /* Override any gcc2 internal prototype to avoid an error.  */
6418 /* We use char because int might match the return type of a gcc2
6419     builtin and then its argument prototype would still apply.  */
6420 char mad_bit_init();
6421
6422 int main() {
6423 mad_bit_init()
6424 ; return 0; }
6425 EOF
6426 if { (eval echo configure:6427: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6427   rm -rf conftest*
6428   eval "ac_cv_lib_$ac_lib_var=yes"
6429 else
6430   echo "configure: failed program was:" >&5
6431   cat conftest.$ac_ext >&5
6432   rm -rf conftest*
6433   eval "ac_cv_lib_$ac_lib_var=no"
6434 fi
6435 rm -f conftest*
6436 LIBS="$ac_save_LIBS"
6437
6438 fi
6439 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6440   echo "$ac_t""yes" 1>&6
6441   PLUGINS="${PLUGINS} mad"
6442       mad_LDFLAGS="${mad_LDFLAGS} -lmad"
6443 else
6444   echo "$ac_t""no" 1>&6
6445  { echo "configure: error: Cannot find libmad library..." 1>&2; exit 1; } 
6446 fi
6447
6448     CFLAGS=$save_CFLAGS
6449     LDFLAGS=$save_LDFLAGS
6450   fi
6451 fi
6452
6453 # Check whether --enable-ffmpeg or --disable-ffmpeg was given.
6454 if test "${enable_ffmpeg+set}" = set; then
6455   enableval="$enable_ffmpeg"
6456   :
6457 fi
6458
6459 if test "x$enable_ffmpeg" = "xyes"
6460 then
6461   # Check whether --with-ffmpeg or --without-ffmpeg was given.
6462 if test "${with_ffmpeg+set}" = set; then
6463   withval="$with_ffmpeg"
6464   :
6465 fi
6466
6467   if test "x$with_ffmpeg" != "xno" -a "x$with_ffmpeg" != "x"
6468   then
6469     BUILTINS="${BUILTINS} ffmpeg"
6470     ffmpeg_CFLAGS="${ffmpeg_CFLAGS} -I$with_ffmpeg/include/libffmpeg"
6471     ffmpeg_LDFLAGS="${ffmpeg_LDFLAGS} -L$with_ffmpeg/lib"
6472   fi
6473
6474   # Check whether --with-ffmpeg-tree or --without-ffmpeg-tree was given.
6475 if test "${with_ffmpeg_tree+set}" = set; then
6476   withval="$with_ffmpeg_tree"
6477   :
6478 fi
6479
6480   if test "x$with_ffmpeg_tree" != "x"
6481   then
6482     echo $ac_n "checking for libavcodec.a in ${with_ffmpeg_tree}""... $ac_c" 1>&6
6483 echo "configure:6484: checking for libavcodec.a in ${with_ffmpeg_tree}" >&5
6484     real_ffmpeg_tree="`cd ${with_ffmpeg_tree} 2>/dev/null && pwd`"
6485     if test "x$real_ffmpeg_tree" = x
6486     then
6487             echo "$ac_t""no" 1>&6
6488       { echo "configure: error: cannot cd to ${with_ffmpeg_tree}" 1>&2; exit 1; }
6489     fi
6490     if test -f "${real_ffmpeg_tree}/libavcodec/libavcodec.a"
6491     then
6492             echo "$ac_t""${real_ffmpeg_tree}/libavcodec/libavcodec.a" 1>&6
6493       BUILTINS="${BUILTINS} ffmpeg"
6494       ffmpeg_LDFLAGS="${ffmpeg_LDFLAGS} ${real_ffmpeg_tree}/libavcodec/libavcodec.a"
6495       ffmpeg_CFLAGS="${ffmpeg_CFLAGS} -I${real_ffmpeg_tree}/libavcodec"
6496     else
6497             echo "$ac_t""no" 1>&6
6498       { echo "configure: error: cannot find ${real_ffmpeg_tree}/libavcodec/libavcodec.a, make sure you compiled libavcodec in ${with_ffmpeg_tree}" 1>&2; exit 1; }
6499     fi
6500   else
6501     save_CFLAGS=$CFLAGS
6502     save_LDFLAGS=$LDFLAGS
6503     CFLAGS="$CFLAGS $ffmpeg_CFLAGS"
6504     LDFLAGS="$LDFLAGS $ffmpeg_LDFLAGS"
6505     echo $ac_n "checking for avcodec_init in -lavcodec""... $ac_c" 1>&6
6506 echo "configure:6507: checking for avcodec_init in -lavcodec" >&5
6507 ac_lib_var=`echo avcodec'_'avcodec_init | sed 'y%./+-%__p_%'`
6508 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6509   echo $ac_n "(cached) $ac_c" 1>&6
6510 else
6511   ac_save_LIBS="$LIBS"
6512 LIBS="-lavcodec  $LIBS"
6513 cat > conftest.$ac_ext <<EOF
6514 #line 6515 "configure"
6515 #include "confdefs.h"
6516 /* Override any gcc2 internal prototype to avoid an error.  */
6517 /* We use char because int might match the return type of a gcc2
6518     builtin and then its argument prototype would still apply.  */
6519 char avcodec_init();
6520
6521 int main() {
6522 avcodec_init()
6523 ; return 0; }
6524 EOF
6525 if { (eval echo configure:6526: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6526   rm -rf conftest*
6527   eval "ac_cv_lib_$ac_lib_var=yes"
6528 else
6529   echo "configure: failed program was:" >&5
6530   cat conftest.$ac_ext >&5
6531   rm -rf conftest*
6532   eval "ac_cv_lib_$ac_lib_var=no"
6533 fi
6534 rm -f conftest*
6535 LIBS="$ac_save_LIBS"
6536
6537 fi
6538 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6539   echo "$ac_t""yes" 1>&6
6540   BUITLINS="${BUILTINS} ffmpeg"
6541       ffmpeg_LDFLAGS="${ffmpeg_LDFLAGS} -lavcodec"
6542 else
6543   echo "$ac_t""no" 1>&6
6544  { echo "configure: error: Cannot find libavcodec library..." 1>&2; exit 1; } 
6545 fi
6546
6547     CFLAGS=$save_CFLAGS
6548     LDFLAGS=$save_LDFLAGS
6549   fi
6550 fi
6551
6552
6553 if test x$SYS = xbeos
6554 then
6555     PLUGINS="${PLUGINS} beos"
6556 fi
6557
6558 # Check whether --enable-a52 or --disable-a52 was given.
6559 if test "${enable_a52+set}" = set; then
6560   enableval="$enable_a52"
6561   :
6562 fi
6563
6564 if test "x$enable_a52" != "xno"
6565 then
6566   # Check whether --with-a52-tree or --without-a52-tree was given.
6567 if test "${with_a52_tree+set}" = set; then
6568   withval="$with_a52_tree"
6569   :
6570 fi
6571
6572   if test "x$with_a52_tree" != "xno" -a "x$with_a52_tree" != "x"
6573   then
6574     real_a52_tree="`cd ${with_a52_tree} 2>/dev/null && pwd`"
6575     if test "x$real_a52_tree" = x
6576     then
6577             echo "$ac_t""no" 1>&6
6578       { echo "configure: error: ${with_a52_tree} directory doesn't exist" 1>&2; exit 1; }
6579     fi
6580         echo $ac_n "checking for a52.h in ${real_a52_tree}/include""... $ac_c" 1>&6
6581 echo "configure:6582: checking for a52.h in ${real_a52_tree}/include" >&5
6582     if test -f ${real_a52_tree}/include/a52.h
6583     then
6584       echo "$ac_t""yes" 1>&6
6585       a52_CFLAGS="${a52_CFLAGS} -I${real_a52_tree}"
6586       a52_LDFLAGS="${a52_LDFLAGS} -L${real_a52_tree}/liba52/.libs"
6587       save_LDFLAGS=$LDFLAGS
6588       LDFLAGS="$a52_LDFLAGS $LDFLAGS"
6589       echo $ac_n "checking for a52_free in -la52""... $ac_c" 1>&6
6590 echo "configure:6591: checking for a52_free in -la52" >&5
6591 ac_lib_var=`echo a52'_'a52_free | sed 'y%./+-%__p_%'`
6592 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6593   echo $ac_n "(cached) $ac_c" 1>&6
6594 else
6595   ac_save_LIBS="$LIBS"
6596 LIBS="-la52 -lm $LIBS"
6597 cat > conftest.$ac_ext <<EOF
6598 #line 6599 "configure"
6599 #include "confdefs.h"
6600 /* Override any gcc2 internal prototype to avoid an error.  */
6601 /* We use char because int might match the return type of a gcc2
6602     builtin and then its argument prototype would still apply.  */
6603 char a52_free();
6604
6605 int main() {
6606 a52_free()
6607 ; return 0; }
6608 EOF
6609 if { (eval echo configure:6610: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6610   rm -rf conftest*
6611   eval "ac_cv_lib_$ac_lib_var=yes"
6612 else
6613   echo "configure: failed program was:" >&5
6614   cat conftest.$ac_ext >&5
6615   rm -rf conftest*
6616   eval "ac_cv_lib_$ac_lib_var=no"
6617 fi
6618 rm -f conftest*
6619 LIBS="$ac_save_LIBS"
6620
6621 fi
6622 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6623   echo "$ac_t""yes" 1>&6
6624   
6625         BUILTINS="${BUILTINS} a52"
6626         a52_LDFLAGS="${a52_LDFLAGS} -la52 -lm"
6627         a52_CFLAGS="${a52_CFLAGS} -DUSE_A52DEC_TREE"
6628         
6629 else
6630   echo "$ac_t""no" 1>&6
6631
6632         if test -f ${real_a52_tree}/liba52/.libs/liba52.a
6633         then
6634           { echo "configure: error: make sure you have at least a52dec-0.7.3" 1>&2; exit 1; }
6635         else
6636           { echo "configure: error: the specified tree hasn't been compiled" 1>&2; exit 1; }
6637         fi
6638       
6639 fi
6640
6641       LDFLAGS=$save_LDFLAGS
6642     else
6643       echo "$ac_t""no" 1>&6
6644       { echo "configure: error: the specified tree doesn't have a52.h" 1>&2; exit 1; }
6645     fi
6646   else     for ac_hdr in a52dec/a52.h
6647 do
6648 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6649 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6650 echo "configure:6651: checking for $ac_hdr" >&5
6651 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
6652   echo $ac_n "(cached) $ac_c" 1>&6
6653 else
6654   cat > conftest.$ac_ext <<EOF
6655 #line 6656 "configure"
6656 #include "confdefs.h"
6657 #include <$ac_hdr>
6658 EOF
6659 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6660 { (eval echo configure:6661: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6661 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6662 if test -z "$ac_err"; then
6663   rm -rf conftest*
6664   eval "ac_cv_header_$ac_safe=yes"
6665 else
6666   echo "$ac_err" >&5
6667   echo "configure: failed program was:" >&5
6668   cat conftest.$ac_ext >&5
6669   rm -rf conftest*
6670   eval "ac_cv_header_$ac_safe=no"
6671 fi
6672 rm -f conftest*
6673 fi
6674 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6675   echo "$ac_t""yes" 1>&6
6676     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6677   cat >> confdefs.h <<EOF
6678 #define $ac_tr_hdr 1
6679 EOF
6680  
6681       echo $ac_n "checking for a52_free in -la52""... $ac_c" 1>&6
6682 echo "configure:6683: checking for a52_free in -la52" >&5
6683 ac_lib_var=`echo a52'_'a52_free | sed 'y%./+-%__p_%'`
6684 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6685   echo $ac_n "(cached) $ac_c" 1>&6
6686 else
6687   ac_save_LIBS="$LIBS"
6688 LIBS="-la52 -lm $LIBS"
6689 cat > conftest.$ac_ext <<EOF
6690 #line 6691 "configure"
6691 #include "confdefs.h"
6692 /* Override any gcc2 internal prototype to avoid an error.  */
6693 /* We use char because int might match the return type of a gcc2
6694     builtin and then its argument prototype would still apply.  */
6695 char a52_free();
6696
6697 int main() {
6698 a52_free()
6699 ; return 0; }
6700 EOF
6701 if { (eval echo configure:6702: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6702   rm -rf conftest*
6703   eval "ac_cv_lib_$ac_lib_var=yes"
6704 else
6705   echo "configure: failed program was:" >&5
6706   cat conftest.$ac_ext >&5
6707   rm -rf conftest*
6708   eval "ac_cv_lib_$ac_lib_var=no"
6709 fi
6710 rm -f conftest*
6711 LIBS="$ac_save_LIBS"
6712
6713 fi
6714 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6715   echo "$ac_t""yes" 1>&6
6716   
6717         BUILTINS="${BUILTINS} a52"
6718         a52_LDFLAGS="${a52_LDFLAGS} -la52 -lm"
6719         a52_CFLAGS="${a52_CFLAGS}"
6720       
6721 else
6722   echo "$ac_t""no" 1>&6
6723 fi
6724
6725     
6726 else
6727   echo "$ac_t""no" 1>&6
6728 fi
6729 done
6730
6731   fi
6732 fi
6733
6734 # Check whether --enable-vorbis or --disable-vorbis was given.
6735 if test "${enable_vorbis+set}" = set; then
6736   enableval="$enable_vorbis"
6737   :
6738 fi
6739
6740 if test "x$enable_vorbis" != "xno"
6741 then
6742   for ac_hdr in ogg/ogg.h
6743 do
6744 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6745 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6746 echo "configure:6747: checking for $ac_hdr" >&5
6747 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
6748   echo $ac_n "(cached) $ac_c" 1>&6
6749 else
6750   cat > conftest.$ac_ext <<EOF
6751 #line 6752 "configure"
6752 #include "confdefs.h"
6753 #include <$ac_hdr>
6754 EOF
6755 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6756 { (eval echo configure:6757: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6757 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6758 if test -z "$ac_err"; then
6759   rm -rf conftest*
6760   eval "ac_cv_header_$ac_safe=yes"
6761 else
6762   echo "$ac_err" >&5
6763   echo "configure: failed program was:" >&5
6764   cat conftest.$ac_ext >&5
6765   rm -rf conftest*
6766   eval "ac_cv_header_$ac_safe=no"
6767 fi
6768 rm -f conftest*
6769 fi
6770 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6771   echo "$ac_t""yes" 1>&6
6772     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6773   cat >> confdefs.h <<EOF
6774 #define $ac_tr_hdr 1
6775 EOF
6776  
6777         #PLUGINS="${PLUGINS} vorbis"
6778     vorbis_LDFLAGS="${vorbis_LDFLAGS} -lvorbis"
6779    
6780 else
6781   echo "$ac_t""no" 1>&6
6782 fi
6783 done
6784
6785 fi
6786
6787
6788 # Check whether --with- or --without- was given.
6789 if test "${with_+set}" = set; then
6790   withval="$with_"
6791   :
6792 fi
6793
6794
6795 # Check whether --enable-x11 or --disable-x11 was given.
6796 if test "${enable_x11+set}" = set; then
6797   enableval="$enable_x11"
6798   :
6799 fi
6800
6801 if test x$enable_x11 != xno &&
6802   (test x$SYS != xmingw32 || test x$enable_x11 = xyes); then
6803   if test x$x_includes = xNONE; then
6804     x_includes=/usr/X11R6/include
6805   fi
6806   if test x$x_libraries = xNONE; then
6807     x_libraries=/usr/X11R6/lib
6808   fi
6809   CPPFLAGS="$save_CPPFLAGS -I$x_includes"
6810   for ac_hdr in X11/Xlib.h
6811 do
6812 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6813 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6814 echo "configure:6815: checking for $ac_hdr" >&5
6815 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
6816   echo $ac_n "(cached) $ac_c" 1>&6
6817 else
6818   cat > conftest.$ac_ext <<EOF
6819 #line 6820 "configure"
6820 #include "confdefs.h"
6821 #include <$ac_hdr>
6822 EOF
6823 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6824 { (eval echo configure:6825: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6825 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6826 if test -z "$ac_err"; then
6827   rm -rf conftest*
6828   eval "ac_cv_header_$ac_safe=yes"
6829 else
6830   echo "$ac_err" >&5
6831   echo "configure: failed program was:" >&5
6832   cat conftest.$ac_ext >&5
6833   rm -rf conftest*
6834   eval "ac_cv_header_$ac_safe=no"
6835 fi
6836 rm -f conftest*
6837 fi
6838 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6839   echo "$ac_t""yes" 1>&6
6840     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6841   cat >> confdefs.h <<EOF
6842 #define $ac_tr_hdr 1
6843 EOF
6844  
6845     PLUGINS="${PLUGINS} x11"
6846     x11_LDFLAGS="${x11_LDFLAGS} -L$x_libraries -lX11 -lXext"
6847     x11_CFLAGS="${x11_CFLAGS} -I$x_includes"
6848   
6849 else
6850   echo "$ac_t""no" 1>&6
6851 fi
6852 done
6853
6854   CPPFLAGS="$save_CPPFLAGS"
6855 fi
6856
6857 # Check whether --enable-xvideo or --disable-xvideo was given.
6858 if test "${enable_xvideo+set}" = set; then
6859   enableval="$enable_xvideo"
6860   :
6861 fi
6862
6863 if test x$enable_xvideo != xno &&
6864   (test x$SYS != xmingw32 || test x$enable_xvideo = xyes); then
6865   if test x$x_includes = xNONE; then
6866     x_includes=/usr/X11R6/include
6867   fi
6868   if test x$x_libraries = xNONE; then
6869     x_libraries=/usr/X11R6/lib
6870   fi
6871   save_CPPFLAGS=$CPPFLAGS
6872   CPPFLAGS="$save_CPPFLAGS -I$x_includes"
6873   for ac_hdr in X11/extensions/Xv.h
6874 do
6875 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
6876 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6877 echo "configure:6878: checking for $ac_hdr" >&5
6878 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
6879   echo $ac_n "(cached) $ac_c" 1>&6
6880 else
6881   cat > conftest.$ac_ext <<EOF
6882 #line 6883 "configure"
6883 #include "confdefs.h"
6884 #include <$ac_hdr>
6885 EOF
6886 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6887 { (eval echo configure:6888: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6888 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6889 if test -z "$ac_err"; then
6890   rm -rf conftest*
6891   eval "ac_cv_header_$ac_safe=yes"
6892 else
6893   echo "$ac_err" >&5
6894   echo "configure: failed program was:" >&5
6895   cat conftest.$ac_ext >&5
6896   rm -rf conftest*
6897   eval "ac_cv_header_$ac_safe=no"
6898 fi
6899 rm -f conftest*
6900 fi
6901 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6902   echo "$ac_t""yes" 1>&6
6903     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
6904   cat >> confdefs.h <<EOF
6905 #define $ac_tr_hdr 1
6906 EOF
6907  
6908     save_CFLAGS=$CFLAGS
6909     CFLAGS="$CFLAGS -L$x_libraries -lX11 -lXext"
6910     echo $ac_n "checking for XvSetPortAttribute in -lXv_pic""... $ac_c" 1>&6
6911 echo "configure:6912: checking for XvSetPortAttribute in -lXv_pic" >&5
6912 ac_lib_var=`echo Xv_pic'_'XvSetPortAttribute | sed 'y%./+-%__p_%'`
6913 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6914   echo $ac_n "(cached) $ac_c" 1>&6
6915 else
6916   ac_save_LIBS="$LIBS"
6917 LIBS="-lXv_pic  $LIBS"
6918 cat > conftest.$ac_ext <<EOF
6919 #line 6920 "configure"
6920 #include "confdefs.h"
6921 /* Override any gcc2 internal prototype to avoid an error.  */
6922 /* We use char because int might match the return type of a gcc2
6923     builtin and then its argument prototype would still apply.  */
6924 char XvSetPortAttribute();
6925
6926 int main() {
6927 XvSetPortAttribute()
6928 ; return 0; }
6929 EOF
6930 if { (eval echo configure:6931: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6931   rm -rf conftest*
6932   eval "ac_cv_lib_$ac_lib_var=yes"
6933 else
6934   echo "configure: failed program was:" >&5
6935   cat conftest.$ac_ext >&5
6936   rm -rf conftest*
6937   eval "ac_cv_lib_$ac_lib_var=no"
6938 fi
6939 rm -f conftest*
6940 LIBS="$ac_save_LIBS"
6941
6942 fi
6943 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6944   echo "$ac_t""yes" 1>&6
6945   # We have Xv_pic, that's good, we can build an xvideo.so plugin !
6946       PLUGINS="${PLUGINS} xvideo"
6947       xvideo_LDFLAGS="${xvideo_LDFLAGS} -L$x_libraries -lX11 -lXext -lXv_pic"
6948       xvideo_CFLAGS="${xvideo_CFLAGS} -I$x_includes"
6949 else
6950   echo "$ac_t""no" 1>&6
6951 # We don't have Xv_pic, let's make xvideo.a as builtin
6952       BUILTINS="${BUILTINS} xvideo"
6953       xvideo_LDFLAGS="${xvideo_LDFLAGS} -L$x_libraries -lX11 -lXext -lXv"
6954       xvideo_CFLAGS="${xvideo_CFLAGS} -I$x_includes"
6955 fi
6956
6957     CFLAGS="$save_CFLAGS"
6958   
6959   CPPFLAGS="$save_CPPFLAGS"
6960 else
6961   echo "$ac_t""no" 1>&6
6962 fi
6963 done
6964
6965 fi
6966
6967 # Check whether --enable-sdl or --disable-sdl was given.
6968 if test "${enable_sdl+set}" = set; then
6969   enableval="$enable_sdl"
6970   :
6971 fi
6972
6973 if test "x$enable_sdl" != "xno"
6974 then
6975   SDL_PATH=$PATH
6976   # Check whether --with-sdl-config-path or --without-sdl-config-path was given.
6977 if test "${with_sdl_config_path+set}" = set; then
6978   withval="$with_sdl_config_path"
6979    if test "x$with_sdl_config_path" != "xno"
6980       then
6981         SDL_PATH="$with_sdl_config_path:$PATH"
6982       fi 
6983 fi
6984
6985   # Extract the first word of "sdl12-config", so it can be a program name with args.
6986 set dummy sdl12-config; ac_word=$2
6987 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
6988 echo "configure:6989: checking for $ac_word" >&5
6989 if eval "test \"`echo '$''{'ac_cv_path_SDL12_CONFIG'+set}'`\" = set"; then
6990   echo $ac_n "(cached) $ac_c" 1>&6
6991 else
6992   case "$SDL12_CONFIG" in
6993   /*)
6994   ac_cv_path_SDL12_CONFIG="$SDL12_CONFIG" # Let the user override the test with a path.
6995   ;;
6996   ?:/*)                  
6997   ac_cv_path_SDL12_CONFIG="$SDL12_CONFIG" # Let the user override the test with a dos path.
6998   ;;
6999   *)
7000   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
7001   ac_dummy="$SDL_PATH"
7002   for ac_dir in $ac_dummy; do 
7003     test -z "$ac_dir" && ac_dir=.
7004     if test -f $ac_dir/$ac_word; then
7005       ac_cv_path_SDL12_CONFIG="$ac_dir/$ac_word"
7006       break
7007     fi
7008   done
7009   IFS="$ac_save_ifs"
7010   test -z "$ac_cv_path_SDL12_CONFIG" && ac_cv_path_SDL12_CONFIG="no"
7011   ;;
7012 esac
7013 fi
7014 SDL12_CONFIG="$ac_cv_path_SDL12_CONFIG"
7015 if test -n "$SDL12_CONFIG"; then
7016   echo "$ac_t""$SDL12_CONFIG" 1>&6
7017 else
7018   echo "$ac_t""no" 1>&6
7019 fi
7020
7021   SDL_CONFIG=${SDL12_CONFIG}
7022   SDL_HEADER="SDL12/SDL.h"
7023   if test x${SDL_CONFIG} = xno
7024   then
7025     # Extract the first word of "sdl11-config", so it can be a program name with args.
7026 set dummy sdl11-config; ac_word=$2
7027 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7028 echo "configure:7029: checking for $ac_word" >&5
7029 if eval "test \"`echo '$''{'ac_cv_path_SDL11_CONFIG'+set}'`\" = set"; then
7030   echo $ac_n "(cached) $ac_c" 1>&6
7031 else
7032   case "$SDL11_CONFIG" in
7033   /*)
7034   ac_cv_path_SDL11_CONFIG="$SDL11_CONFIG" # Let the user override the test with a path.
7035   ;;
7036   ?:/*)                  
7037   ac_cv_path_SDL11_CONFIG="$SDL11_CONFIG" # Let the user override the test with a dos path.
7038   ;;
7039   *)
7040   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
7041   ac_dummy="$SDL_PATH"
7042   for ac_dir in $ac_dummy; do 
7043     test -z "$ac_dir" && ac_dir=.
7044     if test -f $ac_dir/$ac_word; then
7045       ac_cv_path_SDL11_CONFIG="$ac_dir/$ac_word"
7046       break
7047     fi
7048   done
7049   IFS="$ac_save_ifs"
7050   test -z "$ac_cv_path_SDL11_CONFIG" && ac_cv_path_SDL11_CONFIG="no"
7051   ;;
7052 esac
7053 fi
7054 SDL11_CONFIG="$ac_cv_path_SDL11_CONFIG"
7055 if test -n "$SDL11_CONFIG"; then
7056   echo "$ac_t""$SDL11_CONFIG" 1>&6
7057 else
7058   echo "$ac_t""no" 1>&6
7059 fi
7060
7061     SDL_CONFIG=${SDL11_CONFIG}
7062     SDL_HEADER="SDL11/SDL.h"
7063   fi
7064   if test x${SDL_CONFIG} = xno
7065   then
7066     # Extract the first word of "sdl-config", so it can be a program name with args.
7067 set dummy sdl-config; ac_word=$2
7068 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7069 echo "configure:7070: checking for $ac_word" >&5
7070 if eval "test \"`echo '$''{'ac_cv_path_SDL_CONFIG'+set}'`\" = set"; then
7071   echo $ac_n "(cached) $ac_c" 1>&6
7072 else
7073   case "$SDL_CONFIG" in
7074   /*)
7075   ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a path.
7076   ;;
7077   ?:/*)                  
7078   ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a dos path.
7079   ;;
7080   *)
7081   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
7082   ac_dummy="$SDL_PATH"
7083   for ac_dir in $ac_dummy; do 
7084     test -z "$ac_dir" && ac_dir=.
7085     if test -f $ac_dir/$ac_word; then
7086       ac_cv_path_SDL_CONFIG="$ac_dir/$ac_word"
7087       break
7088     fi
7089   done
7090   IFS="$ac_save_ifs"
7091   test -z "$ac_cv_path_SDL_CONFIG" && ac_cv_path_SDL_CONFIG="no"
7092   ;;
7093 esac
7094 fi
7095 SDL_CONFIG="$ac_cv_path_SDL_CONFIG"
7096 if test -n "$SDL_CONFIG"; then
7097   echo "$ac_t""$SDL_CONFIG" 1>&6
7098 else
7099   echo "$ac_t""no" 1>&6
7100 fi
7101
7102     SDL_HEADER="SDL/SDL.h"
7103   fi
7104   if test x${SDL_CONFIG} != xno
7105   then
7106     PLUGINS="${PLUGINS} sdl"
7107     sdl_CFLAGS="${sdl_CFLAGS} `${SDL_CONFIG} --cflags`"
7108     sdl_LDFLAGS="${sdl_LDFLAGS} `${SDL_CONFIG} --libs | sed 's,-rdynamic,,'`"
7109     CPPFLAGS="$save_CPPFLAGS $sdl_CFLAGS"
7110     for ac_hdr in ${SDL_HEADER}
7111 do
7112 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
7113 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7114 echo "configure:7115: checking for $ac_hdr" >&5
7115 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
7116   echo $ac_n "(cached) $ac_c" 1>&6
7117 else
7118   cat > conftest.$ac_ext <<EOF
7119 #line 7120 "configure"
7120 #include "confdefs.h"
7121 #include <$ac_hdr>
7122 EOF
7123 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7124 { (eval echo configure:7125: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7125 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7126 if test -z "$ac_err"; then
7127   rm -rf conftest*
7128   eval "ac_cv_header_$ac_safe=yes"
7129 else
7130   echo "$ac_err" >&5
7131   echo "configure: failed program was:" >&5
7132   cat conftest.$ac_ext >&5
7133   rm -rf conftest*
7134   eval "ac_cv_header_$ac_safe=no"
7135 fi
7136 rm -f conftest*
7137 fi
7138 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
7139   echo "$ac_t""yes" 1>&6
7140     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
7141   cat >> confdefs.h <<EOF
7142 #define $ac_tr_hdr 1
7143 EOF
7144  cat >> confdefs.h <<EOF
7145 #define SDL_INCLUDE_FILE <${SDL_HEADER}>
7146 EOF
7147
7148 else
7149   echo "$ac_t""no" 1>&6
7150 { echo "configure: error: The development package for SDL is not installed. 
7151 Please install it and try again. Alternatively you can also configure with 
7152 --disable-sdl." 1>&2; exit 1; }
7153       
7154 fi
7155 done
7156
7157     CPPFLAGS="$save_CPPFLAGS"
7158     if expr 1.1.5 \> `$SDL_CONFIG --version` >/dev/null
7159     then
7160       { echo "configure: error: The development package for SDL is not installed.
7161 Please install it and try again. Alternatively you can also configure with
7162 --disable-sdl." 1>&2; exit 1; }
7163     fi
7164   elif test "x$enable_sdl" =  "xyes"
7165   then
7166     { echo "configure: error: I couldn't find the SDL package. You can download libSDL
7167 from http://www.libsdl.org/, or configure with --disable-sdl. Have a nice day.
7168     " 1>&2; exit 1; }
7169   fi
7170 fi
7171
7172 # Check whether --enable-directx or --disable-directx was given.
7173 if test "${enable_directx+set}" = set; then
7174   enableval="$enable_directx"
7175   :
7176 fi
7177
7178 if test "x$enable_directx" != "xno"
7179 then
7180   if test x$SYS = xmingw32
7181   then
7182     # Check whether --with-directx or --without-directx was given.
7183 if test "${with_directx+set}" = set; then
7184   withval="$with_directx"
7185   :
7186 fi
7187
7188     if test "x$with_directx" = "x"
7189     then
7190       for ac_hdr in ddraw.h
7191 do
7192 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
7193 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7194 echo "configure:7195: checking for $ac_hdr" >&5
7195 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
7196   echo $ac_n "(cached) $ac_c" 1>&6
7197 else
7198   cat > conftest.$ac_ext <<EOF
7199 #line 7200 "configure"
7200 #include "confdefs.h"
7201 #include <$ac_hdr>
7202 EOF
7203 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7204 { (eval echo configure:7205: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7205 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7206 if test -z "$ac_err"; then
7207   rm -rf conftest*
7208   eval "ac_cv_header_$ac_safe=yes"
7209 else
7210   echo "$ac_err" >&5
7211   echo "configure: failed program was:" >&5
7212   cat conftest.$ac_ext >&5
7213   rm -rf conftest*
7214   eval "ac_cv_header_$ac_safe=no"
7215 fi
7216 rm -f conftest*
7217 fi
7218 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
7219   echo "$ac_t""yes" 1>&6
7220     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
7221   cat >> confdefs.h <<EOF
7222 #define $ac_tr_hdr 1
7223 EOF
7224   PLUGINS="${PLUGINS} directx"
7225         directx_LDFLAGS="${directx_LDFLAGS} -lgdi32" 
7226 else
7227   echo "$ac_t""no" 1>&6
7228 fi
7229 done
7230
7231     else
7232       echo $ac_n "checking for directX headers in ${with_directx}""... $ac_c" 1>&6
7233 echo "configure:7234: checking for directX headers in ${with_directx}" >&5
7234       if test -f ${with_directx}/ddraw.h
7235       then
7236         PLUGINS="${PLUGINS} directx"
7237         directx_LDFLAGS="${directx_LDFLAGS} -L${with_directx}/lib -lgdi32"
7238         directx_CFLAGS="${directx_CFLAGS} -I${with_directx}"
7239         echo "$ac_t""yes" 1>&6
7240       else
7241         echo "$ac_t""no" 1>&6
7242         { echo "configure: error: Cannot find ${with_directx}/ddraw.h!" 1>&2; exit 1; }
7243       fi
7244     fi
7245   fi
7246 fi
7247
7248 # Check whether --enable-fb or --disable-fb was given.
7249 if test "${enable_fb+set}" = set; then
7250   enableval="$enable_fb"
7251   :
7252 fi
7253
7254     if test x$enable_fb != xno
7255     then
7256       for ac_hdr in linux/fb.h
7257 do
7258 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
7259 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7260 echo "configure:7261: checking for $ac_hdr" >&5
7261 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
7262   echo $ac_n "(cached) $ac_c" 1>&6
7263 else
7264   cat > conftest.$ac_ext <<EOF
7265 #line 7266 "configure"
7266 #include "confdefs.h"
7267 #include <$ac_hdr>
7268 EOF
7269 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7270 { (eval echo configure:7271: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7271 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7272 if test -z "$ac_err"; then
7273   rm -rf conftest*
7274   eval "ac_cv_header_$ac_safe=yes"
7275 else
7276   echo "$ac_err" >&5
7277   echo "configure: failed program was:" >&5
7278   cat conftest.$ac_ext >&5
7279   rm -rf conftest*
7280   eval "ac_cv_header_$ac_safe=no"
7281 fi
7282 rm -f conftest*
7283 fi
7284 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
7285   echo "$ac_t""yes" 1>&6
7286     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
7287   cat >> confdefs.h <<EOF
7288 #define $ac_tr_hdr 1
7289 EOF
7290  
7291         PLUGINS="${PLUGINS} fb"
7292       
7293 else
7294   echo "$ac_t""no" 1>&6
7295 fi
7296 done
7297
7298     fi
7299
7300 # Check whether --enable-mga or --disable-mga was given.
7301 if test "${enable_mga+set}" = set; then
7302   enableval="$enable_mga"
7303    if test x$enable_mga = xyes
7304     then
7305       PLUGINS="${PLUGINS} mga xmga"
7306     fi 
7307 fi
7308
7309
7310 # Check whether --enable-ggi or --disable-ggi was given.
7311 if test "${enable_ggi+set}" = set; then
7312   enableval="$enable_ggi"
7313   :
7314 fi
7315
7316 if test x$enable_ggi = xyes
7317 then
7318   PLUGINS="${PLUGINS} ggi"
7319   ggi_LDFLAGS="${ggi_LDFLAGS} -lggi"
7320   # Check whether --with-ggi or --without-ggi was given.
7321 if test "${with_ggi+set}" = set; then
7322   withval="$with_ggi"
7323    if test "x$with_ggi" != "xno" -a "x$with_ggi" != "x"
7324       then
7325         CFLAGS_GGI="${CFLAGS_GGI} -I$with_ggi/include"
7326         ggi_LDFLAGS="${ggi_LDFLAGS} -L$with_ggi/lib"
7327       fi 
7328 fi
7329
7330 fi
7331
7332 # Check whether --enable-glide or --disable-glide was given.
7333 if test "${enable_glide+set}" = set; then
7334   enableval="$enable_glide"
7335   :
7336 fi
7337
7338 if test x$enable_glide = xyes
7339 then
7340   PLUGINS="${PLUGINS} glide"
7341   glide_LDFLAGS="${glide_LDFLAGS} -lglide2x -lm"
7342   glide_CFLAGS="${glide_CFLAGS} -I/usr/include/glide"
7343   # Check whether --with-glide or --without-glide was given.
7344 if test "${with_glide+set}" = set; then
7345   withval="$with_glide"
7346    if test "x$with_glide" != "xno" -a "x$with_glide" != "x"
7347       then
7348         glide_CFLAGS="${glide_CFLAGS} -I$with_glide/include"
7349         glide_LDFLAGS="${glide_LDFLAGS} -L$with_glide/lib"
7350       fi 
7351 fi
7352
7353 fi
7354
7355 # Check whether --enable-aa or --disable-aa was given.
7356 if test "${enable_aa+set}" = set; then
7357   enableval="$enable_aa"
7358   :
7359 fi
7360
7361 if test x$enable_aa = xyes
7362 then
7363   ac_safe=`echo "aalib.h" | sed 'y%./+-%__p_%'`
7364 echo $ac_n "checking for aalib.h""... $ac_c" 1>&6
7365 echo "configure:7366: checking for aalib.h" >&5
7366 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
7367   echo $ac_n "(cached) $ac_c" 1>&6
7368 else
7369   cat > conftest.$ac_ext <<EOF
7370 #line 7371 "configure"
7371 #include "confdefs.h"
7372 #include <aalib.h>
7373 EOF
7374 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7375 { (eval echo configure:7376: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7376 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7377 if test -z "$ac_err"; then
7378   rm -rf conftest*
7379   eval "ac_cv_header_$ac_safe=yes"
7380 else
7381   echo "$ac_err" >&5
7382   echo "configure: failed program was:" >&5
7383   cat conftest.$ac_ext >&5
7384   rm -rf conftest*
7385   eval "ac_cv_header_$ac_safe=no"
7386 fi
7387 rm -f conftest*
7388 fi
7389 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
7390   echo "$ac_t""yes" 1>&6
7391   have_aa="true"
7392 else
7393   echo "$ac_t""no" 1>&6
7394 have_aa="false"
7395 fi
7396
7397   if test x$have_aa = xtrue
7398   then
7399     PLUGINS="${PLUGINS} aa"
7400     aa_LDFLAGS="${aa_LDFLAGS} -laa"
7401   fi
7402 fi
7403
7404
7405 # Check whether --with- or --without- was given.
7406 if test "${with_+set}" = set; then
7407   withval="$with_"
7408   :
7409 fi
7410
7411
7412 # Check whether --enable-dsp or --disable-dsp was given.
7413 if test "${enable_dsp+set}" = set; then
7414   enableval="$enable_dsp"
7415   :
7416 fi
7417
7418
7419 if test x$enable_dsp != xno &&
7420   (test x$SYS != xmingw32 || test x$enable_dsp = xyes)
7421 then
7422   for ac_hdr in soundcard.h sys/soundcard.h machine/soundcard.h
7423 do
7424 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
7425 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7426 echo "configure:7427: checking for $ac_hdr" >&5
7427 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
7428   echo $ac_n "(cached) $ac_c" 1>&6
7429 else
7430   cat > conftest.$ac_ext <<EOF
7431 #line 7432 "configure"
7432 #include "confdefs.h"
7433 #include <$ac_hdr>
7434 EOF
7435 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7436 { (eval echo configure:7437: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7437 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7438 if test -z "$ac_err"; then
7439   rm -rf conftest*
7440   eval "ac_cv_header_$ac_safe=yes"
7441 else
7442   echo "$ac_err" >&5
7443   echo "configure: failed program was:" >&5
7444   cat conftest.$ac_ext >&5
7445   rm -rf conftest*
7446   eval "ac_cv_header_$ac_safe=no"
7447 fi
7448 rm -f conftest*
7449 fi
7450 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
7451   echo "$ac_t""yes" 1>&6
7452     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
7453   cat >> confdefs.h <<EOF
7454 #define $ac_tr_hdr 1
7455 EOF
7456  
7457     PLUGINS="${PLUGINS} dsp"
7458     echo $ac_n "checking for main in -lossaudio""... $ac_c" 1>&6
7459 echo "configure:7460: checking for main in -lossaudio" >&5
7460 ac_lib_var=`echo ossaudio'_'main | sed 'y%./+-%__p_%'`
7461 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
7462   echo $ac_n "(cached) $ac_c" 1>&6
7463 else
7464   ac_save_LIBS="$LIBS"
7465 LIBS="-lossaudio  $LIBS"
7466 cat > conftest.$ac_ext <<EOF
7467 #line 7468 "configure"
7468 #include "confdefs.h"
7469
7470 int main() {
7471 main()
7472 ; return 0; }
7473 EOF
7474 if { (eval echo configure:7475: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7475   rm -rf conftest*
7476   eval "ac_cv_lib_$ac_lib_var=yes"
7477 else
7478   echo "configure: failed program was:" >&5
7479   cat conftest.$ac_ext >&5
7480   rm -rf conftest*
7481   eval "ac_cv_lib_$ac_lib_var=no"
7482 fi
7483 rm -f conftest*
7484 LIBS="$ac_save_LIBS"
7485
7486 fi
7487 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
7488   echo "$ac_t""yes" 1>&6
7489   dsp_LDFLAGS="${dsp_LDFLAGS} -lossaudio"
7490 else
7491   echo "$ac_t""no" 1>&6
7492 fi
7493
7494   
7495 else
7496   echo "$ac_t""no" 1>&6
7497 fi
7498 done
7499
7500 fi
7501
7502 # Check whether --enable-esd or --disable-esd was given.
7503 if test "${enable_esd+set}" = set; then
7504   enableval="$enable_esd"
7505   if test x$enable_esd = xyes
7506    then
7507      # Extract the first word of "esd-config", so it can be a program name with args.
7508 set dummy esd-config; ac_word=$2
7509 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7510 echo "configure:7511: checking for $ac_word" >&5
7511 if eval "test \"`echo '$''{'ac_cv_path_ESD_CONFIG'+set}'`\" = set"; then
7512   echo $ac_n "(cached) $ac_c" 1>&6
7513 else
7514   case "$ESD_CONFIG" in
7515   /*)
7516   ac_cv_path_ESD_CONFIG="$ESD_CONFIG" # Let the user override the test with a path.
7517   ;;
7518   ?:/*)                  
7519   ac_cv_path_ESD_CONFIG="$ESD_CONFIG" # Let the user override the test with a dos path.
7520   ;;
7521   *)
7522   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
7523   ac_dummy="$PATH"
7524   for ac_dir in $ac_dummy; do 
7525     test -z "$ac_dir" && ac_dir=.
7526     if test -f $ac_dir/$ac_word; then
7527       ac_cv_path_ESD_CONFIG="$ac_dir/$ac_word"
7528       break
7529     fi
7530   done
7531   IFS="$ac_save_ifs"
7532   test -z "$ac_cv_path_ESD_CONFIG" && ac_cv_path_ESD_CONFIG="no"
7533   ;;
7534 esac
7535 fi
7536 ESD_CONFIG="$ac_cv_path_ESD_CONFIG"
7537 if test -n "$ESD_CONFIG"; then
7538   echo "$ac_t""$ESD_CONFIG" 1>&6
7539 else
7540   echo "$ac_t""no" 1>&6
7541 fi
7542
7543      if test x${ESD_CONFIG} != xno
7544      then
7545        PLUGINS="${PLUGINS} esd"
7546        esd_CFLAGS="${esd_CFLAGS} `${ESD_CONFIG} --cflags`"
7547        esd_LDFLAGS="${esd_LDFLAGS} `${ESD_CONFIG} --libs`"
7548      fi
7549    fi
7550 fi
7551
7552
7553 # Check whether --enable-arts or --disable-arts was given.
7554 if test "${enable_arts+set}" = set; then
7555   enableval="$enable_arts"
7556   if test x$enable_arts = xyes
7557    then
7558      # Extract the first word of "artsc-config", so it can be a program name with args.
7559 set dummy artsc-config; ac_word=$2
7560 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7561 echo "configure:7562: checking for $ac_word" >&5
7562 if eval "test \"`echo '$''{'ac_cv_path_ARTS_CONFIG'+set}'`\" = set"; then
7563   echo $ac_n "(cached) $ac_c" 1>&6
7564 else
7565   case "$ARTS_CONFIG" in
7566   /*)
7567   ac_cv_path_ARTS_CONFIG="$ARTS_CONFIG" # Let the user override the test with a path.
7568   ;;
7569   ?:/*)                  
7570   ac_cv_path_ARTS_CONFIG="$ARTS_CONFIG" # Let the user override the test with a dos path.
7571   ;;
7572   *)
7573   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
7574   ac_dummy="$PATH"
7575   for ac_dir in $ac_dummy; do 
7576     test -z "$ac_dir" && ac_dir=.
7577     if test -f $ac_dir/$ac_word; then
7578       ac_cv_path_ARTS_CONFIG="$ac_dir/$ac_word"
7579       break
7580     fi
7581   done
7582   IFS="$ac_save_ifs"
7583   test -z "$ac_cv_path_ARTS_CONFIG" && ac_cv_path_ARTS_CONFIG="no"
7584   ;;
7585 esac
7586 fi
7587 ARTS_CONFIG="$ac_cv_path_ARTS_CONFIG"
7588 if test -n "$ARTS_CONFIG"; then
7589   echo "$ac_t""$ARTS_CONFIG" 1>&6
7590 else
7591   echo "$ac_t""no" 1>&6
7592 fi
7593
7594      if test x${ARTS_CONFIG} != xno
7595      then
7596        PLUGINS="${PLUGINS} arts"
7597        arts_CFLAGS="${arts_CFLAGS} `${ARTS_CONFIG} --cflags`"
7598        arts_LDFLAGS="${arts_LDFLAGS} `${ARTS_CONFIG} --libs `"
7599      fi
7600    fi
7601 fi
7602
7603
7604 # Check whether --enable-alsa or --disable-alsa was given.
7605 if test "${enable_alsa+set}" = set; then
7606   enableval="$enable_alsa"
7607   if test x$enable_alsa = xyes
7608    then
7609      ac_safe=`echo "alsa/asoundlib.h" | sed 'y%./+-%__p_%'`
7610 echo $ac_n "checking for alsa/asoundlib.h""... $ac_c" 1>&6
7611 echo "configure:7612: checking for alsa/asoundlib.h" >&5
7612 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
7613   echo $ac_n "(cached) $ac_c" 1>&6
7614 else
7615   cat > conftest.$ac_ext <<EOF
7616 #line 7617 "configure"
7617 #include "confdefs.h"
7618 #include <alsa/asoundlib.h>
7619 EOF
7620 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7621 { (eval echo configure:7622: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7622 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7623 if test -z "$ac_err"; then
7624   rm -rf conftest*
7625   eval "ac_cv_header_$ac_safe=yes"
7626 else
7627   echo "$ac_err" >&5
7628   echo "configure: failed program was:" >&5
7629   cat conftest.$ac_ext >&5
7630   rm -rf conftest*
7631   eval "ac_cv_header_$ac_safe=no"
7632 fi
7633 rm -f conftest*
7634 fi
7635 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
7636   echo "$ac_t""yes" 1>&6
7637   echo $ac_n "checking for main in -lasound""... $ac_c" 1>&6
7638 echo "configure:7639: checking for main in -lasound" >&5
7639 ac_lib_var=`echo asound'_'main | sed 'y%./+-%__p_%'`
7640 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
7641   echo $ac_n "(cached) $ac_c" 1>&6
7642 else
7643   ac_save_LIBS="$LIBS"
7644 LIBS="-lasound  $LIBS"
7645 cat > conftest.$ac_ext <<EOF
7646 #line 7647 "configure"
7647 #include "confdefs.h"
7648
7649 int main() {
7650 main()
7651 ; return 0; }
7652 EOF
7653 if { (eval echo configure:7654: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7654   rm -rf conftest*
7655   eval "ac_cv_lib_$ac_lib_var=yes"
7656 else
7657   echo "configure: failed program was:" >&5
7658   cat conftest.$ac_ext >&5
7659   rm -rf conftest*
7660   eval "ac_cv_lib_$ac_lib_var=no"
7661 fi
7662 rm -f conftest*
7663 LIBS="$ac_save_LIBS"
7664
7665 fi
7666 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
7667   echo "$ac_t""yes" 1>&6
7668   have_alsa="true"
7669 else
7670   echo "$ac_t""no" 1>&6
7671 have_alsa="false"
7672 fi
7673
7674 else
7675   echo "$ac_t""no" 1>&6
7676 have_alsa="false"
7677 fi
7678
7679      if test x$have_alsa = xtrue
7680      then
7681        PLUGINS="${PLUGINS} alsa"
7682        alsa_LDFLAGS="${alsa_LDFLAGS} -lasound -lm -ldl"
7683      fi
7684    fi
7685 fi
7686
7687
7688 # Check whether --enable-waveout or --disable-waveout was given.
7689 if test "${enable_waveout+set}" = set; then
7690   enableval="$enable_waveout"
7691   :
7692 fi
7693
7694 if test "x$enable_waveout" != "xno" -a x$SYS = xmingw32
7695   then
7696     PLUGINS="${PLUGINS} waveout"
7697     waveout_LDFLAGS="-lwinmm"
7698 fi
7699
7700
7701 # Check whether --with- or --without- was given.
7702 if test "${with_+set}" = set; then
7703   withval="$with_"
7704   :
7705 fi
7706
7707
7708 # Check whether --enable-gtk or --disable-gtk was given.
7709 if test "${enable_gtk+set}" = set; then
7710   enableval="$enable_gtk"
7711   :
7712 fi
7713
7714 if test x$enable_gtk != xno
7715 then
7716   GTK_PATH=$PATH
7717   # Check whether --with-gtk-config-path or --without-gtk-config-path was given.
7718 if test "${with_gtk_config_path+set}" = set; then
7719   withval="$with_gtk_config_path"
7720    if test "x$with_gtk_config_path" != "xno"
7721       then
7722         GTK_PATH="$with_gtk_config_path:$PATH"
7723       fi 
7724 fi
7725
7726   # look for gtk-config
7727   # Extract the first word of "gtk12-config", so it can be a program name with args.
7728 set dummy gtk12-config; ac_word=$2
7729 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7730 echo "configure:7731: checking for $ac_word" >&5
7731 if eval "test \"`echo '$''{'ac_cv_path_GTK12_CONFIG'+set}'`\" = set"; then
7732   echo $ac_n "(cached) $ac_c" 1>&6
7733 else
7734   case "$GTK12_CONFIG" in
7735   /*)
7736   ac_cv_path_GTK12_CONFIG="$GTK12_CONFIG" # Let the user override the test with a path.
7737   ;;
7738   ?:/*)                  
7739   ac_cv_path_GTK12_CONFIG="$GTK12_CONFIG" # Let the user override the test with a dos path.
7740   ;;
7741   *)
7742   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
7743   ac_dummy="$GTK_PATH"
7744   for ac_dir in $ac_dummy; do 
7745     test -z "$ac_dir" && ac_dir=.
7746     if test -f $ac_dir/$ac_word; then
7747       ac_cv_path_GTK12_CONFIG="$ac_dir/$ac_word"
7748       break
7749     fi
7750   done
7751   IFS="$ac_save_ifs"
7752   test -z "$ac_cv_path_GTK12_CONFIG" && ac_cv_path_GTK12_CONFIG="no"
7753   ;;
7754 esac
7755 fi
7756 GTK12_CONFIG="$ac_cv_path_GTK12_CONFIG"
7757 if test -n "$GTK12_CONFIG"; then
7758   echo "$ac_t""$GTK12_CONFIG" 1>&6
7759 else
7760   echo "$ac_t""no" 1>&6
7761 fi
7762
7763   GTK_CONFIG=${GTK12_CONFIG}
7764   if test x${GTK_CONFIG} = xno
7765   then
7766     # Extract the first word of "gtk-config", so it can be a program name with args.
7767 set dummy gtk-config; ac_word=$2
7768 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7769 echo "configure:7770: checking for $ac_word" >&5
7770 if eval "test \"`echo '$''{'ac_cv_path_GTK_CONFIG'+set}'`\" = set"; then
7771   echo $ac_n "(cached) $ac_c" 1>&6
7772 else
7773   case "$GTK_CONFIG" in
7774   /*)
7775   ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a path.
7776   ;;
7777   ?:/*)                  
7778   ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a dos path.
7779   ;;
7780   *)
7781   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
7782   ac_dummy="$GTK_PATH"
7783   for ac_dir in $ac_dummy; do 
7784     test -z "$ac_dir" && ac_dir=.
7785     if test -f $ac_dir/$ac_word; then
7786       ac_cv_path_GTK_CONFIG="$ac_dir/$ac_word"
7787       break
7788     fi
7789   done
7790   IFS="$ac_save_ifs"
7791   test -z "$ac_cv_path_GTK_CONFIG" && ac_cv_path_GTK_CONFIG="no"
7792   ;;
7793 esac
7794 fi
7795 GTK_CONFIG="$ac_cv_path_GTK_CONFIG"
7796 if test -n "$GTK_CONFIG"; then
7797   echo "$ac_t""$GTK_CONFIG" 1>&6
7798 else
7799   echo "$ac_t""no" 1>&6
7800 fi
7801
7802   fi
7803   if test x${GTK_CONFIG} != xno
7804   then
7805     if expr 1.2.0 \> `$GTK_CONFIG --version` >/dev/null
7806     then
7807       { echo "configure: error: Your development package for Gtk+ is too old, you need at least version 1.2.0. Please upgrade and try again. Alternatively you can also configure with --disable-gtk." 1>&2; exit 1; }
7808     fi
7809     gtk_CFLAGS="${gtk_CFLAGS} `${GTK_CONFIG} --cflags gtk`"
7810     gtk_LDFLAGS="${gtk_LDFLAGS} `${GTK_CONFIG} --libs gtk | sed 's,-rdynamic,,'`"
7811     # now look for the gtk.h header
7812     CPPFLAGS="$save_CPPFLAGS $gtk_CFLAGS"
7813     ac_cv_gtk_headers=yes
7814     for ac_hdr in gtk/gtk.h glib.h gdk/gdk.h
7815 do
7816 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
7817 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7818 echo "configure:7819: checking for $ac_hdr" >&5
7819 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
7820   echo $ac_n "(cached) $ac_c" 1>&6
7821 else
7822   cat > conftest.$ac_ext <<EOF
7823 #line 7824 "configure"
7824 #include "confdefs.h"
7825 #include <$ac_hdr>
7826 EOF
7827 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7828 { (eval echo configure:7829: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7829 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7830 if test -z "$ac_err"; then
7831   rm -rf conftest*
7832   eval "ac_cv_header_$ac_safe=yes"
7833 else
7834   echo "$ac_err" >&5
7835   echo "configure: failed program was:" >&5
7836   cat conftest.$ac_ext >&5
7837   rm -rf conftest*
7838   eval "ac_cv_header_$ac_safe=no"
7839 fi
7840 rm -f conftest*
7841 fi
7842 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
7843   echo "$ac_t""yes" 1>&6
7844     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
7845   cat >> confdefs.h <<EOF
7846 #define $ac_tr_hdr 1
7847 EOF
7848  
7849 else
7850   echo "$ac_t""no" 1>&6
7851 ac_cv_gtk_headers=no
7852       echo "Cannot find gtk development headers."
7853     
7854 fi
7855 done
7856
7857     if test "x$ac_cv_gtk_headers" = xyes
7858     then
7859       PLUGINS="${PLUGINS} gtk"
7860       ALIASES="${ALIASES} gvlc"
7861     fi
7862     CPPFLAGS="$save_CPPFLAGS"
7863   fi
7864 fi
7865
7866 # Check whether --enable-gnome or --disable-gnome was given.
7867 if test "${enable_gnome+set}" = set; then
7868   enableval="$enable_gnome"
7869   if test x$enable_gnome = xyes; then
7870     # look for gnome-config
7871     # Extract the first word of "gnome-config", so it can be a program name with args.
7872 set dummy gnome-config; ac_word=$2
7873 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7874 echo "configure:7875: checking for $ac_word" >&5
7875 if eval "test \"`echo '$''{'ac_cv_path_GNOME_CONFIG'+set}'`\" = set"; then
7876   echo $ac_n "(cached) $ac_c" 1>&6
7877 else
7878   case "$GNOME_CONFIG" in
7879   /*)
7880   ac_cv_path_GNOME_CONFIG="$GNOME_CONFIG" # Let the user override the test with a path.
7881   ;;
7882   ?:/*)                  
7883   ac_cv_path_GNOME_CONFIG="$GNOME_CONFIG" # Let the user override the test with a dos path.
7884   ;;
7885   *)
7886   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
7887   ac_dummy="$PATH"
7888   for ac_dir in $ac_dummy; do 
7889     test -z "$ac_dir" && ac_dir=.
7890     if test -f $ac_dir/$ac_word; then
7891       ac_cv_path_GNOME_CONFIG="$ac_dir/$ac_word"
7892       break
7893     fi
7894   done
7895   IFS="$ac_save_ifs"
7896   test -z "$ac_cv_path_GNOME_CONFIG" && ac_cv_path_GNOME_CONFIG="no"
7897   ;;
7898 esac
7899 fi
7900 GNOME_CONFIG="$ac_cv_path_GNOME_CONFIG"
7901 if test -n "$GNOME_CONFIG"; then
7902   echo "$ac_t""$GNOME_CONFIG" 1>&6
7903 else
7904   echo "$ac_t""no" 1>&6
7905 fi
7906
7907     if test -x ${GNOME_CONFIG}
7908     then
7909        gnome_CFLAGS="${gnome_CFLAGS} `${GNOME_CONFIG} --cflags gtk gnomeui`"
7910        gnome_LDFLAGS="${gnome_LDFLAGS} `${GNOME_CONFIG} --libs gnomeui | sed 's,-rdynamic,,'`"
7911     fi
7912     # now look for the gnome.h header
7913     CPPFLAGS="$save_CPPFLAGS $gnome_CFLAGS"
7914     for ac_hdr in gnome.h
7915 do
7916 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
7917 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7918 echo "configure:7919: checking for $ac_hdr" >&5
7919 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
7920   echo $ac_n "(cached) $ac_c" 1>&6
7921 else
7922   cat > conftest.$ac_ext <<EOF
7923 #line 7924 "configure"
7924 #include "confdefs.h"
7925 #include <$ac_hdr>
7926 EOF
7927 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7928 { (eval echo configure:7929: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7929 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7930 if test -z "$ac_err"; then
7931   rm -rf conftest*
7932   eval "ac_cv_header_$ac_safe=yes"
7933 else
7934   echo "$ac_err" >&5
7935   echo "configure: failed program was:" >&5
7936   cat conftest.$ac_ext >&5
7937   rm -rf conftest*
7938   eval "ac_cv_header_$ac_safe=no"
7939 fi
7940 rm -f conftest*
7941 fi
7942 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
7943   echo "$ac_t""yes" 1>&6
7944     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
7945   cat >> confdefs.h <<EOF
7946 #define $ac_tr_hdr 1
7947 EOF
7948  
7949       PLUGINS="${PLUGINS} gnome"
7950       ALIASES="${ALIASES} gnome-vlc"
7951      
7952 else
7953   echo "$ac_t""no" 1>&6
7954 { echo "configure: error: Can't find gnome headers. Please install the gnome
7955 developement tools or remove the --enable-gnome option" 1>&2; exit 1; }
7956      
7957 fi
7958 done
7959
7960     CPPFLAGS="$save_CPPFLAGS"
7961   fi
7962 fi
7963
7964
7965 # Check whether --enable-qt or --disable-qt was given.
7966 if test "${enable_qt+set}" = set; then
7967   enableval="$enable_qt"
7968   if test x$enable_qt = xyes; then
7969      PLUGINS="${PLUGINS} qt"
7970      ALIASES="${ALIASES} qvlc"
7971      qt_LDFLAGS="${qt_LDFLAGS} -lqt -L${QTDIR}/lib"
7972      qt_CFLAGS="${qt_CFLAGS} -I/usr/include/qt -I${QTDIR}/include"
7973      if test -x ${QTDIR}/bin/moc
7974      then
7975        MOC=${QTDIR}/bin/moc
7976      else
7977        MOC=moc
7978      fi
7979    fi
7980 fi
7981
7982
7983 # Check whether --enable-kde or --disable-kde was given.
7984 if test "${enable_kde+set}" = set; then
7985   enableval="$enable_kde"
7986   if test x$enable_kde = xyes; then
7987      PLUGINS="${PLUGINS} kde"
7988      ALIASES="${ALIASES} kvlc"
7989      kde_LDFLAGS="${kde_LDFLAGS} -L${KDEDIR}/lib -lkfile"
7990      kde_CFLAGS="${kde_CFLAGS} -I/usr/include/kde -I/usr/include/qt"
7991      kde_CFLAGS="${kde_CFLAGS} -I${KDEDIR}/include -I${QTDIR}/include"
7992      if test -x ${QTDIR}/bin/moc
7993      then
7994        MOC=${QTDIR}/bin/moc
7995      else
7996        MOC=moc
7997      fi
7998    fi
7999 fi
8000
8001
8002 # Check whether --enable-macosx or --disable-macosx was given.
8003 if test "${enable_macosx+set}" = set; then
8004   enableval="$enable_macosx"
8005   if test x$enable_macosx = xyes
8006    then
8007      BUILTINS="${BUILTINS} macosx"
8008      macosx_LDFLAGS="${macosx_LDFLAGS} -framework CoreAudio -framework AudioToolbox -framework IOKit -framework Cocoa -framework AGL -framework QuickTime -lobjc -ObjC"
8009    fi
8010 else
8011   for ac_hdr in Cocoa/Cocoa.h
8012 do
8013 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
8014 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
8015 echo "configure:8016: checking for $ac_hdr" >&5
8016 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
8017   echo $ac_n "(cached) $ac_c" 1>&6
8018 else
8019   cat > conftest.$ac_ext <<EOF
8020 #line 8021 "configure"
8021 #include "confdefs.h"
8022 #include <$ac_hdr>
8023 EOF
8024 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
8025 { (eval echo configure:8026: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8026 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
8027 if test -z "$ac_err"; then
8028   rm -rf conftest*
8029   eval "ac_cv_header_$ac_safe=yes"
8030 else
8031   echo "$ac_err" >&5
8032   echo "configure: failed program was:" >&5
8033   cat conftest.$ac_ext >&5
8034   rm -rf conftest*
8035   eval "ac_cv_header_$ac_safe=no"
8036 fi
8037 rm -f conftest*
8038 fi
8039 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
8040   echo "$ac_t""yes" 1>&6
8041     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
8042   cat >> confdefs.h <<EOF
8043 #define $ac_tr_hdr 1
8044 EOF
8045  BUILTINS="${BUILTINS} macosx"
8046      macosx_LDFLAGS="${macosx_LDFLAGS} -framework CoreAudio -framework AudioToolbox -framework IOKit -framework Cocoa -framework AGL -framework QuickTime -lobjc -ObjC"
8047    
8048 else
8049   echo "$ac_t""no" 1>&6
8050 fi
8051 done
8052
8053 fi
8054
8055
8056 # Check whether --enable-qnx or --disable-qnx was given.
8057 if test "${enable_qnx+set}" = set; then
8058   enableval="$enable_qnx"
8059   :
8060 fi
8061
8062     if test x$enable_qnx != xno
8063     then
8064       for ac_hdr in Ph.h
8065 do
8066 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
8067 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
8068 echo "configure:8069: checking for $ac_hdr" >&5
8069 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
8070   echo $ac_n "(cached) $ac_c" 1>&6
8071 else
8072   cat > conftest.$ac_ext <<EOF
8073 #line 8074 "configure"
8074 #include "confdefs.h"
8075 #include <$ac_hdr>
8076 EOF
8077 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
8078 { (eval echo configure:8079: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8079 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
8080 if test -z "$ac_err"; then
8081   rm -rf conftest*
8082   eval "ac_cv_header_$ac_safe=yes"
8083 else
8084   echo "$ac_err" >&5
8085   echo "configure: failed program was:" >&5
8086   cat conftest.$ac_ext >&5
8087   rm -rf conftest*
8088   eval "ac_cv_header_$ac_safe=no"
8089 fi
8090 rm -f conftest*
8091 fi
8092 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
8093   echo "$ac_t""yes" 1>&6
8094     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
8095   cat >> confdefs.h <<EOF
8096 #define $ac_tr_hdr 1
8097 EOF
8098  
8099         PLUGINS="${PLUGINS} qnx"
8100         qnx_LDFLAGS="${qnx_LDFLAGS} -lasound -lph"
8101       
8102 else
8103   echo "$ac_t""no" 1>&6
8104 fi
8105 done
8106
8107     fi
8108
8109 # Check whether --enable-intfwin or --disable-intfwin was given.
8110 if test "${enable_intfwin+set}" = set; then
8111   enableval="$enable_intfwin"
8112    if test "x$enable_intfwin" != "xno"
8113   then
8114     # Check whether --with-bcbuilder or --without-bcbuilder was given.
8115 if test "${with_bcbuilder+set}" = set; then
8116   withval="$with_bcbuilder"
8117   :
8118 fi
8119
8120     if test "x$with_bcbuilder" != "x"
8121     then
8122       BCBUILDER="$with_bcbuilder"
8123     fi
8124     PLUGINS="${PLUGINS} intfwin"
8125   fi 
8126 fi
8127
8128
8129 # Check whether --enable-ncurses or --disable-ncurses was given.
8130 if test "${enable_ncurses+set}" = set; then
8131   enableval="$enable_ncurses"
8132   if test x$enable_ncurses = xyes; then
8133      PLUGINS="${PLUGINS} ncurses"
8134      ncurses_LDFLAGS="${ncurses_LDFLAGS} -lncurses"
8135    fi
8136 fi
8137
8138
8139 # Check whether --enable-lirc or --disable-lirc was given.
8140 if test "${enable_lirc+set}" = set; then
8141   enableval="$enable_lirc"
8142   :
8143 fi
8144
8145 if test x$enable_lirc = xyes
8146 then
8147   ac_safe=`echo "lirc/lirc_client.h" | sed 'y%./+-%__p_%'`
8148 echo $ac_n "checking for lirc/lirc_client.h""... $ac_c" 1>&6
8149 echo "configure:8150: checking for lirc/lirc_client.h" >&5
8150 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
8151   echo $ac_n "(cached) $ac_c" 1>&6
8152 else
8153   cat > conftest.$ac_ext <<EOF
8154 #line 8155 "configure"
8155 #include "confdefs.h"
8156 #include <lirc/lirc_client.h>
8157 EOF
8158 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
8159 { (eval echo configure:8160: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8160 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
8161 if test -z "$ac_err"; then
8162   rm -rf conftest*
8163   eval "ac_cv_header_$ac_safe=yes"
8164 else
8165   echo "$ac_err" >&5
8166   echo "configure: failed program was:" >&5
8167   cat conftest.$ac_ext >&5
8168   rm -rf conftest*
8169   eval "ac_cv_header_$ac_safe=no"
8170 fi
8171 rm -f conftest*
8172 fi
8173 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
8174   echo "$ac_t""yes" 1>&6
8175   echo $ac_n "checking for lirc_init in -llirc_client""... $ac_c" 1>&6
8176 echo "configure:8177: checking for lirc_init in -llirc_client" >&5
8177 ac_lib_var=`echo lirc_client'_'lirc_init | sed 'y%./+-%__p_%'`
8178 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
8179   echo $ac_n "(cached) $ac_c" 1>&6
8180 else
8181   ac_save_LIBS="$LIBS"
8182 LIBS="-llirc_client  $LIBS"
8183 cat > conftest.$ac_ext <<EOF
8184 #line 8185 "configure"
8185 #include "confdefs.h"
8186 /* Override any gcc2 internal prototype to avoid an error.  */
8187 /* We use char because int might match the return type of a gcc2
8188     builtin and then its argument prototype would still apply.  */
8189 char lirc_init();
8190
8191 int main() {
8192 lirc_init()
8193 ; return 0; }
8194 EOF
8195 if { (eval echo configure:8196: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8196   rm -rf conftest*
8197   eval "ac_cv_lib_$ac_lib_var=yes"
8198 else
8199   echo "configure: failed program was:" >&5
8200   cat conftest.$ac_ext >&5
8201   rm -rf conftest*
8202   eval "ac_cv_lib_$ac_lib_var=no"
8203 fi
8204 rm -f conftest*
8205 LIBS="$ac_save_LIBS"
8206
8207 fi
8208 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
8209   echo "$ac_t""yes" 1>&6
8210   have_lirc="true"
8211 else
8212   echo "$ac_t""no" 1>&6
8213 have_lirc="false"
8214 fi
8215
8216 else
8217   echo "$ac_t""no" 1>&6
8218 have_lirc="false"
8219 fi
8220
8221   if test x$have_lirc = xtrue
8222   then
8223     PLUGINS="${PLUGINS} lirc"
8224     lirc_LDFLAGS="${lirc_LDFLAGS} -llirc_client"
8225   fi
8226 fi
8227
8228 # Check whether --with- or --without- was given.
8229 if test "${with_+set}" = set; then
8230   withval="$with_"
8231   :
8232 fi
8233
8234
8235 # Check whether --with-words or --without-words was given.
8236 if test "${with_words+set}" = set; then
8237   withval="$with_words"
8238   :
8239 fi
8240
8241   case "x$with_words" in
8242     xbig)
8243       ac_cv_c_bigendian=yes
8244       ;;
8245     xlittle)
8246       ac_cv_c_bigendian=no
8247       ;;
8248     *)
8249                   echo $ac_n "checking whether the byte order is big-endian""... $ac_c" 1>&6
8250 echo "configure:8251: checking whether the byte order is big-endian" >&5
8251 if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
8252   echo $ac_n "(cached) $ac_c" 1>&6
8253 else
8254   ac_cv_c_bigendian=unknown
8255         cat >conftest.c <<EOF
8256         short am[] = { 0x4249, 0x4765, 0x6e44, 0x6961, 0x6e53, 0x7953, 0 };
8257         short ai[] = { 0x694c, 0x5454, 0x656c, 0x6e45, 0x6944, 0x6e61, 0 };
8258         void _a(void) { char*s = (char*)am; s = (char *)ai; }
8259         short ei[] = { 0x89D3, 0xe3e3, 0x8593, 0x95c5, 0x89c4, 0x9581, 0 };
8260         short em[] = { 0xc2c9, 0xc785, 0x95c4, 0x8981, 0x95e2, 0xa8e2, 0 };
8261         void _e(void) { char*s = (char*)em; s = (char*)ei; }
8262         int main(void) { _a(); _e(); return 0; }
8263 EOF
8264         
8265         if test -f conftest.c
8266         then 
8267           if ${CC-cc} -c conftest.c -o conftest.o >config.log 2>&1 \
8268               && test -f conftest.o
8269           then
8270             if test "`strings conftest.o | grep BIGenDianSyS`"
8271             then
8272               ac_cv_c_bigendian=yes
8273             fi
8274             if test "`strings conftest.o | grep LiTTleEnDian`"
8275             then
8276               ac_cv_c_bigendian=no
8277             fi
8278           fi
8279         fi
8280       
8281 fi
8282
8283 echo "$ac_t""$ac_cv_c_bigendian" 1>&6
8284       if test x$ac_cv_c_bigendian = xunknown
8285       then
8286         { echo "configure: error: Could not guess endianness, please use --with-words" 1>&2; exit 1; }
8287       fi
8288       ;;
8289   esac
8290 if test $ac_cv_c_bigendian = yes
8291 then
8292   cat >> confdefs.h <<\EOF
8293 #define WORDS_BIGENDIAN 1
8294 EOF
8295
8296 fi
8297
8298 GPROF=0
8299 # Check whether --enable-gprof or --disable-gprof was given.
8300 if test "${enable_gprof+set}" = set; then
8301   enableval="$enable_gprof"
8302    if test "x$enable_gprof" = "xyes"; then GPROF=1; fi 
8303 fi
8304
8305
8306 CPROF=0
8307 # Check whether --enable-cprof or --disable-cprof was given.
8308 if test "${enable_cprof+set}" = set; then
8309   enableval="$enable_cprof"
8310    if test "x$enable_cprof" = "xyes";
8311   then
8312     LDFLAGS="${LDFLAGS} -lcprof"
8313     CPROF=1
8314   fi
8315
8316 fi
8317
8318
8319 # Check whether --enable-pth or --disable-pth was given.
8320 if test "${enable_pth+set}" = set; then
8321   enableval="$enable_pth"
8322    if test "x$enable_pth" = "xyes"; then
8323     echo $ac_n "checking for pth_init in -lpth""... $ac_c" 1>&6
8324 echo "configure:8325: checking for pth_init in -lpth" >&5
8325 ac_lib_var=`echo pth'_'pth_init | sed 'y%./+-%__p_%'`
8326 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
8327   echo $ac_n "(cached) $ac_c" 1>&6
8328 else
8329   ac_save_LIBS="$LIBS"
8330 LIBS="-lpth  $LIBS"
8331 cat > conftest.$ac_ext <<EOF
8332 #line 8333 "configure"
8333 #include "confdefs.h"
8334 /* Override any gcc2 internal prototype to avoid an error.  */
8335 /* We use char because int might match the return type of a gcc2
8336     builtin and then its argument prototype would still apply.  */
8337 char pth_init();
8338
8339 int main() {
8340 pth_init()
8341 ; return 0; }
8342 EOF
8343 if { (eval echo configure:8344: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8344   rm -rf conftest*
8345   eval "ac_cv_lib_$ac_lib_var=yes"
8346 else
8347   echo "configure: failed program was:" >&5
8348   cat conftest.$ac_ext >&5
8349   rm -rf conftest*
8350   eval "ac_cv_lib_$ac_lib_var=no"
8351 fi
8352 rm -f conftest*
8353 LIBS="$ac_save_LIBS"
8354
8355 fi
8356 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
8357   echo "$ac_t""yes" 1>&6
8358     ac_tr_lib=HAVE_LIB`echo pth | sed -e 's/[^a-zA-Z0-9_]/_/g' \
8359     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
8360   cat >> confdefs.h <<EOF
8361 #define $ac_tr_lib 1
8362 EOF
8363
8364   LIBS="-lpth $LIBS"
8365
8366 else
8367   echo "$ac_t""no" 1>&6
8368 fi
8369
8370     cat > conftest.$ac_ext <<EOF
8371 #line 8372 "configure"
8372 #include "confdefs.h"
8373 #include <pth.h>
8374 EOF
8375 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8376   egrep "pth_init" >/dev/null 2>&1; then
8377   rm -rf conftest*
8378   
8379       cat >> confdefs.h <<\EOF
8380 #define PTH_INIT_IN_PTH_H 1
8381 EOF
8382
8383     THREAD_LIB="-lpth"
8384     fi
8385 fi
8386 rm -f conftest*
8387
8388
8389 fi
8390
8391
8392 # Check whether --enable-st or --disable-st was given.
8393 if test "${enable_st+set}" = set; then
8394   enableval="$enable_st"
8395    if test "x$enable_st" = "xyes"; then
8396     echo $ac_n "checking for st_init in -lst""... $ac_c" 1>&6
8397 echo "configure:8398: checking for st_init in -lst" >&5
8398 ac_lib_var=`echo st'_'st_init | sed 'y%./+-%__p_%'`
8399 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
8400   echo $ac_n "(cached) $ac_c" 1>&6
8401 else
8402   ac_save_LIBS="$LIBS"
8403 LIBS="-lst  $LIBS"
8404 cat > conftest.$ac_ext <<EOF
8405 #line 8406 "configure"
8406 #include "confdefs.h"
8407 /* Override any gcc2 internal prototype to avoid an error.  */
8408 /* We use char because int might match the return type of a gcc2
8409     builtin and then its argument prototype would still apply.  */
8410 char st_init();
8411
8412 int main() {
8413 st_init()
8414 ; return 0; }
8415 EOF
8416 if { (eval echo configure:8417: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8417   rm -rf conftest*
8418   eval "ac_cv_lib_$ac_lib_var=yes"
8419 else
8420   echo "configure: failed program was:" >&5
8421   cat conftest.$ac_ext >&5
8422   rm -rf conftest*
8423   eval "ac_cv_lib_$ac_lib_var=no"
8424 fi
8425 rm -f conftest*
8426 LIBS="$ac_save_LIBS"
8427
8428 fi
8429 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
8430   echo "$ac_t""yes" 1>&6
8431     ac_tr_lib=HAVE_LIB`echo st | sed -e 's/[^a-zA-Z0-9_]/_/g' \
8432     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
8433   cat >> confdefs.h <<EOF
8434 #define $ac_tr_lib 1
8435 EOF
8436
8437   LIBS="-lst $LIBS"
8438
8439 else
8440   echo "$ac_t""no" 1>&6
8441 fi
8442
8443     cat > conftest.$ac_ext <<EOF
8444 #line 8445 "configure"
8445 #include "confdefs.h"
8446 #include <st.h>
8447 EOF
8448 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8449   egrep "st_init" >/dev/null 2>&1; then
8450   rm -rf conftest*
8451   
8452       cat >> confdefs.h <<\EOF
8453 #define ST_INIT_IN_ST_H 1
8454 EOF
8455
8456     THREAD_LIB="-lst"
8457     fi
8458 fi
8459 rm -f conftest*
8460
8461
8462 fi
8463
8464
8465 LDFLAGS="${LDFLAGS} ${THREAD_LIB}"
8466
8467 # Check whether --enable-plugins or --disable-plugins was given.
8468 if test "${enable_plugins+set}" = set; then
8469   enableval="$enable_plugins"
8470   if test x$enable_plugins = xno
8471    then
8472      BUILTINS="${BUILTINS} ${PLUGINS}"
8473      PLUGINS=
8474    fi
8475 fi
8476
8477
8478 if test x$ac_cv_header_dlfcn_h = xno -a x$ac_cv_header_image_h = xno -a x$SYS != xmingw32
8479 then
8480   echo "*** Your system doesn't have plug-in support. All plug-ins will be compiled"
8481   echo "as built-in"
8482   BUILTINS="${BUILTINS} ${PLUGINS}"
8483   PLUGINS=
8484 fi
8485
8486 cat >> confdefs.h <<EOF
8487 #define VERSION_MESSAGE "vlc $VERSION $CODENAME Copyright 1996-2002 VideoLAN"
8488 EOF
8489
8490 cat >> confdefs.h <<EOF
8491 #define COPYRIGHT_MESSAGE "VideoLAN Client - version $VERSION $CODENAME - (c) 1996-2002 VideoLAN"
8492 EOF
8493
8494
8495 VLC_SYMBOL="`echo ${VERSION} | tr .- __`"
8496 cat >> confdefs.h <<EOF
8497 #define MODULE_SUFFIX "__MODULE_$VLC_SYMBOL"
8498 EOF
8499
8500 cat >> confdefs.h <<EOF
8501 #define MODULE_SYMBOL $VLC_SYMBOL
8502 EOF
8503
8504
8505 DATA_PATH="${ac_tool_prefix}/share/videolan"
8506
8507 PLUGIN_PATH="${ac_tool_prefix}/share/videolan"
8508
8509
8510
8511
8512
8513
8514
8515
8516
8517
8518
8519
8520
8521
8522
8523
8524
8525
8526
8527
8528
8529
8530
8531
8532
8533
8534
8535
8536
8537
8538
8539
8540
8541
8542
8543
8544
8545
8546
8547
8548
8549
8550
8551
8552
8553
8554
8555
8556
8557
8558
8559
8560
8561
8562
8563
8564
8565
8566
8567
8568
8569
8570
8571
8572
8573
8574
8575
8576
8577
8578
8579
8580
8581
8582
8583
8584
8585
8586
8587
8588
8589
8590
8591
8592
8593
8594
8595
8596
8597
8598
8599
8600
8601
8602
8603 trap '' 1 2 15
8604 cat > confcache <<\EOF
8605 # This file is a shell script that caches the results of configure
8606 # tests run on this system so they can be shared between configure
8607 # scripts and configure runs.  It is not useful on other systems.
8608 # If it contains results you don't want to keep, you may remove or edit it.
8609 #
8610 # By default, configure uses ./config.cache as the cache file,
8611 # creating it if it does not exist already.  You can give configure
8612 # the --cache-file=FILE option to use a different cache file; that is
8613 # what configure does when it calls configure scripts in
8614 # subdirectories, so they share the cache.
8615 # Giving --cache-file=/dev/null disables caching, for debugging configure.
8616 # config.status only pays attention to the cache file if you give it the
8617 # --recheck option to rerun configure.
8618 #
8619 EOF
8620 # The following way of writing the cache mishandles newlines in values,
8621 # but we know of no workaround that is simple, portable, and efficient.
8622 # So, don't put newlines in cache variables' values.
8623 # Ultrix sh set writes to stderr and can't be redirected directly,
8624 # and sets the high bit in the cache file unless we assign to the vars.
8625 (set) 2>&1 |
8626   case `(ac_space=' '; set | grep ac_space) 2>&1` in
8627   *ac_space=\ *)
8628     # `set' does not quote correctly, so add quotes (double-quote substitution
8629     # turns \\\\ into \\, and sed turns \\ into \).
8630     sed -n \
8631       -e "s/'/'\\\\''/g" \
8632       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
8633     ;;
8634   *)
8635     # `set' quotes correctly as required by POSIX, so do not add quotes.
8636     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
8637     ;;
8638   esac >> confcache
8639 if cmp -s $cache_file confcache; then
8640   :
8641 else
8642   if test -w $cache_file; then
8643     echo "updating cache $cache_file"
8644     cat confcache > $cache_file
8645   else
8646     echo "not updating unwritable cache $cache_file"
8647   fi
8648 fi
8649 rm -f confcache
8650
8651 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
8652
8653 test "x$prefix" = xNONE && prefix=$ac_default_prefix
8654 # Let make expand exec_prefix.
8655 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
8656
8657 # Any assignment to VPATH causes Sun make to only execute
8658 # the first set of double-colon rules, so remove it if not needed.
8659 # If there is a colon in the path, we need to keep it.
8660 if test "x$srcdir" = x.; then
8661   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
8662 fi
8663
8664 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
8665
8666 DEFS=-DHAVE_CONFIG_H
8667
8668 # Without the "./", some shells look in PATH for config.status.
8669 : ${CONFIG_STATUS=./config.status}
8670
8671 echo creating $CONFIG_STATUS
8672 rm -f $CONFIG_STATUS
8673 cat > $CONFIG_STATUS <<EOF
8674 #! /bin/sh
8675 # Generated automatically by configure.
8676 # Run this file to recreate the current configuration.
8677 # This directory was configured as follows,
8678 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
8679 #
8680 # $0 $ac_configure_args
8681 #
8682 # Compiler output produced by configure, useful for debugging
8683 # configure, is in ./config.log if it exists.
8684
8685 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
8686 for ac_option
8687 do
8688   case "\$ac_option" in
8689   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
8690     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
8691     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
8692   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
8693     echo "$CONFIG_STATUS generated by autoconf version 2.13"
8694     exit 0 ;;
8695   -help | --help | --hel | --he | --h)
8696     echo "\$ac_cs_usage"; exit 0 ;;
8697   *) echo "\$ac_cs_usage"; exit 1 ;;
8698   esac
8699 done
8700
8701 ac_given_srcdir=$srcdir
8702 ac_given_INSTALL="$INSTALL"
8703
8704 trap 'rm -fr `echo "Makefile.opts po/Makefile.in include/defs.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
8705 EOF
8706 cat >> $CONFIG_STATUS <<EOF
8707
8708 # Protect against being on the right side of a sed subst in config.status.
8709 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
8710  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
8711 $ac_vpsub
8712 $extrasub
8713 s%@SHELL@%$SHELL%g
8714 s%@CFLAGS@%$CFLAGS%g
8715 s%@CPPFLAGS@%$CPPFLAGS%g
8716 s%@CXXFLAGS@%$CXXFLAGS%g
8717 s%@FFLAGS@%$FFLAGS%g
8718 s%@DEFS@%$DEFS%g
8719 s%@LDFLAGS@%$LDFLAGS%g
8720 s%@LIBS@%$LIBS%g
8721 s%@exec_prefix@%$exec_prefix%g
8722 s%@prefix@%$prefix%g
8723 s%@program_transform_name@%$program_transform_name%g
8724 s%@bindir@%$bindir%g
8725 s%@sbindir@%$sbindir%g
8726 s%@libexecdir@%$libexecdir%g
8727 s%@datadir@%$datadir%g
8728 s%@sysconfdir@%$sysconfdir%g
8729 s%@sharedstatedir@%$sharedstatedir%g
8730 s%@localstatedir@%$localstatedir%g
8731 s%@libdir@%$libdir%g
8732 s%@includedir@%$includedir%g
8733 s%@oldincludedir@%$oldincludedir%g
8734 s%@infodir@%$infodir%g
8735 s%@mandir@%$mandir%g
8736 s%@host@%$host%g
8737 s%@host_alias@%$host_alias%g
8738 s%@host_cpu@%$host_cpu%g
8739 s%@host_vendor@%$host_vendor%g
8740 s%@host_os@%$host_os%g
8741 s%@target@%$target%g
8742 s%@target_alias@%$target_alias%g
8743 s%@target_cpu@%$target_cpu%g
8744 s%@target_vendor@%$target_vendor%g
8745 s%@target_os@%$target_os%g
8746 s%@build@%$build%g
8747 s%@build_alias@%$build_alias%g
8748 s%@build_cpu@%$build_cpu%g
8749 s%@build_vendor@%$build_vendor%g
8750 s%@build_os@%$build_os%g
8751 s%@SET_MAKE@%$SET_MAKE%g
8752 s%@CC@%$CC%g
8753 s%@CPP@%$CPP%g
8754 s%@RANLIB@%$RANLIB%g
8755 s%@STRIP@%$STRIP%g
8756 s%@GMAKE@%$GMAKE%g
8757 s%@ALLOCA@%$ALLOCA%g
8758 s%@GLIBC21@%$GLIBC21%g
8759 s%@LIBICONV@%$LIBICONV%g
8760 s%@USE_NLS@%$USE_NLS%g
8761 s%@MSGFMT@%$MSGFMT%g
8762 s%@GMSGFMT@%$GMSGFMT%g
8763 s%@XGETTEXT@%$XGETTEXT%g
8764 s%@INTLBISON@%$INTLBISON%g
8765 s%@BUILD_INCLUDED_LIBINTL@%$BUILD_INCLUDED_LIBINTL%g
8766 s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
8767 s%@CATALOGS@%$CATALOGS%g
8768 s%@CATOBJEXT@%$CATOBJEXT%g
8769 s%@GMOFILES@%$GMOFILES%g
8770 s%@INTLLIBS@%$INTLLIBS%g
8771 s%@INTLOBJS@%$INTLOBJS%g
8772 s%@POFILES@%$POFILES%g
8773 s%@POSUB@%$POSUB%g
8774 s%@DATADIRNAME@%$DATADIRNAME%g
8775 s%@INSTOBJEXT@%$INSTOBJEXT%g
8776 s%@GENCAT@%$GENCAT%g
8777 s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
8778 s%@INTL_LIBTOOL_SUFFIX_PREFIX@%$INTL_LIBTOOL_SUFFIX_PREFIX%g
8779 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
8780 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
8781 s%@INSTALL_DATA@%$INSTALL_DATA%g
8782 s%@WINDRES@%$WINDRES%g
8783 s%@SDL12_CONFIG@%$SDL12_CONFIG%g
8784 s%@SDL11_CONFIG@%$SDL11_CONFIG%g
8785 s%@SDL_CONFIG@%$SDL_CONFIG%g
8786 s%@ESD_CONFIG@%$ESD_CONFIG%g
8787 s%@ARTS_CONFIG@%$ARTS_CONFIG%g
8788 s%@GTK12_CONFIG@%$GTK12_CONFIG%g
8789 s%@GTK_CONFIG@%$GTK_CONFIG%g
8790 s%@GNOME_CONFIG@%$GNOME_CONFIG%g
8791 s%@DATA_PATH@%$DATA_PATH%g
8792 s%@PLUGIN_PATH@%$PLUGIN_PATH%g
8793 s%@SYS@%$SYS%g
8794 s%@ARCH@%$ARCH%g
8795 s%@PLUGINS@%$PLUGINS%g
8796 s%@BUILTINS@%$BUILTINS%g
8797 s%@ALIASES@%$ALIASES%g
8798 s%@DEBUG@%$DEBUG%g
8799 s%@ASM@%$ASM%g
8800 s%@CPROF@%$CPROF%g
8801 s%@GPROF@%$GPROF%g
8802 s%@OPTIMS@%$OPTIMS%g
8803 s%@TUNING@%$TUNING%g
8804 s%@RELEASE@%$RELEASE%g
8805 s%@MOC@%$MOC%g
8806 s%@BCBUILDER@%$BCBUILDER%g
8807 s%@PACKAGE@%$PACKAGE%g
8808 s%@VERSION@%$VERSION%g
8809 s%@NEED_GETOPT@%$NEED_GETOPT%g
8810 s%@CFLAGS_OPTIM@%$CFLAGS_OPTIM%g
8811 s%@CFLAGS_OPTIM_NODEBUG@%$CFLAGS_OPTIM_NODEBUG%g
8812 s%@vlc_CFLAGS@%$vlc_CFLAGS%g
8813 s%@plugins_CFLAGS@%$plugins_CFLAGS%g
8814 s%@builtins_CFLAGS@%$builtins_CFLAGS%g
8815 s%@a52_CFLAGS@%$a52_CFLAGS%g
8816 s%@arts_CFLAGS@%$arts_CFLAGS%g
8817 s%@dvd_CFLAGS@%$dvd_CFLAGS%g
8818 s%@dvdread_CFLAGS@%$dvdread_CFLAGS%g
8819 s%@mpeg_ts_dvbpsi_CFLAGS@%$mpeg_ts_dvbpsi_CFLAGS%g
8820 s%@directx_CFLAGS@%$directx_CFLAGS%g
8821 s%@esd_CFLAGS@%$esd_CFLAGS%g
8822 s%@ffmpeg_CFLAGS@%$ffmpeg_CFLAGS%g
8823 s%@glide_CFLAGS@%$glide_CFLAGS%g
8824 s%@gnome_CFLAGS@%$gnome_CFLAGS%g
8825 s%@gtk_CFLAGS@%$gtk_CFLAGS%g
8826 s%@kde_CFLAGS@%$kde_CFLAGS%g
8827 s%@idctaltivec_CFLAGS@%$idctaltivec_CFLAGS%g
8828 s%@macosx_CFLAGS@%$macosx_CFLAGS%g
8829 s%@mad_CFLAGS@%$mad_CFLAGS%g
8830 s%@memcpyaltivec_CFLAGS@%$memcpyaltivec_CFLAGS%g
8831 s%@motionaltivec_CFLAGS@%$motionaltivec_CFLAGS%g
8832 s%@qt_CFLAGS@%$qt_CFLAGS%g
8833 s%@sdl_CFLAGS@%$sdl_CFLAGS%g
8834 s%@x11_CFLAGS@%$x11_CFLAGS%g
8835 s%@xvideo_CFLAGS@%$xvideo_CFLAGS%g
8836 s%@vlc_LDFLAGS@%$vlc_LDFLAGS%g
8837 s%@plugins_LDFLAGS@%$plugins_LDFLAGS%g
8838 s%@builtins_LDFLAGS@%$builtins_LDFLAGS%g
8839 s%@a52_LDFLAGS@%$a52_LDFLAGS%g
8840 s%@aa_LDFLAGS@%$aa_LDFLAGS%g
8841 s%@alsa_LDFLAGS@%$alsa_LDFLAGS%g
8842 s%@arts_LDFLAGS@%$arts_LDFLAGS%g
8843 s%@beos_LDFLAGS@%$beos_LDFLAGS%g
8844 s%@chroma_i420_rgb_LDFLAGS@%$chroma_i420_rgb_LDFLAGS%g
8845 s%@directx_LDFLAGS@%$directx_LDFLAGS%g
8846 s%@dsp_LDFLAGS@%$dsp_LDFLAGS%g
8847 s%@dvd_LDFLAGS@%$dvd_LDFLAGS%g
8848 s%@dvdread_LDFLAGS@%$dvdread_LDFLAGS%g
8849 s%@mpeg_ts_dvbpsi_LDFLAGS@%$mpeg_ts_dvbpsi_LDFLAGS%g
8850 s%@esd_LDFLAGS@%$esd_LDFLAGS%g
8851 s%@filter_distort_LDFLAGS@%$filter_distort_LDFLAGS%g
8852 s%@ffmpeg_LDFLAGS@%$ffmpeg_LDFLAGS%g
8853 s%@ggi_LDFLAGS@%$ggi_LDFLAGS%g
8854 s%@glide_LDFLAGS@%$glide_LDFLAGS%g
8855 s%@gnome_LDFLAGS@%$gnome_LDFLAGS%g
8856 s%@gtk_LDFLAGS@%$gtk_LDFLAGS%g
8857 s%@idctaltivec_LDFLAGS@%$idctaltivec_LDFLAGS%g
8858 s%@imdct_LDFLAGS@%$imdct_LDFLAGS%g
8859 s%@imdct3dn_LDFLAGS@%$imdct3dn_LDFLAGS%g
8860 s%@imdctsse_LDFLAGS@%$imdctsse_LDFLAGS%g
8861 s%@ipv4_LDFLAGS@%$ipv4_LDFLAGS%g
8862 s%@kde_LDFLAGS@%$kde_LDFLAGS%g
8863 s%@lirc_LDFLAGS@%$lirc_LDFLAGS%g
8864 s%@macosx_LDFLAGS@%$macosx_LDFLAGS%g
8865 s%@mad_LDFLAGS@%$mad_LDFLAGS%g
8866 s%@memcpyaltivec_LDFLAGS@%$memcpyaltivec_LDFLAGS%g
8867 s%@motionaltivec_LDFLAGS@%$motionaltivec_LDFLAGS%g
8868 s%@ncurses_LDFLAGS@%$ncurses_LDFLAGS%g
8869 s%@qnx_LDFLAGS@%$qnx_LDFLAGS%g
8870 s%@qt_LDFLAGS@%$qt_LDFLAGS%g
8871 s%@rc_LDFLAGS@%$rc_LDFLAGS%g
8872 s%@sdl_LDFLAGS@%$sdl_LDFLAGS%g
8873 s%@vcd_LDFLAGS@%$vcd_LDFLAGS%g
8874 s%@vorbis_LDFLAGS@%$vorbis_LDFLAGS%g
8875 s%@waveout_LDFLAGS@%$waveout_LDFLAGS%g
8876 s%@x11_LDFLAGS@%$x11_LDFLAGS%g
8877 s%@xvideo_LDFLAGS@%$xvideo_LDFLAGS%g
8878
8879 CEOF
8880 EOF
8881
8882 cat >> $CONFIG_STATUS <<\EOF
8883
8884 # Split the substitutions into bite-sized pieces for seds with
8885 # small command number limits, like on Digital OSF/1 and HP-UX.
8886 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
8887 ac_file=1 # Number of current file.
8888 ac_beg=1 # First line for current file.
8889 ac_end=$ac_max_sed_cmds # Line after last line for current file.
8890 ac_more_lines=:
8891 ac_sed_cmds=""
8892 while $ac_more_lines; do
8893   if test $ac_beg -gt 1; then
8894     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
8895   else
8896     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
8897   fi
8898   if test ! -s conftest.s$ac_file; then
8899     ac_more_lines=false
8900     rm -f conftest.s$ac_file
8901   else
8902     if test -z "$ac_sed_cmds"; then
8903       ac_sed_cmds="sed -f conftest.s$ac_file"
8904     else
8905       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
8906     fi
8907     ac_file=`expr $ac_file + 1`
8908     ac_beg=$ac_end
8909     ac_end=`expr $ac_end + $ac_max_sed_cmds`
8910   fi
8911 done
8912 if test -z "$ac_sed_cmds"; then
8913   ac_sed_cmds=cat
8914 fi
8915 EOF
8916
8917 cat >> $CONFIG_STATUS <<EOF
8918
8919 CONFIG_FILES=\${CONFIG_FILES-"Makefile.opts po/Makefile.in"}
8920 EOF
8921 cat >> $CONFIG_STATUS <<\EOF
8922 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
8923   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
8924   case "$ac_file" in
8925   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
8926        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
8927   *) ac_file_in="${ac_file}.in" ;;
8928   esac
8929
8930   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
8931
8932   # Remove last slash and all that follows it.  Not all systems have dirname.
8933   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
8934   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
8935     # The file is in a subdirectory.
8936     test ! -d "$ac_dir" && mkdir "$ac_dir"
8937     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
8938     # A "../" for each directory in $ac_dir_suffix.
8939     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
8940   else
8941     ac_dir_suffix= ac_dots=
8942   fi
8943
8944   case "$ac_given_srcdir" in
8945   .)  srcdir=.
8946       if test -z "$ac_dots"; then top_srcdir=.
8947       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
8948   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
8949   *) # Relative path.
8950     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
8951     top_srcdir="$ac_dots$ac_given_srcdir" ;;
8952   esac
8953
8954   case "$ac_given_INSTALL" in
8955   [/$]*) INSTALL="$ac_given_INSTALL" ;;
8956   *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
8957   esac
8958
8959   echo creating "$ac_file"
8960   rm -f "$ac_file"
8961   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
8962   case "$ac_file" in
8963   *Makefile*) ac_comsub="1i\\
8964 # $configure_input" ;;
8965   *) ac_comsub= ;;
8966   esac
8967
8968   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
8969   sed -e "$ac_comsub
8970 s%@configure_input@%$configure_input%g
8971 s%@srcdir@%$srcdir%g
8972 s%@top_srcdir@%$top_srcdir%g
8973 s%@INSTALL@%$INSTALL%g
8974 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
8975 fi; done
8976 rm -f conftest.s*
8977
8978 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
8979 # NAME is the cpp macro being defined and VALUE is the value it is being given.
8980 #
8981 # ac_d sets the value in "#define NAME VALUE" lines.
8982 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
8983 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
8984 ac_dC='\3'
8985 ac_dD='%g'
8986 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
8987 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
8988 ac_uB='\([      ]\)%\1#\2define\3'
8989 ac_uC=' '
8990 ac_uD='\4%g'
8991 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
8992 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
8993 ac_eB='$%\1#\2define\3'
8994 ac_eC=' '
8995 ac_eD='%g'
8996
8997 if test "${CONFIG_HEADERS+set}" != set; then
8998 EOF
8999 cat >> $CONFIG_STATUS <<EOF
9000   CONFIG_HEADERS="include/defs.h"
9001 EOF
9002 cat >> $CONFIG_STATUS <<\EOF
9003 fi
9004 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
9005   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
9006   case "$ac_file" in
9007   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
9008        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
9009   *) ac_file_in="${ac_file}.in" ;;
9010   esac
9011
9012   echo creating $ac_file
9013
9014   rm -f conftest.frag conftest.in conftest.out
9015   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
9016   cat $ac_file_inputs > conftest.in
9017
9018 EOF
9019
9020 # Transform confdefs.h into a sed script conftest.vals that substitutes
9021 # the proper values into config.h.in to produce config.h.  And first:
9022 # Protect against being on the right side of a sed subst in config.status.
9023 # Protect against being in an unquoted here document in config.status.
9024 rm -f conftest.vals
9025 cat > conftest.hdr <<\EOF
9026 s/[\\&%]/\\&/g
9027 s%[\\$`]%\\&%g
9028 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
9029 s%ac_d%ac_u%gp
9030 s%ac_u%ac_e%gp
9031 EOF
9032 sed -n -f conftest.hdr confdefs.h > conftest.vals
9033 rm -f conftest.hdr
9034
9035 # This sed command replaces #undef with comments.  This is necessary, for
9036 # example, in the case of _POSIX_SOURCE, which is predefined and required
9037 # on some systems where configure will not decide to define it.
9038 cat >> conftest.vals <<\EOF
9039 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
9040 EOF
9041
9042 # Break up conftest.vals because some shells have a limit on
9043 # the size of here documents, and old seds have small limits too.
9044
9045 rm -f conftest.tail
9046 while :
9047 do
9048   ac_lines=`grep -c . conftest.vals`
9049   # grep -c gives empty output for an empty file on some AIX systems.
9050   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
9051   # Write a limited-size here document to conftest.frag.
9052   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
9053   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
9054   echo 'CEOF
9055   sed -f conftest.frag conftest.in > conftest.out
9056   rm -f conftest.in
9057   mv conftest.out conftest.in
9058 ' >> $CONFIG_STATUS
9059   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
9060   rm -f conftest.vals
9061   mv conftest.tail conftest.vals
9062 done
9063 rm -f conftest.vals
9064
9065 cat >> $CONFIG_STATUS <<\EOF
9066   rm -f conftest.frag conftest.h
9067   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
9068   cat conftest.in >> conftest.h
9069   rm -f conftest.in
9070   if cmp -s $ac_file conftest.h 2>/dev/null; then
9071     echo "$ac_file is unchanged"
9072     rm -f conftest.h
9073   else
9074     # Remove last slash and all that follows it.  Not all systems have dirname.
9075       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
9076       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
9077       # The file is in a subdirectory.
9078       test ! -d "$ac_dir" && mkdir "$ac_dir"
9079     fi
9080     rm -f $ac_file
9081     mv conftest.h $ac_file
9082   fi
9083 fi; done
9084
9085 EOF
9086 cat >> $CONFIG_STATUS <<EOF
9087
9088
9089 EOF
9090 cat >> $CONFIG_STATUS <<\EOF
9091 for ac_file in $CONFIG_FILES; do
9092         # Support "outfile[:infile[:infile...]]"
9093         case "$ac_file" in
9094           *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
9095         esac
9096         # PO directories have a Makefile.in generated from Makefile.in.in.
9097         case "$ac_file" in */Makefile.in)
9098           # Adjust a relative srcdir.
9099           ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
9100           ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
9101           ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
9102           # In autoconf-2.13 it is called $ac_given_srcdir.
9103           # In autoconf-2.50 it is called $srcdir.
9104           test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
9105           case "$ac_given_srcdir" in
9106             .)  top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
9107             /*) top_srcdir="$ac_given_srcdir" ;;
9108             *)  top_srcdir="$ac_dots$ac_given_srcdir" ;;
9109           esac
9110           if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
9111             rm -f "$ac_dir/POTFILES"
9112             test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
9113             sed -e "/^#/d" -e "/^[      ]*\$/d" -e "s,.*,     $top_srcdir/& \\\\," -e "\$s/\(.*\) \\\\/\1/" < "$ac_given_srcdir/$ac_dir/POTFILES.in" > "$ac_dir/POTFILES"
9114             test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
9115             sed -e "/POTFILES =/r $ac_dir/POTFILES" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
9116           fi
9117           ;;
9118         esac
9119       done
9120
9121 exit 0
9122 EOF
9123 chmod +x $CONFIG_STATUS
9124 rm -fr confdefs* $ac_clean_files
9125 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
9126
9127
9128 echo "
9129 vlc configuration
9130 --------------------
9131 vlc version           : ${VERSION}
9132 system                : ${SYS}
9133 architecture          : ${ARCH}
9134 optimizations         : ${OPTIMS}
9135 tuning                : ${TUNING}
9136 debug mode            : ${DEBUG}
9137 release               : ${RELEASE}
9138 cprof/gprof support   : ${CPROF}/${GPROF}
9139 need builtin getopt   : ${NEED_GETOPT}
9140 built-in modules      :${BUILTINS}
9141 plug-in modules       :${PLUGINS}
9142 vlc aliases           :${ALIASES}
9143
9144 You may now tune Makefile.opts at your convenience, for instance to choose
9145 which modules get compiled as plugins.
9146
9147 To build vlc and its plugins, type \`$VLC_MAKE'.
9148 "
9149