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