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