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