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