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