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