]> git.sesse.net Git - vlc/blob - configure
* added --intf option to vlc
[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   --disable-ppro          Disable PentiumPro optimizations (default enabled for x86)"
16 ac_help="$ac_help
17   --disable-mmx           Disable MMX optimizations (default enabled for x86)"
18 ac_help="$ac_help
19   --enable-debug          Enable debug mode (default disabled)"
20 ac_help="$ac_help
21   --enable-stats          Enable printing of statistics (default disabled)"
22 ac_help="$ac_help
23   --disable-optimizations Disable compiler optimizations (default enabled)"
24 ac_help="$ac_help
25   --disable-dummy         dummy module (default enabled)"
26 ac_help="$ac_help
27   --disable-null          Null module (default enabled)"
28 ac_help="$ac_help
29   --disable-dsp           Linux /dev/dsp support (default enabled)"
30 ac_help="$ac_help
31   --enable-esd            Esound library support (default disabled)"
32 ac_help="$ac_help
33   --enable-fb             Linux framebuffer support (default disabled)"
34 ac_help="$ac_help
35   --with-ggi[=name]       GGI support (default disabled)"
36 ac_help="$ac_help
37   --with-sdl[=name]       SDL support (default enabled)"
38 ac_help="$ac_help
39   --with-glide[=name]     Glide (3dfx) support (default disabled)"
40 ac_help="$ac_help
41   --disable-gnome         Gnome support (default enabled)"
42 ac_help="$ac_help
43   --enable-x11            X11 support (default disabled)"
44 ac_help="$ac_help
45   --enable-alsa           Alsa sound drivers support (Only for linux) (default disabled)"
46
47 # Initialize some variables set by options.
48 # The variables have the same names as the options, with
49 # dashes changed to underlines.
50 build=NONE
51 cache_file=./config.cache
52 exec_prefix=NONE
53 host=NONE
54 no_create=
55 nonopt=NONE
56 no_recursion=
57 prefix=NONE
58 program_prefix=NONE
59 program_suffix=NONE
60 program_transform_name=s,x,x,
61 silent=
62 site=
63 srcdir=
64 target=NONE
65 verbose=
66 x_includes=NONE
67 x_libraries=NONE
68 bindir='${exec_prefix}/bin'
69 sbindir='${exec_prefix}/sbin'
70 libexecdir='${exec_prefix}/libexec'
71 datadir='${prefix}/share'
72 sysconfdir='${prefix}/etc'
73 sharedstatedir='${prefix}/com'
74 localstatedir='${prefix}/var'
75 libdir='${exec_prefix}/lib'
76 includedir='${prefix}/include'
77 oldincludedir='/usr/include'
78 infodir='${prefix}/info'
79 mandir='${prefix}/man'
80
81 # Initialize some other variables.
82 subdirs=
83 MFLAGS= MAKEFLAGS=
84 SHELL=${CONFIG_SHELL-/bin/sh}
85 # Maximum number of lines to put in a shell here document.
86 ac_max_here_lines=12
87
88 ac_prev=
89 for ac_option
90 do
91
92   # If the previous option needs an argument, assign it.
93   if test -n "$ac_prev"; then
94     eval "$ac_prev=\$ac_option"
95     ac_prev=
96     continue
97   fi
98
99   case "$ac_option" in
100   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
101   *) ac_optarg= ;;
102   esac
103
104   # Accept the important Cygnus configure options, so we can diagnose typos.
105
106   case "$ac_option" in
107
108   -bindir | --bindir | --bindi | --bind | --bin | --bi)
109     ac_prev=bindir ;;
110   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
111     bindir="$ac_optarg" ;;
112
113   -build | --build | --buil | --bui | --bu)
114     ac_prev=build ;;
115   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
116     build="$ac_optarg" ;;
117
118   -cache-file | --cache-file | --cache-fil | --cache-fi \
119   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
120     ac_prev=cache_file ;;
121   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
122   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
123     cache_file="$ac_optarg" ;;
124
125   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
126     ac_prev=datadir ;;
127   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
128   | --da=*)
129     datadir="$ac_optarg" ;;
130
131   -disable-* | --disable-*)
132     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
133     # Reject names that are not valid shell variable names.
134     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
135       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
136     fi
137     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
138     eval "enable_${ac_feature}=no" ;;
139
140   -enable-* | --enable-*)
141     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
142     # Reject names that are not valid shell variable names.
143     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
144       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
145     fi
146     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
147     case "$ac_option" in
148       *=*) ;;
149       *) ac_optarg=yes ;;
150     esac
151     eval "enable_${ac_feature}='$ac_optarg'" ;;
152
153   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
154   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
155   | --exec | --exe | --ex)
156     ac_prev=exec_prefix ;;
157   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
158   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
159   | --exec=* | --exe=* | --ex=*)
160     exec_prefix="$ac_optarg" ;;
161
162   -gas | --gas | --ga | --g)
163     # Obsolete; use --with-gas.
164     with_gas=yes ;;
165
166   -help | --help | --hel | --he)
167     # Omit some internal or obsolete options to make the list less imposing.
168     # This message is too long to be a string in the A/UX 3.1 sh.
169     cat << EOF
170 Usage: configure [options] [host]
171 Options: [defaults in brackets after descriptions]
172 Configuration:
173   --cache-file=FILE       cache test results in FILE
174   --help                  print this message
175   --no-create             do not create output files
176   --quiet, --silent       do not print \`checking...' messages
177   --version               print the version of autoconf that created configure
178 Directory and file names:
179   --prefix=PREFIX         install architecture-independent files in PREFIX
180                           [$ac_default_prefix]
181   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
182                           [same as prefix]
183   --bindir=DIR            user executables in DIR [EPREFIX/bin]
184   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
185   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
186   --datadir=DIR           read-only architecture-independent data in DIR
187                           [PREFIX/share]
188   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
189   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
190                           [PREFIX/com]
191   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
192   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
193   --includedir=DIR        C header files in DIR [PREFIX/include]
194   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
195   --infodir=DIR           info documentation in DIR [PREFIX/info]
196   --mandir=DIR            man documentation in DIR [PREFIX/man]
197   --srcdir=DIR            find the sources in DIR [configure dir or ..]
198   --program-prefix=PREFIX prepend PREFIX to installed program names
199   --program-suffix=SUFFIX append SUFFIX to installed program names
200   --program-transform-name=PROGRAM
201                           run sed PROGRAM on installed program names
202 EOF
203     cat << EOF
204 Host type:
205   --build=BUILD           configure for building on BUILD [BUILD=HOST]
206   --host=HOST             configure for HOST [guessed]
207   --target=TARGET         configure for TARGET [TARGET=HOST]
208 Features and packages:
209   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
210   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
211   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
212   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
213   --x-includes=DIR        X include files are in DIR
214   --x-libraries=DIR       X library files are in DIR
215 EOF
216     if test -n "$ac_help"; then
217       echo "--enable and --with options recognized:$ac_help"
218     fi
219     exit 0 ;;
220
221   -host | --host | --hos | --ho)
222     ac_prev=host ;;
223   -host=* | --host=* | --hos=* | --ho=*)
224     host="$ac_optarg" ;;
225
226   -includedir | --includedir | --includedi | --included | --include \
227   | --includ | --inclu | --incl | --inc)
228     ac_prev=includedir ;;
229   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
230   | --includ=* | --inclu=* | --incl=* | --inc=*)
231     includedir="$ac_optarg" ;;
232
233   -infodir | --infodir | --infodi | --infod | --info | --inf)
234     ac_prev=infodir ;;
235   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
236     infodir="$ac_optarg" ;;
237
238   -libdir | --libdir | --libdi | --libd)
239     ac_prev=libdir ;;
240   -libdir=* | --libdir=* | --libdi=* | --libd=*)
241     libdir="$ac_optarg" ;;
242
243   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
244   | --libexe | --libex | --libe)
245     ac_prev=libexecdir ;;
246   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
247   | --libexe=* | --libex=* | --libe=*)
248     libexecdir="$ac_optarg" ;;
249
250   -localstatedir | --localstatedir | --localstatedi | --localstated \
251   | --localstate | --localstat | --localsta | --localst \
252   | --locals | --local | --loca | --loc | --lo)
253     ac_prev=localstatedir ;;
254   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
255   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
256   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
257     localstatedir="$ac_optarg" ;;
258
259   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
260     ac_prev=mandir ;;
261   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
262     mandir="$ac_optarg" ;;
263
264   -nfp | --nfp | --nf)
265     # Obsolete; use --without-fp.
266     with_fp=no ;;
267
268   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
269   | --no-cr | --no-c)
270     no_create=yes ;;
271
272   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
273   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
274     no_recursion=yes ;;
275
276   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
277   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
278   | --oldin | --oldi | --old | --ol | --o)
279     ac_prev=oldincludedir ;;
280   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
281   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
282   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
283     oldincludedir="$ac_optarg" ;;
284
285   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
286     ac_prev=prefix ;;
287   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
288     prefix="$ac_optarg" ;;
289
290   -program-prefix | --program-prefix | --program-prefi | --program-pref \
291   | --program-pre | --program-pr | --program-p)
292     ac_prev=program_prefix ;;
293   -program-prefix=* | --program-prefix=* | --program-prefi=* \
294   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
295     program_prefix="$ac_optarg" ;;
296
297   -program-suffix | --program-suffix | --program-suffi | --program-suff \
298   | --program-suf | --program-su | --program-s)
299     ac_prev=program_suffix ;;
300   -program-suffix=* | --program-suffix=* | --program-suffi=* \
301   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
302     program_suffix="$ac_optarg" ;;
303
304   -program-transform-name | --program-transform-name \
305   | --program-transform-nam | --program-transform-na \
306   | --program-transform-n | --program-transform- \
307   | --program-transform | --program-transfor \
308   | --program-transfo | --program-transf \
309   | --program-trans | --program-tran \
310   | --progr-tra | --program-tr | --program-t)
311     ac_prev=program_transform_name ;;
312   -program-transform-name=* | --program-transform-name=* \
313   | --program-transform-nam=* | --program-transform-na=* \
314   | --program-transform-n=* | --program-transform-=* \
315   | --program-transform=* | --program-transfor=* \
316   | --program-transfo=* | --program-transf=* \
317   | --program-trans=* | --program-tran=* \
318   | --progr-tra=* | --program-tr=* | --program-t=*)
319     program_transform_name="$ac_optarg" ;;
320
321   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
322   | -silent | --silent | --silen | --sile | --sil)
323     silent=yes ;;
324
325   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
326     ac_prev=sbindir ;;
327   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
328   | --sbi=* | --sb=*)
329     sbindir="$ac_optarg" ;;
330
331   -sharedstatedir | --sharedstatedir | --sharedstatedi \
332   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
333   | --sharedst | --shareds | --shared | --share | --shar \
334   | --sha | --sh)
335     ac_prev=sharedstatedir ;;
336   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
337   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
338   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
339   | --sha=* | --sh=*)
340     sharedstatedir="$ac_optarg" ;;
341
342   -site | --site | --sit)
343     ac_prev=site ;;
344   -site=* | --site=* | --sit=*)
345     site="$ac_optarg" ;;
346
347   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
348     ac_prev=srcdir ;;
349   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
350     srcdir="$ac_optarg" ;;
351
352   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
353   | --syscon | --sysco | --sysc | --sys | --sy)
354     ac_prev=sysconfdir ;;
355   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
356   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
357     sysconfdir="$ac_optarg" ;;
358
359   -target | --target | --targe | --targ | --tar | --ta | --t)
360     ac_prev=target ;;
361   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
362     target="$ac_optarg" ;;
363
364   -v | -verbose | --verbose | --verbos | --verbo | --verb)
365     verbose=yes ;;
366
367   -version | --version | --versio | --versi | --vers)
368     echo "configure generated by autoconf version 2.13"
369     exit 0 ;;
370
371   -with-* | --with-*)
372     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
373     # Reject names that are not valid shell variable names.
374     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
375       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
376     fi
377     ac_package=`echo $ac_package| sed 's/-/_/g'`
378     case "$ac_option" in
379       *=*) ;;
380       *) ac_optarg=yes ;;
381     esac
382     eval "with_${ac_package}='$ac_optarg'" ;;
383
384   -without-* | --without-*)
385     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
386     # Reject names that are not valid shell variable names.
387     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
388       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
389     fi
390     ac_package=`echo $ac_package| sed 's/-/_/g'`
391     eval "with_${ac_package}=no" ;;
392
393   --x)
394     # Obsolete; use --with-x.
395     with_x=yes ;;
396
397   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
398   | --x-incl | --x-inc | --x-in | --x-i)
399     ac_prev=x_includes ;;
400   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
401   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
402     x_includes="$ac_optarg" ;;
403
404   -x-libraries | --x-libraries | --x-librarie | --x-librari \
405   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
406     ac_prev=x_libraries ;;
407   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
408   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
409     x_libraries="$ac_optarg" ;;
410
411   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
412     ;;
413
414   *)
415     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
416       echo "configure: warning: $ac_option: invalid host type" 1>&2
417     fi
418     if test "x$nonopt" != xNONE; then
419       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
420     fi
421     nonopt="$ac_option"
422     ;;
423
424   esac
425 done
426
427 if test -n "$ac_prev"; then
428   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
429 fi
430
431 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
432
433 # File descriptor usage:
434 # 0 standard input
435 # 1 file creation
436 # 2 errors and warnings
437 # 3 some systems may open it to /dev/tty
438 # 4 used on the Kubota Titan
439 # 6 checking for... messages and results
440 # 5 compiler messages saved in config.log
441 if test "$silent" = yes; then
442   exec 6>/dev/null
443 else
444   exec 6>&1
445 fi
446 exec 5>./config.log
447
448 echo "\
449 This file contains any messages produced by compilers while
450 running configure, to aid debugging if configure makes a mistake.
451 " 1>&5
452
453 # Strip out --no-create and --no-recursion so they do not pile up.
454 # Also quote any args containing shell metacharacters.
455 ac_configure_args=
456 for ac_arg
457 do
458   case "$ac_arg" in
459   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
460   | --no-cr | --no-c) ;;
461   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
462   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
463   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
464   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
465   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
466   esac
467 done
468
469 # NLS nuisances.
470 # Only set these to C if already set.  These must not be set unconditionally
471 # because not all systems understand e.g. LANG=C (notably SCO).
472 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
473 # Non-C LC_CTYPE values break the ctype check.
474 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
475 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
476 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
477 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
478
479 # confdefs.h avoids OS command line length limits that DEFS can exceed.
480 rm -rf conftest* confdefs.h
481 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
482 echo > confdefs.h
483
484 # A filename unique to this package, relative to the directory that
485 # configure is in, which we can look for to find out if srcdir is correct.
486 ac_unique_file=src/interface/main.c
487
488 # Find the source files, if location was not specified.
489 if test -z "$srcdir"; then
490   ac_srcdir_defaulted=yes
491   # Try the directory containing this script, then its parent.
492   ac_prog=$0
493   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
494   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
495   srcdir=$ac_confdir
496   if test ! -r $srcdir/$ac_unique_file; then
497     srcdir=..
498   fi
499 else
500   ac_srcdir_defaulted=no
501 fi
502 if test ! -r $srcdir/$ac_unique_file; then
503   if test "$ac_srcdir_defaulted" = yes; then
504     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
505   else
506     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
507   fi
508 fi
509 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
510
511 # Prefer explicitly selected file to automatically selected ones.
512 if test -z "$CONFIG_SITE"; then
513   if test "x$prefix" != xNONE; then
514     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
515   else
516     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
517   fi
518 fi
519 for ac_site_file in $CONFIG_SITE; do
520   if test -r "$ac_site_file"; then
521     echo "loading site script $ac_site_file"
522     . "$ac_site_file"
523   fi
524 done
525
526 if test -r "$cache_file"; then
527   echo "loading cache $cache_file"
528   . $cache_file
529 else
530   echo "creating cache $cache_file"
531   > $cache_file
532 fi
533
534 ac_ext=c
535 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
536 ac_cpp='$CPP $CPPFLAGS'
537 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
538 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
539 cross_compiling=$ac_cv_prog_cc_cross
540
541 ac_exeext=
542 ac_objext=o
543 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
544   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
545   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
546     ac_n= ac_c='
547 ' ac_t='        '
548   else
549     ac_n=-n ac_c= ac_t=
550   fi
551 else
552   ac_n= ac_c='\c' ac_t=
553 fi
554
555
556
557
558 ac_aux_dir=
559 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
560   if test -f $ac_dir/install-sh; then
561     ac_aux_dir=$ac_dir
562     ac_install_sh="$ac_aux_dir/install-sh -c"
563     break
564   elif test -f $ac_dir/install.sh; then
565     ac_aux_dir=$ac_dir
566     ac_install_sh="$ac_aux_dir/install.sh -c"
567     break
568   fi
569 done
570 if test -z "$ac_aux_dir"; then
571   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
572 fi
573 ac_config_guess=$ac_aux_dir/config.guess
574 ac_config_sub=$ac_aux_dir/config.sub
575 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
576
577
578 # Make sure we can run config.sub.
579 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
580 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
581 fi
582
583 echo $ac_n "checking host system type""... $ac_c" 1>&6
584 echo "configure:585: checking host system type" >&5
585
586 host_alias=$host
587 case "$host_alias" in
588 NONE)
589   case $nonopt in
590   NONE)
591     if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
592     else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
593     fi ;;
594   *) host_alias=$nonopt ;;
595   esac ;;
596 esac
597
598 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
599 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
600 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
601 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
602 echo "$ac_t""$host" 1>&6
603
604
605 VLC_VERSION=0.2.50
606
607 VLC_CODENAME=Urumov
608
609
610 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
611 echo "configure:612: checking whether ${MAKE-make} sets \${MAKE}" >&5
612 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
613 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
614   echo $ac_n "(cached) $ac_c" 1>&6
615 else
616   cat > conftestmake <<\EOF
617 all:
618         @echo 'ac_maketemp="${MAKE}"'
619 EOF
620 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
621 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
622 if test -n "$ac_maketemp"; then
623   eval ac_cv_prog_make_${ac_make}_set=yes
624 else
625   eval ac_cv_prog_make_${ac_make}_set=no
626 fi
627 rm -f conftestmake
628 fi
629 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
630   echo "$ac_t""yes" 1>&6
631   SET_MAKE=
632 else
633   echo "$ac_t""no" 1>&6
634   SET_MAKE="MAKE=${MAKE-make}"
635 fi
636
637 if test -z "$CC"; then
638   # Extract the first word of "gcc", so it can be a program name with args.
639 set dummy gcc; ac_word=$2
640 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
641 echo "configure:642: checking for $ac_word" >&5
642 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
643   echo $ac_n "(cached) $ac_c" 1>&6
644 else
645   if test -n "$CC"; then
646   ac_cv_prog_CC="$CC" # Let the user override the test.
647 else
648   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
649   ac_dummy="$PATH"
650   for ac_dir in $ac_dummy; do
651     test -z "$ac_dir" && ac_dir=.
652     if test -f $ac_dir/$ac_word; then
653       ac_cv_prog_CC="gcc"
654       break
655     fi
656   done
657   IFS="$ac_save_ifs"
658 fi
659 fi
660 CC="$ac_cv_prog_CC"
661 if test -n "$CC"; then
662   echo "$ac_t""$CC" 1>&6
663 else
664   echo "$ac_t""no" 1>&6
665 fi
666
667 if test -z "$CC"; then
668   # Extract the first word of "cc", so it can be a program name with args.
669 set dummy cc; ac_word=$2
670 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
671 echo "configure:672: checking for $ac_word" >&5
672 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
673   echo $ac_n "(cached) $ac_c" 1>&6
674 else
675   if test -n "$CC"; then
676   ac_cv_prog_CC="$CC" # Let the user override the test.
677 else
678   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
679   ac_prog_rejected=no
680   ac_dummy="$PATH"
681   for ac_dir in $ac_dummy; do
682     test -z "$ac_dir" && ac_dir=.
683     if test -f $ac_dir/$ac_word; then
684       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
685         ac_prog_rejected=yes
686         continue
687       fi
688       ac_cv_prog_CC="cc"
689       break
690     fi
691   done
692   IFS="$ac_save_ifs"
693 if test $ac_prog_rejected = yes; then
694   # We found a bogon in the path, so make sure we never use it.
695   set dummy $ac_cv_prog_CC
696   shift
697   if test $# -gt 0; then
698     # We chose a different compiler from the bogus one.
699     # However, it has the same basename, so the bogon will be chosen
700     # first if we set CC to just the basename; use the full file name.
701     shift
702     set dummy "$ac_dir/$ac_word" "$@"
703     shift
704     ac_cv_prog_CC="$@"
705   fi
706 fi
707 fi
708 fi
709 CC="$ac_cv_prog_CC"
710 if test -n "$CC"; then
711   echo "$ac_t""$CC" 1>&6
712 else
713   echo "$ac_t""no" 1>&6
714 fi
715
716   if test -z "$CC"; then
717     case "`uname -s`" in
718     *win32* | *WIN32*)
719       # Extract the first word of "cl", so it can be a program name with args.
720 set dummy cl; ac_word=$2
721 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
722 echo "configure:723: checking for $ac_word" >&5
723 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
724   echo $ac_n "(cached) $ac_c" 1>&6
725 else
726   if test -n "$CC"; then
727   ac_cv_prog_CC="$CC" # Let the user override the test.
728 else
729   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
730   ac_dummy="$PATH"
731   for ac_dir in $ac_dummy; do
732     test -z "$ac_dir" && ac_dir=.
733     if test -f $ac_dir/$ac_word; then
734       ac_cv_prog_CC="cl"
735       break
736     fi
737   done
738   IFS="$ac_save_ifs"
739 fi
740 fi
741 CC="$ac_cv_prog_CC"
742 if test -n "$CC"; then
743   echo "$ac_t""$CC" 1>&6
744 else
745   echo "$ac_t""no" 1>&6
746 fi
747  ;;
748     esac
749   fi
750   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
751 fi
752
753 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
754 echo "configure:755: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
755
756 ac_ext=c
757 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
758 ac_cpp='$CPP $CPPFLAGS'
759 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
760 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
761 cross_compiling=$ac_cv_prog_cc_cross
762
763 cat > conftest.$ac_ext << EOF
764
765 #line 766 "configure"
766 #include "confdefs.h"
767
768 main(){return(0);}
769 EOF
770 if { (eval echo configure:771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
771   ac_cv_prog_cc_works=yes
772   # If we can't run a trivial program, we are probably using a cross compiler.
773   if (./conftest; exit) 2>/dev/null; then
774     ac_cv_prog_cc_cross=no
775   else
776     ac_cv_prog_cc_cross=yes
777   fi
778 else
779   echo "configure: failed program was:" >&5
780   cat conftest.$ac_ext >&5
781   ac_cv_prog_cc_works=no
782 fi
783 rm -fr conftest*
784 ac_ext=c
785 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
786 ac_cpp='$CPP $CPPFLAGS'
787 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
788 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
789 cross_compiling=$ac_cv_prog_cc_cross
790
791 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
792 if test $ac_cv_prog_cc_works = no; then
793   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
794 fi
795 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
796 echo "configure:797: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
797 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
798 cross_compiling=$ac_cv_prog_cc_cross
799
800 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
801 echo "configure:802: checking whether we are using GNU C" >&5
802 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
803   echo $ac_n "(cached) $ac_c" 1>&6
804 else
805   cat > conftest.c <<EOF
806 #ifdef __GNUC__
807   yes;
808 #endif
809 EOF
810 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:811: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
811   ac_cv_prog_gcc=yes
812 else
813   ac_cv_prog_gcc=no
814 fi
815 fi
816
817 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
818
819 if test $ac_cv_prog_gcc = yes; then
820   GCC=yes
821 else
822   GCC=
823 fi
824
825 ac_test_CFLAGS="${CFLAGS+set}"
826 ac_save_CFLAGS="$CFLAGS"
827 CFLAGS=
828 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
829 echo "configure:830: checking whether ${CC-cc} accepts -g" >&5
830 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
831   echo $ac_n "(cached) $ac_c" 1>&6
832 else
833   echo 'void f(){}' > conftest.c
834 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
835   ac_cv_prog_cc_g=yes
836 else
837   ac_cv_prog_cc_g=no
838 fi
839 rm -f conftest*
840
841 fi
842
843 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
844 if test "$ac_test_CFLAGS" = set; then
845   CFLAGS="$ac_save_CFLAGS"
846 elif test $ac_cv_prog_cc_g = yes; then
847   if test "$GCC" = yes; then
848     CFLAGS="-g -O2"
849   else
850     CFLAGS="-g"
851   fi
852 else
853   if test "$GCC" = yes; then
854     CFLAGS="-O2"
855   else
856     CFLAGS=
857   fi
858 fi
859
860 fi
861 if test -z "$CPP"; then
862   echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
863 echo "configure:864: checking how to run the C preprocessor" >&5
864 # On Suns, sometimes $CPP names a directory.
865 if test -n "$CPP" && test -d "$CPP"; then
866   CPP=
867 fi
868 if test -z "$CPP"; then
869 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
870   echo $ac_n "(cached) $ac_c" 1>&6
871 else
872     # This must be in double quotes, not single quotes, because CPP may get
873   # substituted into the Makefile and "${CC-cc}" will confuse make.
874   CPP="${CC-cc} -E"
875   # On the NeXT, cc -E runs the code through the compiler's parser,
876   # not just through cpp.
877   cat > conftest.$ac_ext <<EOF
878 #line 879 "configure"
879 #include "confdefs.h"
880 #include <assert.h>
881 Syntax Error
882 EOF
883 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
884 { (eval echo configure:885: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
885 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
886 if test -z "$ac_err"; then
887   :
888 else
889   echo "$ac_err" >&5
890   echo "configure: failed program was:" >&5
891   cat conftest.$ac_ext >&5
892   rm -rf conftest*
893   CPP="${CC-cc} -E -traditional-cpp"
894   cat > conftest.$ac_ext <<EOF
895 #line 896 "configure"
896 #include "confdefs.h"
897 #include <assert.h>
898 Syntax Error
899 EOF
900 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
901 { (eval echo configure:902: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
902 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
903 if test -z "$ac_err"; then
904   :
905 else
906   echo "$ac_err" >&5
907   echo "configure: failed program was:" >&5
908   cat conftest.$ac_ext >&5
909   rm -rf conftest*
910   CPP="${CC-cc} -nologo -E"
911   cat > conftest.$ac_ext <<EOF
912 #line 913 "configure"
913 #include "confdefs.h"
914 #include <assert.h>
915 Syntax Error
916 EOF
917 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
918 { (eval echo configure:919: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
919 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
920 if test -z "$ac_err"; then
921   :
922 else
923   echo "$ac_err" >&5
924   echo "configure: failed program was:" >&5
925   cat conftest.$ac_ext >&5
926   rm -rf conftest*
927   CPP=/lib/cpp
928 fi
929 rm -f conftest*
930 fi
931 rm -f conftest*
932 fi
933 rm -f conftest*
934   ac_cv_prog_CPP="$CPP"
935 fi
936   CPP="$ac_cv_prog_CPP"
937 else
938   ac_cv_prog_CPP="$CPP"
939 fi
940 echo "$ac_t""$CPP" 1>&6
941
942 fi
943
944 # Find a good install program.  We prefer a C program (faster),
945 # so one script is as good as another.  But avoid the broken or
946 # incompatible versions:
947 # SysV /etc/install, /usr/sbin/install
948 # SunOS /usr/etc/install
949 # IRIX /sbin/install
950 # AIX /bin/install
951 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
952 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
953 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
954 # ./install, which can be erroneously created by make from ./install.sh.
955 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
956 echo "configure:957: checking for a BSD compatible install" >&5
957 if test -z "$INSTALL"; then
958 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
959   echo $ac_n "(cached) $ac_c" 1>&6
960 else
961     IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
962   for ac_dir in $PATH; do
963     # Account for people who put trailing slashes in PATH elements.
964     case "$ac_dir/" in
965     /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
966     *)
967       # OSF1 and SCO ODT 3.0 have their own names for install.
968       # Don't use installbsd from OSF since it installs stuff as root
969       # by default.
970       for ac_prog in ginstall scoinst install; do
971         if test -f $ac_dir/$ac_prog; then
972           if test $ac_prog = install &&
973             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
974             # AIX install.  It has an incompatible calling convention.
975             :
976           else
977             ac_cv_path_install="$ac_dir/$ac_prog -c"
978             break 2
979           fi
980         fi
981       done
982       ;;
983     esac
984   done
985   IFS="$ac_save_IFS"
986
987 fi
988   if test "${ac_cv_path_install+set}" = set; then
989     INSTALL="$ac_cv_path_install"
990   else
991     # As a last resort, use the slow shell script.  We don't cache a
992     # path for INSTALL within a source directory, because that will
993     # break other packages using the cache if that directory is
994     # removed, or if the path is relative.
995     INSTALL="$ac_install_sh"
996   fi
997 fi
998 echo "$ac_t""$INSTALL" 1>&6
999
1000 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1001 # It thinks the first close brace ends the variable substitution.
1002 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1003
1004 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1005
1006 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1007
1008
1009 echo $ac_n "checking for working const""... $ac_c" 1>&6
1010 echo "configure:1011: checking for working const" >&5
1011 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
1012   echo $ac_n "(cached) $ac_c" 1>&6
1013 else
1014   cat > conftest.$ac_ext <<EOF
1015 #line 1016 "configure"
1016 #include "confdefs.h"
1017
1018 int main() {
1019
1020 /* Ultrix mips cc rejects this.  */
1021 typedef int charset[2]; const charset x = {0,0};
1022 /* SunOS 4.1.1 cc rejects this.  */
1023 char const *const *ccp;
1024 char **p;
1025 /* NEC SVR4.0.2 mips cc rejects this.  */
1026 struct point {int x, y;};
1027 static struct point const zero = {0,0};
1028 /* AIX XL C 1.02.0.0 rejects this.
1029    It does not let you subtract one const X* pointer from another in an arm
1030    of an if-expression whose if-part is not a constant expression */
1031 const char *g = "string";
1032 ccp = &g + (g ? g-g : 0);
1033 /* HPUX 7.0 cc rejects these. */
1034 ++ccp;
1035 p = (char**) ccp;
1036 ccp = (char const *const *) p;
1037 { /* SCO 3.2v4 cc rejects this.  */
1038   char *t;
1039   char const *s = 0 ? (char *) 0 : (char const *) 0;
1040
1041   *t++ = 0;
1042 }
1043 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
1044   int x[] = {25, 17};
1045   const int *foo = &x[0];
1046   ++foo;
1047 }
1048 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
1049   typedef const int *iptr;
1050   iptr p = 0;
1051   ++p;
1052 }
1053 { /* AIX XL C 1.02.0.0 rejects this saying
1054      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
1055   struct s { int j; const int *ap[3]; };
1056   struct s *b; b->j = 5;
1057 }
1058 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
1059   const int foo = 10;
1060 }
1061
1062 ; return 0; }
1063 EOF
1064 if { (eval echo configure:1065: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1065   rm -rf conftest*
1066   ac_cv_c_const=yes
1067 else
1068   echo "configure: failed program was:" >&5
1069   cat conftest.$ac_ext >&5
1070   rm -rf conftest*
1071   ac_cv_c_const=no
1072 fi
1073 rm -f conftest*
1074 fi
1075
1076 echo "$ac_t""$ac_cv_c_const" 1>&6
1077 if test $ac_cv_c_const = no; then
1078   cat >> confdefs.h <<\EOF
1079 #define const 
1080 EOF
1081
1082 fi
1083
1084 echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
1085 echo "configure:1086: checking whether byte ordering is bigendian" >&5
1086 if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
1087   echo $ac_n "(cached) $ac_c" 1>&6
1088 else
1089   ac_cv_c_bigendian=unknown
1090 # See if sys/param.h defines the BYTE_ORDER macro.
1091 cat > conftest.$ac_ext <<EOF
1092 #line 1093 "configure"
1093 #include "confdefs.h"
1094 #include <sys/types.h>
1095 #include <sys/param.h>
1096 int main() {
1097
1098 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
1099  bogus endian macros
1100 #endif
1101 ; return 0; }
1102 EOF
1103 if { (eval echo configure:1104: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1104   rm -rf conftest*
1105   # It does; now see whether it defined to BIG_ENDIAN or not.
1106 cat > conftest.$ac_ext <<EOF
1107 #line 1108 "configure"
1108 #include "confdefs.h"
1109 #include <sys/types.h>
1110 #include <sys/param.h>
1111 int main() {
1112
1113 #if BYTE_ORDER != BIG_ENDIAN
1114  not big endian
1115 #endif
1116 ; return 0; }
1117 EOF
1118 if { (eval echo configure:1119: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1119   rm -rf conftest*
1120   ac_cv_c_bigendian=yes
1121 else
1122   echo "configure: failed program was:" >&5
1123   cat conftest.$ac_ext >&5
1124   rm -rf conftest*
1125   ac_cv_c_bigendian=no
1126 fi
1127 rm -f conftest*
1128 else
1129   echo "configure: failed program was:" >&5
1130   cat conftest.$ac_ext >&5
1131 fi
1132 rm -f conftest*
1133 if test $ac_cv_c_bigendian = unknown; then
1134 if test "$cross_compiling" = yes; then
1135     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1136 else
1137   cat > conftest.$ac_ext <<EOF
1138 #line 1139 "configure"
1139 #include "confdefs.h"
1140 main () {
1141   /* Are we little or big endian?  From Harbison&Steele.  */
1142   union
1143   {
1144     long l;
1145     char c[sizeof (long)];
1146   } u;
1147   u.l = 1;
1148   exit (u.c[sizeof (long) - 1] == 1);
1149 }
1150 EOF
1151 if { (eval echo configure:1152: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1152 then
1153   ac_cv_c_bigendian=no
1154 else
1155   echo "configure: failed program was:" >&5
1156   cat conftest.$ac_ext >&5
1157   rm -fr conftest*
1158   ac_cv_c_bigendian=yes
1159 fi
1160 rm -fr conftest*
1161 fi
1162
1163 fi
1164 fi
1165
1166 echo "$ac_t""$ac_cv_c_bigendian" 1>&6
1167 if test $ac_cv_c_bigendian = yes; then
1168   cat >> confdefs.h <<\EOF
1169 #define WORDS_BIGENDIAN 1
1170 EOF
1171
1172 fi
1173
1174
1175 echo $ac_n "checking whether compiler accepts bswap x86 instruction""... $ac_c" 1>&6
1176 echo "configure:1177: checking whether compiler accepts bswap x86 instruction" >&5
1177 cat > conftest.$ac_ext <<EOF
1178 #line 1179 "configure"
1179 #include "confdefs.h"
1180 unsigned int foo( unsigned int x )
1181    { __asm__("bswap %0" : "=r" (x) : "0" (x)); return x; }
1182 int main() {
1183
1184 ; return 0; }
1185 EOF
1186 if { (eval echo configure:1187: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1187   rm -rf conftest*
1188   cat >> confdefs.h <<\EOF
1189 #define HAVE_X86_BSWAP 1
1190 EOF
1191  echo "$ac_t""yes" 1>&6
1192 else
1193   echo "configure: failed program was:" >&5
1194   cat conftest.$ac_ext >&5
1195   rm -rf conftest*
1196   echo "$ac_t""no" 1>&6
1197 fi
1198 rm -f conftest*
1199
1200 for ac_func in gettimeofday select strerror strtod strtol
1201 do
1202 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1203 echo "configure:1204: checking for $ac_func" >&5
1204 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1205   echo $ac_n "(cached) $ac_c" 1>&6
1206 else
1207   cat > conftest.$ac_ext <<EOF
1208 #line 1209 "configure"
1209 #include "confdefs.h"
1210 /* System header to define __stub macros and hopefully few prototypes,
1211     which can conflict with char $ac_func(); below.  */
1212 #include <assert.h>
1213 /* Override any gcc2 internal prototype to avoid an error.  */
1214 /* We use char because int might match the return type of a gcc2
1215     builtin and then its argument prototype would still apply.  */
1216 char $ac_func();
1217
1218 int main() {
1219
1220 /* The GNU C library defines this for functions which it implements
1221     to always fail with ENOSYS.  Some functions are actually named
1222     something starting with __ and the normal name is an alias.  */
1223 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1224 choke me
1225 #else
1226 $ac_func();
1227 #endif
1228
1229 ; return 0; }
1230 EOF
1231 if { (eval echo configure:1232: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1232   rm -rf conftest*
1233   eval "ac_cv_func_$ac_func=yes"
1234 else
1235   echo "configure: failed program was:" >&5
1236   cat conftest.$ac_ext >&5
1237   rm -rf conftest*
1238   eval "ac_cv_func_$ac_func=no"
1239 fi
1240 rm -f conftest*
1241 fi
1242
1243 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1244   echo "$ac_t""yes" 1>&6
1245     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1246   cat >> confdefs.h <<EOF
1247 #define $ac_tr_func 1
1248 EOF
1249  
1250 else
1251   echo "$ac_t""no" 1>&6
1252 fi
1253 done
1254
1255 for ac_func in setenv putenv
1256 do
1257 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1258 echo "configure:1259: checking for $ac_func" >&5
1259 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1260   echo $ac_n "(cached) $ac_c" 1>&6
1261 else
1262   cat > conftest.$ac_ext <<EOF
1263 #line 1264 "configure"
1264 #include "confdefs.h"
1265 /* System header to define __stub macros and hopefully few prototypes,
1266     which can conflict with char $ac_func(); below.  */
1267 #include <assert.h>
1268 /* Override any gcc2 internal prototype to avoid an error.  */
1269 /* We use char because int might match the return type of a gcc2
1270     builtin and then its argument prototype would still apply.  */
1271 char $ac_func();
1272
1273 int main() {
1274
1275 /* The GNU C library defines this for functions which it implements
1276     to always fail with ENOSYS.  Some functions are actually named
1277     something starting with __ and the normal name is an alias.  */
1278 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1279 choke me
1280 #else
1281 $ac_func();
1282 #endif
1283
1284 ; return 0; }
1285 EOF
1286 if { (eval echo configure:1287: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1287   rm -rf conftest*
1288   eval "ac_cv_func_$ac_func=yes"
1289 else
1290   echo "configure: failed program was:" >&5
1291   cat conftest.$ac_ext >&5
1292   rm -rf conftest*
1293   eval "ac_cv_func_$ac_func=no"
1294 fi
1295 rm -f conftest*
1296 fi
1297
1298 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1299   echo "$ac_t""yes" 1>&6
1300     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1301   cat >> confdefs.h <<EOF
1302 #define $ac_tr_func 1
1303 EOF
1304  
1305 else
1306   echo "$ac_t""no" 1>&6
1307 fi
1308 done
1309
1310 echo $ac_n "checking for connect""... $ac_c" 1>&6
1311 echo "configure:1312: checking for connect" >&5
1312 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
1313   echo $ac_n "(cached) $ac_c" 1>&6
1314 else
1315   cat > conftest.$ac_ext <<EOF
1316 #line 1317 "configure"
1317 #include "confdefs.h"
1318 /* System header to define __stub macros and hopefully few prototypes,
1319     which can conflict with char connect(); below.  */
1320 #include <assert.h>
1321 /* Override any gcc2 internal prototype to avoid an error.  */
1322 /* We use char because int might match the return type of a gcc2
1323     builtin and then its argument prototype would still apply.  */
1324 char connect();
1325
1326 int main() {
1327
1328 /* The GNU C library defines this for functions which it implements
1329     to always fail with ENOSYS.  Some functions are actually named
1330     something starting with __ and the normal name is an alias.  */
1331 #if defined (__stub_connect) || defined (__stub___connect)
1332 choke me
1333 #else
1334 connect();
1335 #endif
1336
1337 ; return 0; }
1338 EOF
1339 if { (eval echo configure:1340: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1340   rm -rf conftest*
1341   eval "ac_cv_func_connect=yes"
1342 else
1343   echo "configure: failed program was:" >&5
1344   cat conftest.$ac_ext >&5
1345   rm -rf conftest*
1346   eval "ac_cv_func_connect=no"
1347 fi
1348 rm -f conftest*
1349 fi
1350
1351 if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
1352   echo "$ac_t""yes" 1>&6
1353   :
1354 else
1355   echo "$ac_t""no" 1>&6
1356 echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
1357 echo "configure:1358: checking for connect in -lsocket" >&5
1358 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
1359 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1360   echo $ac_n "(cached) $ac_c" 1>&6
1361 else
1362   ac_save_LIBS="$LIBS"
1363 LIBS="-lsocket  $LIBS"
1364 cat > conftest.$ac_ext <<EOF
1365 #line 1366 "configure"
1366 #include "confdefs.h"
1367 /* Override any gcc2 internal prototype to avoid an error.  */
1368 /* We use char because int might match the return type of a gcc2
1369     builtin and then its argument prototype would still apply.  */
1370 char connect();
1371
1372 int main() {
1373 connect()
1374 ; return 0; }
1375 EOF
1376 if { (eval echo configure:1377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1377   rm -rf conftest*
1378   eval "ac_cv_lib_$ac_lib_var=yes"
1379 else
1380   echo "configure: failed program was:" >&5
1381   cat conftest.$ac_ext >&5
1382   rm -rf conftest*
1383   eval "ac_cv_lib_$ac_lib_var=no"
1384 fi
1385 rm -f conftest*
1386 LIBS="$ac_save_LIBS"
1387
1388 fi
1389 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1390   echo "$ac_t""yes" 1>&6
1391     ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1392     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1393   cat >> confdefs.h <<EOF
1394 #define $ac_tr_lib 1
1395 EOF
1396
1397   LIBS="-lsocket $LIBS"
1398
1399 else
1400   echo "$ac_t""no" 1>&6
1401 fi
1402
1403 fi
1404
1405 echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
1406 echo "configure:1407: checking for gethostbyname" >&5
1407 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
1408   echo $ac_n "(cached) $ac_c" 1>&6
1409 else
1410   cat > conftest.$ac_ext <<EOF
1411 #line 1412 "configure"
1412 #include "confdefs.h"
1413 /* System header to define __stub macros and hopefully few prototypes,
1414     which can conflict with char gethostbyname(); below.  */
1415 #include <assert.h>
1416 /* Override any gcc2 internal prototype to avoid an error.  */
1417 /* We use char because int might match the return type of a gcc2
1418     builtin and then its argument prototype would still apply.  */
1419 char gethostbyname();
1420
1421 int main() {
1422
1423 /* The GNU C library defines this for functions which it implements
1424     to always fail with ENOSYS.  Some functions are actually named
1425     something starting with __ and the normal name is an alias.  */
1426 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
1427 choke me
1428 #else
1429 gethostbyname();
1430 #endif
1431
1432 ; return 0; }
1433 EOF
1434 if { (eval echo configure:1435: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1435   rm -rf conftest*
1436   eval "ac_cv_func_gethostbyname=yes"
1437 else
1438   echo "configure: failed program was:" >&5
1439   cat conftest.$ac_ext >&5
1440   rm -rf conftest*
1441   eval "ac_cv_func_gethostbyname=no"
1442 fi
1443 rm -f conftest*
1444 fi
1445
1446 if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
1447   echo "$ac_t""yes" 1>&6
1448   :
1449 else
1450   echo "$ac_t""no" 1>&6
1451 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
1452 echo "configure:1453: checking for gethostbyname in -lnsl" >&5
1453 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
1454 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1455   echo $ac_n "(cached) $ac_c" 1>&6
1456 else
1457   ac_save_LIBS="$LIBS"
1458 LIBS="-lnsl  $LIBS"
1459 cat > conftest.$ac_ext <<EOF
1460 #line 1461 "configure"
1461 #include "confdefs.h"
1462 /* Override any gcc2 internal prototype to avoid an error.  */
1463 /* We use char because int might match the return type of a gcc2
1464     builtin and then its argument prototype would still apply.  */
1465 char gethostbyname();
1466
1467 int main() {
1468 gethostbyname()
1469 ; return 0; }
1470 EOF
1471 if { (eval echo configure:1472: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1472   rm -rf conftest*
1473   eval "ac_cv_lib_$ac_lib_var=yes"
1474 else
1475   echo "configure: failed program was:" >&5
1476   cat conftest.$ac_ext >&5
1477   rm -rf conftest*
1478   eval "ac_cv_lib_$ac_lib_var=no"
1479 fi
1480 rm -f conftest*
1481 LIBS="$ac_save_LIBS"
1482
1483 fi
1484 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1485   echo "$ac_t""yes" 1>&6
1486     ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1487     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1488   cat >> confdefs.h <<EOF
1489 #define $ac_tr_lib 1
1490 EOF
1491
1492   LIBS="-lnsl $LIBS"
1493
1494 else
1495   echo "$ac_t""no" 1>&6
1496 fi
1497
1498 fi
1499
1500 echo $ac_n "checking for nanosleep""... $ac_c" 1>&6
1501 echo "configure:1502: checking for nanosleep" >&5
1502 if eval "test \"`echo '$''{'ac_cv_func_nanosleep'+set}'`\" = set"; then
1503   echo $ac_n "(cached) $ac_c" 1>&6
1504 else
1505   cat > conftest.$ac_ext <<EOF
1506 #line 1507 "configure"
1507 #include "confdefs.h"
1508 /* System header to define __stub macros and hopefully few prototypes,
1509     which can conflict with char nanosleep(); below.  */
1510 #include <assert.h>
1511 /* Override any gcc2 internal prototype to avoid an error.  */
1512 /* We use char because int might match the return type of a gcc2
1513     builtin and then its argument prototype would still apply.  */
1514 char nanosleep();
1515
1516 int main() {
1517
1518 /* The GNU C library defines this for functions which it implements
1519     to always fail with ENOSYS.  Some functions are actually named
1520     something starting with __ and the normal name is an alias.  */
1521 #if defined (__stub_nanosleep) || defined (__stub___nanosleep)
1522 choke me
1523 #else
1524 nanosleep();
1525 #endif
1526
1527 ; return 0; }
1528 EOF
1529 if { (eval echo configure:1530: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1530   rm -rf conftest*
1531   eval "ac_cv_func_nanosleep=yes"
1532 else
1533   echo "configure: failed program was:" >&5
1534   cat conftest.$ac_ext >&5
1535   rm -rf conftest*
1536   eval "ac_cv_func_nanosleep=no"
1537 fi
1538 rm -f conftest*
1539 fi
1540
1541 if eval "test \"`echo '$ac_cv_func_'nanosleep`\" = yes"; then
1542   echo "$ac_t""yes" 1>&6
1543   :
1544 else
1545   echo "$ac_t""no" 1>&6
1546 echo $ac_n "checking for nanosleep in -lrt""... $ac_c" 1>&6
1547 echo "configure:1548: checking for nanosleep in -lrt" >&5
1548 ac_lib_var=`echo rt'_'nanosleep | sed 'y%./+-%__p_%'`
1549 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1550   echo $ac_n "(cached) $ac_c" 1>&6
1551 else
1552   ac_save_LIBS="$LIBS"
1553 LIBS="-lrt  $LIBS"
1554 cat > conftest.$ac_ext <<EOF
1555 #line 1556 "configure"
1556 #include "confdefs.h"
1557 /* Override any gcc2 internal prototype to avoid an error.  */
1558 /* We use char because int might match the return type of a gcc2
1559     builtin and then its argument prototype would still apply.  */
1560 char nanosleep();
1561
1562 int main() {
1563 nanosleep()
1564 ; return 0; }
1565 EOF
1566 if { (eval echo configure:1567: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1567   rm -rf conftest*
1568   eval "ac_cv_lib_$ac_lib_var=yes"
1569 else
1570   echo "configure: failed program was:" >&5
1571   cat conftest.$ac_ext >&5
1572   rm -rf conftest*
1573   eval "ac_cv_lib_$ac_lib_var=no"
1574 fi
1575 rm -f conftest*
1576 LIBS="$ac_save_LIBS"
1577
1578 fi
1579 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1580   echo "$ac_t""yes" 1>&6
1581     ac_tr_lib=HAVE_LIB`echo rt | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1582     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1583   cat >> confdefs.h <<EOF
1584 #define $ac_tr_lib 1
1585 EOF
1586
1587   LIBS="-lrt $LIBS"
1588
1589 else
1590   echo "$ac_t""no" 1>&6
1591 echo $ac_n "checking for nanosleep in -lposix4""... $ac_c" 1>&6
1592 echo "configure:1593: checking for nanosleep in -lposix4" >&5
1593 ac_lib_var=`echo posix4'_'nanosleep | sed 'y%./+-%__p_%'`
1594 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1595   echo $ac_n "(cached) $ac_c" 1>&6
1596 else
1597   ac_save_LIBS="$LIBS"
1598 LIBS="-lposix4  $LIBS"
1599 cat > conftest.$ac_ext <<EOF
1600 #line 1601 "configure"
1601 #include "confdefs.h"
1602 /* Override any gcc2 internal prototype to avoid an error.  */
1603 /* We use char because int might match the return type of a gcc2
1604     builtin and then its argument prototype would still apply.  */
1605 char nanosleep();
1606
1607 int main() {
1608 nanosleep()
1609 ; return 0; }
1610 EOF
1611 if { (eval echo configure:1612: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1612   rm -rf conftest*
1613   eval "ac_cv_lib_$ac_lib_var=yes"
1614 else
1615   echo "configure: failed program was:" >&5
1616   cat conftest.$ac_ext >&5
1617   rm -rf conftest*
1618   eval "ac_cv_lib_$ac_lib_var=no"
1619 fi
1620 rm -f conftest*
1621 LIBS="$ac_save_LIBS"
1622
1623 fi
1624 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1625   echo "$ac_t""yes" 1>&6
1626     ac_tr_lib=HAVE_LIB`echo posix4 | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1627     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1628   cat >> confdefs.h <<EOF
1629 #define $ac_tr_lib 1
1630 EOF
1631
1632   LIBS="-lposix4 $LIBS"
1633
1634 else
1635   echo "$ac_t""no" 1>&6
1636 fi
1637
1638 fi
1639
1640 fi
1641
1642 for ac_func in usleep
1643 do
1644 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1645 echo "configure:1646: checking for $ac_func" >&5
1646 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1647   echo $ac_n "(cached) $ac_c" 1>&6
1648 else
1649   cat > conftest.$ac_ext <<EOF
1650 #line 1651 "configure"
1651 #include "confdefs.h"
1652 /* System header to define __stub macros and hopefully few prototypes,
1653     which can conflict with char $ac_func(); below.  */
1654 #include <assert.h>
1655 /* Override any gcc2 internal prototype to avoid an error.  */
1656 /* We use char because int might match the return type of a gcc2
1657     builtin and then its argument prototype would still apply.  */
1658 char $ac_func();
1659
1660 int main() {
1661
1662 /* The GNU C library defines this for functions which it implements
1663     to always fail with ENOSYS.  Some functions are actually named
1664     something starting with __ and the normal name is an alias.  */
1665 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1666 choke me
1667 #else
1668 $ac_func();
1669 #endif
1670
1671 ; return 0; }
1672 EOF
1673 if { (eval echo configure:1674: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1674   rm -rf conftest*
1675   eval "ac_cv_func_$ac_func=yes"
1676 else
1677   echo "configure: failed program was:" >&5
1678   cat conftest.$ac_ext >&5
1679   rm -rf conftest*
1680   eval "ac_cv_func_$ac_func=no"
1681 fi
1682 rm -f conftest*
1683 fi
1684
1685 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1686   echo "$ac_t""yes" 1>&6
1687     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1688   cat >> confdefs.h <<EOF
1689 #define $ac_tr_func 1
1690 EOF
1691  
1692 else
1693   echo "$ac_t""no" 1>&6
1694 fi
1695 done
1696
1697 echo $ac_n "checking for inet_aton""... $ac_c" 1>&6
1698 echo "configure:1699: checking for inet_aton" >&5
1699 if eval "test \"`echo '$''{'ac_cv_func_inet_aton'+set}'`\" = set"; then
1700   echo $ac_n "(cached) $ac_c" 1>&6
1701 else
1702   cat > conftest.$ac_ext <<EOF
1703 #line 1704 "configure"
1704 #include "confdefs.h"
1705 /* System header to define __stub macros and hopefully few prototypes,
1706     which can conflict with char inet_aton(); below.  */
1707 #include <assert.h>
1708 /* Override any gcc2 internal prototype to avoid an error.  */
1709 /* We use char because int might match the return type of a gcc2
1710     builtin and then its argument prototype would still apply.  */
1711 char inet_aton();
1712
1713 int main() {
1714
1715 /* The GNU C library defines this for functions which it implements
1716     to always fail with ENOSYS.  Some functions are actually named
1717     something starting with __ and the normal name is an alias.  */
1718 #if defined (__stub_inet_aton) || defined (__stub___inet_aton)
1719 choke me
1720 #else
1721 inet_aton();
1722 #endif
1723
1724 ; return 0; }
1725 EOF
1726 if { (eval echo configure:1727: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1727   rm -rf conftest*
1728   eval "ac_cv_func_inet_aton=yes"
1729 else
1730   echo "configure: failed program was:" >&5
1731   cat conftest.$ac_ext >&5
1732   rm -rf conftest*
1733   eval "ac_cv_func_inet_aton=no"
1734 fi
1735 rm -f conftest*
1736 fi
1737
1738 if eval "test \"`echo '$ac_cv_func_'inet_aton`\" = yes"; then
1739   echo "$ac_t""yes" 1>&6
1740   :
1741 else
1742   echo "$ac_t""no" 1>&6
1743 echo $ac_n "checking for inet_aton in -lresolv""... $ac_c" 1>&6
1744 echo "configure:1745: checking for inet_aton in -lresolv" >&5
1745 ac_lib_var=`echo resolv'_'inet_aton | sed 'y%./+-%__p_%'`
1746 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1747   echo $ac_n "(cached) $ac_c" 1>&6
1748 else
1749   ac_save_LIBS="$LIBS"
1750 LIBS="-lresolv  $LIBS"
1751 cat > conftest.$ac_ext <<EOF
1752 #line 1753 "configure"
1753 #include "confdefs.h"
1754 /* Override any gcc2 internal prototype to avoid an error.  */
1755 /* We use char because int might match the return type of a gcc2
1756     builtin and then its argument prototype would still apply.  */
1757 char inet_aton();
1758
1759 int main() {
1760 inet_aton()
1761 ; return 0; }
1762 EOF
1763 if { (eval echo configure:1764: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1764   rm -rf conftest*
1765   eval "ac_cv_lib_$ac_lib_var=yes"
1766 else
1767   echo "configure: failed program was:" >&5
1768   cat conftest.$ac_ext >&5
1769   rm -rf conftest*
1770   eval "ac_cv_lib_$ac_lib_var=no"
1771 fi
1772 rm -f conftest*
1773 LIBS="$ac_save_LIBS"
1774
1775 fi
1776 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1777   echo "$ac_t""yes" 1>&6
1778     ac_tr_lib=HAVE_LIB`echo resolv | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1779     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1780   cat >> confdefs.h <<EOF
1781 #define $ac_tr_lib 1
1782 EOF
1783
1784   LIBS="-lresolv $LIBS"
1785
1786 else
1787   echo "$ac_t""no" 1>&6
1788 fi
1789
1790 fi
1791
1792 for ac_func in vasprintf
1793 do
1794 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1795 echo "configure:1796: checking for $ac_func" >&5
1796 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1797   echo $ac_n "(cached) $ac_c" 1>&6
1798 else
1799   cat > conftest.$ac_ext <<EOF
1800 #line 1801 "configure"
1801 #include "confdefs.h"
1802 /* System header to define __stub macros and hopefully few prototypes,
1803     which can conflict with char $ac_func(); below.  */
1804 #include <assert.h>
1805 /* Override any gcc2 internal prototype to avoid an error.  */
1806 /* We use char because int might match the return type of a gcc2
1807     builtin and then its argument prototype would still apply.  */
1808 char $ac_func();
1809
1810 int main() {
1811
1812 /* The GNU C library defines this for functions which it implements
1813     to always fail with ENOSYS.  Some functions are actually named
1814     something starting with __ and the normal name is an alias.  */
1815 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1816 choke me
1817 #else
1818 $ac_func();
1819 #endif
1820
1821 ; return 0; }
1822 EOF
1823 if { (eval echo configure:1824: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1824   rm -rf conftest*
1825   eval "ac_cv_func_$ac_func=yes"
1826 else
1827   echo "configure: failed program was:" >&5
1828   cat conftest.$ac_ext >&5
1829   rm -rf conftest*
1830   eval "ac_cv_func_$ac_func=no"
1831 fi
1832 rm -f conftest*
1833 fi
1834
1835 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1836   echo "$ac_t""yes" 1>&6
1837     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1838   cat >> confdefs.h <<EOF
1839 #define $ac_tr_func 1
1840 EOF
1841  
1842 else
1843   echo "$ac_t""no" 1>&6
1844 fi
1845 done
1846
1847 for ac_hdr in unistd.h
1848 do
1849 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1850 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1851 echo "configure:1852: checking for $ac_hdr" >&5
1852 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1853   echo $ac_n "(cached) $ac_c" 1>&6
1854 else
1855   cat > conftest.$ac_ext <<EOF
1856 #line 1857 "configure"
1857 #include "confdefs.h"
1858 #include <$ac_hdr>
1859 EOF
1860 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1861 { (eval echo configure:1862: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1862 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1863 if test -z "$ac_err"; then
1864   rm -rf conftest*
1865   eval "ac_cv_header_$ac_safe=yes"
1866 else
1867   echo "$ac_err" >&5
1868   echo "configure: failed program was:" >&5
1869   cat conftest.$ac_ext >&5
1870   rm -rf conftest*
1871   eval "ac_cv_header_$ac_safe=no"
1872 fi
1873 rm -f conftest*
1874 fi
1875 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1876   echo "$ac_t""yes" 1>&6
1877     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1878   cat >> confdefs.h <<EOF
1879 #define $ac_tr_hdr 1
1880 EOF
1881  
1882 else
1883   echo "$ac_t""no" 1>&6
1884 fi
1885 done
1886
1887 for ac_func in getpagesize
1888 do
1889 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1890 echo "configure:1891: checking for $ac_func" >&5
1891 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1892   echo $ac_n "(cached) $ac_c" 1>&6
1893 else
1894   cat > conftest.$ac_ext <<EOF
1895 #line 1896 "configure"
1896 #include "confdefs.h"
1897 /* System header to define __stub macros and hopefully few prototypes,
1898     which can conflict with char $ac_func(); below.  */
1899 #include <assert.h>
1900 /* Override any gcc2 internal prototype to avoid an error.  */
1901 /* We use char because int might match the return type of a gcc2
1902     builtin and then its argument prototype would still apply.  */
1903 char $ac_func();
1904
1905 int main() {
1906
1907 /* The GNU C library defines this for functions which it implements
1908     to always fail with ENOSYS.  Some functions are actually named
1909     something starting with __ and the normal name is an alias.  */
1910 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1911 choke me
1912 #else
1913 $ac_func();
1914 #endif
1915
1916 ; return 0; }
1917 EOF
1918 if { (eval echo configure:1919: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1919   rm -rf conftest*
1920   eval "ac_cv_func_$ac_func=yes"
1921 else
1922   echo "configure: failed program was:" >&5
1923   cat conftest.$ac_ext >&5
1924   rm -rf conftest*
1925   eval "ac_cv_func_$ac_func=no"
1926 fi
1927 rm -f conftest*
1928 fi
1929
1930 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1931   echo "$ac_t""yes" 1>&6
1932     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1933   cat >> confdefs.h <<EOF
1934 #define $ac_tr_func 1
1935 EOF
1936  
1937 else
1938   echo "$ac_t""no" 1>&6
1939 fi
1940 done
1941
1942 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
1943 echo "configure:1944: checking for working mmap" >&5
1944 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
1945   echo $ac_n "(cached) $ac_c" 1>&6
1946 else
1947   if test "$cross_compiling" = yes; then
1948   ac_cv_func_mmap_fixed_mapped=no
1949 else
1950   cat > conftest.$ac_ext <<EOF
1951 #line 1952 "configure"
1952 #include "confdefs.h"
1953
1954 /* Thanks to Mike Haertel and Jim Avera for this test.
1955    Here is a matrix of mmap possibilities:
1956         mmap private not fixed
1957         mmap private fixed at somewhere currently unmapped
1958         mmap private fixed at somewhere already mapped
1959         mmap shared not fixed
1960         mmap shared fixed at somewhere currently unmapped
1961         mmap shared fixed at somewhere already mapped
1962    For private mappings, we should verify that changes cannot be read()
1963    back from the file, nor mmap's back from the file at a different
1964    address.  (There have been systems where private was not correctly
1965    implemented like the infamous i386 svr4.0, and systems where the
1966    VM page cache was not coherent with the filesystem buffer cache
1967    like early versions of FreeBSD and possibly contemporary NetBSD.)
1968    For shared mappings, we should conversely verify that changes get
1969    propogated back to all the places they're supposed to be.
1970
1971    Grep wants private fixed already mapped.
1972    The main things grep needs to know about mmap are:
1973    * does it exist and is it safe to write into the mmap'd area
1974    * how to use it (BSD variants)  */
1975 #include <sys/types.h>
1976 #include <fcntl.h>
1977 #include <sys/mman.h>
1978 #include <stdlib.h>
1979 #include <sys/stat.h>
1980
1981 #ifdef HAVE_UNISTD_H
1982 # include <unistd.h>
1983 #endif
1984
1985 /* This mess was copied from the GNU getpagesize.h.  */
1986 #ifndef HAVE_GETPAGESIZE
1987
1988 /* Assume that all systems that can run configure have sys/param.h.  */
1989 # ifndef HAVE_SYS_PARAM_H
1990 #  define HAVE_SYS_PARAM_H 1
1991 # endif
1992
1993 # ifdef _SC_PAGESIZE
1994 #  define getpagesize() sysconf(_SC_PAGESIZE)
1995 # else /* no _SC_PAGESIZE */
1996 #  ifdef HAVE_SYS_PARAM_H
1997 #   include <sys/param.h>
1998 #   ifdef EXEC_PAGESIZE
1999 #    define getpagesize() EXEC_PAGESIZE
2000 #   else /* no EXEC_PAGESIZE */
2001 #    ifdef NBPG
2002 #     define getpagesize() NBPG * CLSIZE
2003 #     ifndef CLSIZE
2004 #      define CLSIZE 1
2005 #     endif /* no CLSIZE */
2006 #    else /* no NBPG */
2007 #     ifdef NBPC
2008 #      define getpagesize() NBPC
2009 #     else /* no NBPC */
2010 #      ifdef PAGESIZE
2011 #       define getpagesize() PAGESIZE
2012 #      endif /* PAGESIZE */
2013 #     endif /* no NBPC */
2014 #    endif /* no NBPG */
2015 #   endif /* no EXEC_PAGESIZE */
2016 #  else /* no HAVE_SYS_PARAM_H */
2017 #   define getpagesize() 8192   /* punt totally */
2018 #  endif /* no HAVE_SYS_PARAM_H */
2019 # endif /* no _SC_PAGESIZE */
2020
2021 #endif /* no HAVE_GETPAGESIZE */
2022
2023 #ifdef __cplusplus
2024 extern "C" { void *malloc(unsigned); }
2025 #else
2026 char *malloc();
2027 #endif
2028
2029 int
2030 main()
2031 {
2032         char *data, *data2, *data3;
2033         int i, pagesize;
2034         int fd;
2035
2036         pagesize = getpagesize();
2037
2038         /*
2039          * First, make a file with some known garbage in it.
2040          */
2041         data = (char*)malloc(pagesize);
2042         if (!data)
2043                 exit(1);
2044         for (i = 0; i < pagesize; ++i)
2045                 *(data + i) = rand();
2046         umask(0);
2047         fd = creat("conftestmmap", 0600);
2048         if (fd < 0)
2049                 exit(1);
2050         if (write(fd, data, pagesize) != pagesize)
2051                 exit(1);
2052         close(fd);
2053
2054         /*
2055          * Next, try to mmap the file at a fixed address which
2056          * already has something else allocated at it.  If we can,
2057          * also make sure that we see the same garbage.
2058          */
2059         fd = open("conftestmmap", O_RDWR);
2060         if (fd < 0)
2061                 exit(1);
2062         data2 = (char*)malloc(2 * pagesize);
2063         if (!data2)
2064                 exit(1);
2065         data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
2066         if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
2067             MAP_PRIVATE | MAP_FIXED, fd, 0L))
2068                 exit(1);
2069         for (i = 0; i < pagesize; ++i)
2070                 if (*(data + i) != *(data2 + i))
2071                         exit(1);
2072
2073         /*
2074          * Finally, make sure that changes to the mapped area
2075          * do not percolate back to the file as seen by read().
2076          * (This is a bug on some variants of i386 svr4.0.)
2077          */
2078         for (i = 0; i < pagesize; ++i)
2079                 *(data2 + i) = *(data2 + i) + 1;
2080         data3 = (char*)malloc(pagesize);
2081         if (!data3)
2082                 exit(1);
2083         if (read(fd, data3, pagesize) != pagesize)
2084                 exit(1);
2085         for (i = 0; i < pagesize; ++i)
2086                 if (*(data + i) != *(data3 + i))
2087                         exit(1);
2088         close(fd);
2089         unlink("conftestmmap");
2090         exit(0);
2091 }
2092
2093 EOF
2094 if { (eval echo configure:2095: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2095 then
2096   ac_cv_func_mmap_fixed_mapped=yes
2097 else
2098   echo "configure: failed program was:" >&5
2099   cat conftest.$ac_ext >&5
2100   rm -fr conftest*
2101   ac_cv_func_mmap_fixed_mapped=no
2102 fi
2103 rm -fr conftest*
2104 fi
2105
2106 fi
2107
2108 echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
2109 if test $ac_cv_func_mmap_fixed_mapped = yes; then
2110   cat >> confdefs.h <<\EOF
2111 #define HAVE_MMAP 1
2112 EOF
2113
2114 fi
2115
2116 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
2117 echo "configure:2118: checking return type of signal handlers" >&5
2118 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
2119   echo $ac_n "(cached) $ac_c" 1>&6
2120 else
2121   cat > conftest.$ac_ext <<EOF
2122 #line 2123 "configure"
2123 #include "confdefs.h"
2124 #include <sys/types.h>
2125 #include <signal.h>
2126 #ifdef signal
2127 #undef signal
2128 #endif
2129 #ifdef __cplusplus
2130 extern "C" void (*signal (int, void (*)(int)))(int);
2131 #else
2132 void (*signal ()) ();
2133 #endif
2134
2135 int main() {
2136 int i;
2137 ; return 0; }
2138 EOF
2139 if { (eval echo configure:2140: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2140   rm -rf conftest*
2141   ac_cv_type_signal=void
2142 else
2143   echo "configure: failed program was:" >&5
2144   cat conftest.$ac_ext >&5
2145   rm -rf conftest*
2146   ac_cv_type_signal=int
2147 fi
2148 rm -f conftest*
2149 fi
2150
2151 echo "$ac_t""$ac_cv_type_signal" 1>&6
2152 cat >> confdefs.h <<EOF
2153 #define RETSIGTYPE $ac_cv_type_signal
2154 EOF
2155
2156
2157 echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
2158 echo "configure:2159: checking for dlopen in -ldl" >&5
2159 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
2160 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2161   echo $ac_n "(cached) $ac_c" 1>&6
2162 else
2163   ac_save_LIBS="$LIBS"
2164 LIBS="-ldl  $LIBS"
2165 cat > conftest.$ac_ext <<EOF
2166 #line 2167 "configure"
2167 #include "confdefs.h"
2168 /* Override any gcc2 internal prototype to avoid an error.  */
2169 /* We use char because int might match the return type of a gcc2
2170     builtin and then its argument prototype would still apply.  */
2171 char dlopen();
2172
2173 int main() {
2174 dlopen()
2175 ; return 0; }
2176 EOF
2177 if { (eval echo configure:2178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2178   rm -rf conftest*
2179   eval "ac_cv_lib_$ac_lib_var=yes"
2180 else
2181   echo "configure: failed program was:" >&5
2182   cat conftest.$ac_ext >&5
2183   rm -rf conftest*
2184   eval "ac_cv_lib_$ac_lib_var=no"
2185 fi
2186 rm -f conftest*
2187 LIBS="$ac_save_LIBS"
2188
2189 fi
2190 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2191   echo "$ac_t""yes" 1>&6
2192     ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2193     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2194   cat >> confdefs.h <<EOF
2195 #define $ac_tr_lib 1
2196 EOF
2197
2198   LIBS="-ldl $LIBS"
2199
2200 else
2201   echo "$ac_t""no" 1>&6
2202 fi
2203
2204 echo $ac_n "checking for optarg in -lgnugetopt""... $ac_c" 1>&6
2205 echo "configure:2206: checking for optarg in -lgnugetopt" >&5
2206 ac_lib_var=`echo gnugetopt'_'optarg | sed 'y%./+-%__p_%'`
2207 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2208   echo $ac_n "(cached) $ac_c" 1>&6
2209 else
2210   ac_save_LIBS="$LIBS"
2211 LIBS="-lgnugetopt  $LIBS"
2212 cat > conftest.$ac_ext <<EOF
2213 #line 2214 "configure"
2214 #include "confdefs.h"
2215 /* Override any gcc2 internal prototype to avoid an error.  */
2216 /* We use char because int might match the return type of a gcc2
2217     builtin and then its argument prototype would still apply.  */
2218 char optarg();
2219
2220 int main() {
2221 optarg()
2222 ; return 0; }
2223 EOF
2224 if { (eval echo configure:2225: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2225   rm -rf conftest*
2226   eval "ac_cv_lib_$ac_lib_var=yes"
2227 else
2228   echo "configure: failed program was:" >&5
2229   cat conftest.$ac_ext >&5
2230   rm -rf conftest*
2231   eval "ac_cv_lib_$ac_lib_var=no"
2232 fi
2233 rm -f conftest*
2234 LIBS="$ac_save_LIBS"
2235
2236 fi
2237 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2238   echo "$ac_t""yes" 1>&6
2239     ac_tr_lib=HAVE_LIB`echo gnugetopt | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2240     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2241   cat >> confdefs.h <<EOF
2242 #define $ac_tr_lib 1
2243 EOF
2244
2245   LIBS="-lgnugetopt $LIBS"
2246
2247 else
2248   echo "$ac_t""no" 1>&6
2249 fi
2250
2251 echo $ac_n "checking for _ in -lbe""... $ac_c" 1>&6
2252 echo "configure:2253: checking for _ in -lbe" >&5
2253 ac_lib_var=`echo be'_'_ | sed 'y%./+-%__p_%'`
2254 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2255   echo $ac_n "(cached) $ac_c" 1>&6
2256 else
2257   ac_save_LIBS="$LIBS"
2258 LIBS="-lbe  $LIBS"
2259 cat > conftest.$ac_ext <<EOF
2260 #line 2261 "configure"
2261 #include "confdefs.h"
2262 /* Override any gcc2 internal prototype to avoid an error.  */
2263 /* We use char because int might match the return type of a gcc2
2264     builtin and then its argument prototype would still apply.  */
2265 char _();
2266
2267 int main() {
2268 _()
2269 ; return 0; }
2270 EOF
2271 if { (eval echo configure:2272: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2272   rm -rf conftest*
2273   eval "ac_cv_lib_$ac_lib_var=yes"
2274 else
2275   echo "configure: failed program was:" >&5
2276   cat conftest.$ac_ext >&5
2277   rm -rf conftest*
2278   eval "ac_cv_lib_$ac_lib_var=no"
2279 fi
2280 rm -f conftest*
2281 LIBS="$ac_save_LIBS"
2282
2283 fi
2284 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2285   echo "$ac_t""yes" 1>&6
2286     ac_tr_lib=HAVE_LIB`echo be | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2287     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2288   cat >> confdefs.h <<EOF
2289 #define $ac_tr_lib 1
2290 EOF
2291
2292   LIBS="-lbe $LIBS"
2293
2294 else
2295   echo "$ac_t""no" 1>&6
2296 fi
2297
2298 echo $ac_n "checking for _ in -lgame""... $ac_c" 1>&6
2299 echo "configure:2300: checking for _ in -lgame" >&5
2300 ac_lib_var=`echo game'_'_ | sed 'y%./+-%__p_%'`
2301 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2302   echo $ac_n "(cached) $ac_c" 1>&6
2303 else
2304   ac_save_LIBS="$LIBS"
2305 LIBS="-lgame  $LIBS"
2306 cat > conftest.$ac_ext <<EOF
2307 #line 2308 "configure"
2308 #include "confdefs.h"
2309 /* Override any gcc2 internal prototype to avoid an error.  */
2310 /* We use char because int might match the return type of a gcc2
2311     builtin and then its argument prototype would still apply.  */
2312 char _();
2313
2314 int main() {
2315 _()
2316 ; return 0; }
2317 EOF
2318 if { (eval echo configure:2319: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2319   rm -rf conftest*
2320   eval "ac_cv_lib_$ac_lib_var=yes"
2321 else
2322   echo "configure: failed program was:" >&5
2323   cat conftest.$ac_ext >&5
2324   rm -rf conftest*
2325   eval "ac_cv_lib_$ac_lib_var=no"
2326 fi
2327 rm -f conftest*
2328 LIBS="$ac_save_LIBS"
2329
2330 fi
2331 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2332   echo "$ac_t""yes" 1>&6
2333     ac_tr_lib=HAVE_LIB`echo game | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2334     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2335   cat >> confdefs.h <<EOF
2336 #define $ac_tr_lib 1
2337 EOF
2338
2339   LIBS="-lgame $LIBS"
2340
2341 else
2342   echo "$ac_t""no" 1>&6
2343 fi
2344
2345 echo $ac_n "checking for _ in -lroot""... $ac_c" 1>&6
2346 echo "configure:2347: checking for _ in -lroot" >&5
2347 ac_lib_var=`echo root'_'_ | sed 'y%./+-%__p_%'`
2348 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2349   echo $ac_n "(cached) $ac_c" 1>&6
2350 else
2351   ac_save_LIBS="$LIBS"
2352 LIBS="-lroot  $LIBS"
2353 cat > conftest.$ac_ext <<EOF
2354 #line 2355 "configure"
2355 #include "confdefs.h"
2356 /* Override any gcc2 internal prototype to avoid an error.  */
2357 /* We use char because int might match the return type of a gcc2
2358     builtin and then its argument prototype would still apply.  */
2359 char _();
2360
2361 int main() {
2362 _()
2363 ; return 0; }
2364 EOF
2365 if { (eval echo configure:2366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2366   rm -rf conftest*
2367   eval "ac_cv_lib_$ac_lib_var=yes"
2368 else
2369   echo "configure: failed program was:" >&5
2370   cat conftest.$ac_ext >&5
2371   rm -rf conftest*
2372   eval "ac_cv_lib_$ac_lib_var=no"
2373 fi
2374 rm -f conftest*
2375 LIBS="$ac_save_LIBS"
2376
2377 fi
2378 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2379   echo "$ac_t""yes" 1>&6
2380     ac_tr_lib=HAVE_LIB`echo root | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2381     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2382   cat >> confdefs.h <<EOF
2383 #define $ac_tr_lib 1
2384 EOF
2385
2386   LIBS="-lroot $LIBS"
2387
2388 else
2389   echo "$ac_t""no" 1>&6
2390 fi
2391
2392 echo $ac_n "checking for powl in -lm""... $ac_c" 1>&6
2393 echo "configure:2394: checking for powl in -lm" >&5
2394 ac_lib_var=`echo m'_'powl | sed 'y%./+-%__p_%'`
2395 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2396   echo $ac_n "(cached) $ac_c" 1>&6
2397 else
2398   ac_save_LIBS="$LIBS"
2399 LIBS="-lm  $LIBS"
2400 cat > conftest.$ac_ext <<EOF
2401 #line 2402 "configure"
2402 #include "confdefs.h"
2403 /* Override any gcc2 internal prototype to avoid an error.  */
2404 /* We use char because int might match the return type of a gcc2
2405     builtin and then its argument prototype would still apply.  */
2406 char powl();
2407
2408 int main() {
2409 powl()
2410 ; return 0; }
2411 EOF
2412 if { (eval echo configure:2413: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2413   rm -rf conftest*
2414   eval "ac_cv_lib_$ac_lib_var=yes"
2415 else
2416   echo "configure: failed program was:" >&5
2417   cat conftest.$ac_ext >&5
2418   rm -rf conftest*
2419   eval "ac_cv_lib_$ac_lib_var=no"
2420 fi
2421 rm -f conftest*
2422 LIBS="$ac_save_LIBS"
2423
2424 fi
2425 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2426   echo "$ac_t""yes" 1>&6
2427     ac_tr_lib=HAVE_LIB`echo m | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2428     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2429   cat >> confdefs.h <<EOF
2430 #define $ac_tr_lib 1
2431 EOF
2432
2433   LIBS="-lm $LIBS"
2434
2435 else
2436   echo "$ac_t""no" 1>&6
2437 fi
2438
2439 echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
2440 echo "configure:2441: checking for pthread_create in -lpthread" >&5
2441 ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'`
2442 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2443   echo $ac_n "(cached) $ac_c" 1>&6
2444 else
2445   ac_save_LIBS="$LIBS"
2446 LIBS="-lpthread  $LIBS"
2447 cat > conftest.$ac_ext <<EOF
2448 #line 2449 "configure"
2449 #include "confdefs.h"
2450 /* Override any gcc2 internal prototype to avoid an error.  */
2451 /* We use char because int might match the return type of a gcc2
2452     builtin and then its argument prototype would still apply.  */
2453 char pthread_create();
2454
2455 int main() {
2456 pthread_create()
2457 ; return 0; }
2458 EOF
2459 if { (eval echo configure:2460: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2460   rm -rf conftest*
2461   eval "ac_cv_lib_$ac_lib_var=yes"
2462 else
2463   echo "configure: failed program was:" >&5
2464   cat conftest.$ac_ext >&5
2465   rm -rf conftest*
2466   eval "ac_cv_lib_$ac_lib_var=no"
2467 fi
2468 rm -f conftest*
2469 LIBS="$ac_save_LIBS"
2470
2471 fi
2472 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2473   echo "$ac_t""yes" 1>&6
2474     ac_tr_lib=HAVE_LIB`echo pthread | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2475     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2476   cat >> confdefs.h <<EOF
2477 #define $ac_tr_lib 1
2478 EOF
2479
2480   LIBS="-lpthread $LIBS"
2481
2482 else
2483   echo "$ac_t""no" 1>&6
2484 fi
2485
2486 echo $ac_n "checking for thread_create in -lthreads""... $ac_c" 1>&6
2487 echo "configure:2488: checking for thread_create in -lthreads" >&5
2488 ac_lib_var=`echo threads'_'thread_create | sed 'y%./+-%__p_%'`
2489 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2490   echo $ac_n "(cached) $ac_c" 1>&6
2491 else
2492   ac_save_LIBS="$LIBS"
2493 LIBS="-lthreads  $LIBS"
2494 cat > conftest.$ac_ext <<EOF
2495 #line 2496 "configure"
2496 #include "confdefs.h"
2497 /* Override any gcc2 internal prototype to avoid an error.  */
2498 /* We use char because int might match the return type of a gcc2
2499     builtin and then its argument prototype would still apply.  */
2500 char thread_create();
2501
2502 int main() {
2503 thread_create()
2504 ; return 0; }
2505 EOF
2506 if { (eval echo configure:2507: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2507   rm -rf conftest*
2508   eval "ac_cv_lib_$ac_lib_var=yes"
2509 else
2510   echo "configure: failed program was:" >&5
2511   cat conftest.$ac_ext >&5
2512   rm -rf conftest*
2513   eval "ac_cv_lib_$ac_lib_var=no"
2514 fi
2515 rm -f conftest*
2516 LIBS="$ac_save_LIBS"
2517
2518 fi
2519 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2520   echo "$ac_t""yes" 1>&6
2521     ac_tr_lib=HAVE_LIB`echo threads | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2522     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2523   cat >> confdefs.h <<EOF
2524 #define $ac_tr_lib 1
2525 EOF
2526
2527   LIBS="-lthreads $LIBS"
2528
2529 else
2530   echo "$ac_t""no" 1>&6
2531 fi
2532
2533
2534 echo $ac_n "checking for getopt_long""... $ac_c" 1>&6
2535 echo "configure:2536: checking for getopt_long" >&5
2536 if eval "test \"`echo '$''{'ac_cv_func_getopt_long'+set}'`\" = set"; then
2537   echo $ac_n "(cached) $ac_c" 1>&6
2538 else
2539   cat > conftest.$ac_ext <<EOF
2540 #line 2541 "configure"
2541 #include "confdefs.h"
2542 /* System header to define __stub macros and hopefully few prototypes,
2543     which can conflict with char getopt_long(); below.  */
2544 #include <assert.h>
2545 /* Override any gcc2 internal prototype to avoid an error.  */
2546 /* We use char because int might match the return type of a gcc2
2547     builtin and then its argument prototype would still apply.  */
2548 char getopt_long();
2549
2550 int main() {
2551
2552 /* The GNU C library defines this for functions which it implements
2553     to always fail with ENOSYS.  Some functions are actually named
2554     something starting with __ and the normal name is an alias.  */
2555 #if defined (__stub_getopt_long) || defined (__stub___getopt_long)
2556 choke me
2557 #else
2558 getopt_long();
2559 #endif
2560
2561 ; return 0; }
2562 EOF
2563 if { (eval echo configure:2564: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2564   rm -rf conftest*
2565   eval "ac_cv_func_getopt_long=yes"
2566 else
2567   echo "configure: failed program was:" >&5
2568   cat conftest.$ac_ext >&5
2569   rm -rf conftest*
2570   eval "ac_cv_func_getopt_long=no"
2571 fi
2572 rm -f conftest*
2573 fi
2574
2575 if eval "test \"`echo '$ac_cv_func_'getopt_long`\" = yes"; then
2576   echo "$ac_t""yes" 1>&6
2577   :
2578 else
2579   echo "$ac_t""no" 1>&6
2580 LIBOBJS="$LIBOBJS getopt.o getopt1.o"
2581 fi
2582
2583
2584
2585 CPPFLAGS="${CPPFLAGS} -I/usr/local/include"
2586 for ac_hdr in stddef.h
2587 do
2588 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2589 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2590 echo "configure:2591: checking for $ac_hdr" >&5
2591 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2592   echo $ac_n "(cached) $ac_c" 1>&6
2593 else
2594   cat > conftest.$ac_ext <<EOF
2595 #line 2596 "configure"
2596 #include "confdefs.h"
2597 #include <$ac_hdr>
2598 EOF
2599 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2600 { (eval echo configure:2601: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2601 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2602 if test -z "$ac_err"; then
2603   rm -rf conftest*
2604   eval "ac_cv_header_$ac_safe=yes"
2605 else
2606   echo "$ac_err" >&5
2607   echo "configure: failed program was:" >&5
2608   cat conftest.$ac_ext >&5
2609   rm -rf conftest*
2610   eval "ac_cv_header_$ac_safe=no"
2611 fi
2612 rm -f conftest*
2613 fi
2614 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2615   echo "$ac_t""yes" 1>&6
2616     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2617   cat >> confdefs.h <<EOF
2618 #define $ac_tr_hdr 1
2619 EOF
2620  
2621 else
2622   echo "$ac_t""no" 1>&6
2623 fi
2624 done
2625
2626 for ac_hdr in getopt.h
2627 do
2628 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2629 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2630 echo "configure:2631: checking for $ac_hdr" >&5
2631 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2632   echo $ac_n "(cached) $ac_c" 1>&6
2633 else
2634   cat > conftest.$ac_ext <<EOF
2635 #line 2636 "configure"
2636 #include "confdefs.h"
2637 #include <$ac_hdr>
2638 EOF
2639 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2640 { (eval echo configure:2641: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2641 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2642 if test -z "$ac_err"; then
2643   rm -rf conftest*
2644   eval "ac_cv_header_$ac_safe=yes"
2645 else
2646   echo "$ac_err" >&5
2647   echo "configure: failed program was:" >&5
2648   cat conftest.$ac_ext >&5
2649   rm -rf conftest*
2650   eval "ac_cv_header_$ac_safe=no"
2651 fi
2652 rm -f conftest*
2653 fi
2654 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2655   echo "$ac_t""yes" 1>&6
2656     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2657   cat >> confdefs.h <<EOF
2658 #define $ac_tr_hdr 1
2659 EOF
2660  
2661 else
2662   echo "$ac_t""no" 1>&6
2663 fi
2664 done
2665
2666 for ac_hdr in sys/sockio.h
2667 do
2668 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2669 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2670 echo "configure:2671: checking for $ac_hdr" >&5
2671 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2672   echo $ac_n "(cached) $ac_c" 1>&6
2673 else
2674   cat > conftest.$ac_ext <<EOF
2675 #line 2676 "configure"
2676 #include "confdefs.h"
2677 #include <$ac_hdr>
2678 EOF
2679 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2680 { (eval echo configure:2681: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2681 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2682 if test -z "$ac_err"; then
2683   rm -rf conftest*
2684   eval "ac_cv_header_$ac_safe=yes"
2685 else
2686   echo "$ac_err" >&5
2687   echo "configure: failed program was:" >&5
2688   cat conftest.$ac_ext >&5
2689   rm -rf conftest*
2690   eval "ac_cv_header_$ac_safe=no"
2691 fi
2692 rm -f conftest*
2693 fi
2694 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2695   echo "$ac_t""yes" 1>&6
2696     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2697   cat >> confdefs.h <<EOF
2698 #define $ac_tr_hdr 1
2699 EOF
2700  
2701 else
2702   echo "$ac_t""no" 1>&6
2703 fi
2704 done
2705
2706 for ac_hdr in fcntl.h sys/ioctl.h sys/time.h unistd.h
2707 do
2708 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2709 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2710 echo "configure:2711: checking for $ac_hdr" >&5
2711 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2712   echo $ac_n "(cached) $ac_c" 1>&6
2713 else
2714   cat > conftest.$ac_ext <<EOF
2715 #line 2716 "configure"
2716 #include "confdefs.h"
2717 #include <$ac_hdr>
2718 EOF
2719 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2720 { (eval echo configure:2721: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2721 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2722 if test -z "$ac_err"; then
2723   rm -rf conftest*
2724   eval "ac_cv_header_$ac_safe=yes"
2725 else
2726   echo "$ac_err" >&5
2727   echo "configure: failed program was:" >&5
2728   cat conftest.$ac_ext >&5
2729   rm -rf conftest*
2730   eval "ac_cv_header_$ac_safe=no"
2731 fi
2732 rm -f conftest*
2733 fi
2734 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2735   echo "$ac_t""yes" 1>&6
2736     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2737   cat >> confdefs.h <<EOF
2738 #define $ac_tr_hdr 1
2739 EOF
2740  
2741 else
2742   echo "$ac_t""no" 1>&6
2743 fi
2744 done
2745
2746 for ac_hdr in sys/soundcard.h machine/soundcard.h
2747 do
2748 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2749 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2750 echo "configure:2751: checking for $ac_hdr" >&5
2751 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2752   echo $ac_n "(cached) $ac_c" 1>&6
2753 else
2754   cat > conftest.$ac_ext <<EOF
2755 #line 2756 "configure"
2756 #include "confdefs.h"
2757 #include <$ac_hdr>
2758 EOF
2759 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2760 { (eval echo configure:2761: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2761 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2762 if test -z "$ac_err"; then
2763   rm -rf conftest*
2764   eval "ac_cv_header_$ac_safe=yes"
2765 else
2766   echo "$ac_err" >&5
2767   echo "configure: failed program was:" >&5
2768   cat conftest.$ac_ext >&5
2769   rm -rf conftest*
2770   eval "ac_cv_header_$ac_safe=no"
2771 fi
2772 rm -f conftest*
2773 fi
2774 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2775   echo "$ac_t""yes" 1>&6
2776     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2777   cat >> confdefs.h <<EOF
2778 #define $ac_tr_hdr 1
2779 EOF
2780  
2781 else
2782   echo "$ac_t""no" 1>&6
2783 fi
2784 done
2785
2786 for ac_hdr in dlfcn.h image.h
2787 do
2788 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2789 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2790 echo "configure:2791: checking for $ac_hdr" >&5
2791 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2792   echo $ac_n "(cached) $ac_c" 1>&6
2793 else
2794   cat > conftest.$ac_ext <<EOF
2795 #line 2796 "configure"
2796 #include "confdefs.h"
2797 #include <$ac_hdr>
2798 EOF
2799 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2800 { (eval echo configure:2801: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2801 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2802 if test -z "$ac_err"; then
2803   rm -rf conftest*
2804   eval "ac_cv_header_$ac_safe=yes"
2805 else
2806   echo "$ac_err" >&5
2807   echo "configure: failed program was:" >&5
2808   cat conftest.$ac_ext >&5
2809   rm -rf conftest*
2810   eval "ac_cv_header_$ac_safe=no"
2811 fi
2812 rm -f conftest*
2813 fi
2814 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2815   echo "$ac_t""yes" 1>&6
2816     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2817   cat >> confdefs.h <<EOF
2818 #define $ac_tr_hdr 1
2819 EOF
2820  
2821 else
2822   echo "$ac_t""no" 1>&6
2823 fi
2824 done
2825
2826 for ac_hdr in arpa/inet.h net/if.h netinet/in.h sys/socket.h
2827 do
2828 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2829 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2830 echo "configure:2831: checking for $ac_hdr" >&5
2831 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2832   echo $ac_n "(cached) $ac_c" 1>&6
2833 else
2834   cat > conftest.$ac_ext <<EOF
2835 #line 2836 "configure"
2836 #include "confdefs.h"
2837 #include <$ac_hdr>
2838 EOF
2839 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2840 { (eval echo configure:2841: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2841 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2842 if test -z "$ac_err"; then
2843   rm -rf conftest*
2844   eval "ac_cv_header_$ac_safe=yes"
2845 else
2846   echo "$ac_err" >&5
2847   echo "configure: failed program was:" >&5
2848   cat conftest.$ac_ext >&5
2849   rm -rf conftest*
2850   eval "ac_cv_header_$ac_safe=no"
2851 fi
2852 rm -f conftest*
2853 fi
2854 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2855   echo "$ac_t""yes" 1>&6
2856     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2857   cat >> confdefs.h <<EOF
2858 #define $ac_tr_hdr 1
2859 EOF
2860  
2861 else
2862   echo "$ac_t""no" 1>&6
2863 fi
2864 done
2865
2866 for ac_hdr in machine/param.h
2867 do
2868 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2869 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2870 echo "configure:2871: checking for $ac_hdr" >&5
2871 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2872   echo $ac_n "(cached) $ac_c" 1>&6
2873 else
2874   cat > conftest.$ac_ext <<EOF
2875 #line 2876 "configure"
2876 #include "confdefs.h"
2877 #include <$ac_hdr>
2878 EOF
2879 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2880 { (eval echo configure:2881: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2881 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2882 if test -z "$ac_err"; then
2883   rm -rf conftest*
2884   eval "ac_cv_header_$ac_safe=yes"
2885 else
2886   echo "$ac_err" >&5
2887   echo "configure: failed program was:" >&5
2888   cat conftest.$ac_ext >&5
2889   rm -rf conftest*
2890   eval "ac_cv_header_$ac_safe=no"
2891 fi
2892 rm -f conftest*
2893 fi
2894 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2895   echo "$ac_t""yes" 1>&6
2896     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2897   cat >> confdefs.h <<EOF
2898 #define $ac_tr_hdr 1
2899 EOF
2900  
2901 else
2902   echo "$ac_t""no" 1>&6
2903 fi
2904 done
2905
2906
2907 for ac_hdr in cthreads.h pthread.h kernel/scheduler.h kernel/OS.h
2908 do
2909 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2910 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2911 echo "configure:2912: checking for $ac_hdr" >&5
2912 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2913   echo $ac_n "(cached) $ac_c" 1>&6
2914 else
2915   cat > conftest.$ac_ext <<EOF
2916 #line 2917 "configure"
2917 #include "confdefs.h"
2918 #include <$ac_hdr>
2919 EOF
2920 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2921 { (eval echo configure:2922: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2922 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2923 if test -z "$ac_err"; then
2924   rm -rf conftest*
2925   eval "ac_cv_header_$ac_safe=yes"
2926 else
2927   echo "$ac_err" >&5
2928   echo "configure: failed program was:" >&5
2929   cat conftest.$ac_ext >&5
2930   rm -rf conftest*
2931   eval "ac_cv_header_$ac_safe=no"
2932 fi
2933 rm -f conftest*
2934 fi
2935 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2936   echo "$ac_t""yes" 1>&6
2937     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2938   cat >> confdefs.h <<EOF
2939 #define $ac_tr_hdr 1
2940 EOF
2941  
2942 else
2943   echo "$ac_t""no" 1>&6
2944 fi
2945 done
2946
2947
2948 save_CFLAGS=$CFLAGS
2949
2950 CFLAGS="${CFLAGS} -Wall -Werror"
2951 echo $ac_n "checking for ntohl in sys/param.h""... $ac_c" 1>&6
2952 echo "configure:2953: checking for ntohl in sys/param.h" >&5
2953 cat > conftest.$ac_ext <<EOF
2954 #line 2955 "configure"
2955 #include "confdefs.h"
2956 #include <sys/param.h>
2957 void foo() { int meuh; ntohl(meuh); }
2958 int main() {
2959
2960 ; return 0; }
2961 EOF
2962 if { (eval echo configure:2963: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2963   rm -rf conftest*
2964   cat >> confdefs.h <<\EOF
2965 #define NTOHL_IN_SYS_PARAM_H 1
2966 EOF
2967
2968  echo "$ac_t""yes" 1>&6
2969 else
2970   echo "configure: failed program was:" >&5
2971   cat conftest.$ac_ext >&5
2972   rm -rf conftest*
2973   echo "$ac_t""no" 1>&6
2974 fi
2975 rm -f conftest*
2976
2977 CFLAGS="${CFLAGS} -rdynamic"
2978 echo $ac_n "checking if \$CC accepts -rdynamic""... $ac_c" 1>&6
2979 echo "configure:2980: checking if \$CC accepts -rdynamic" >&5
2980 cat > conftest.$ac_ext <<EOF
2981 #line 2982 "configure"
2982 #include "confdefs.h"
2983
2984 int main() {
2985
2986 ; return 0; }
2987 EOF
2988 if { (eval echo configure:2989: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2989   rm -rf conftest*
2990   DYNAMIC_FLAG="-rdynamic"
2991  echo "$ac_t""yes" 1>&6
2992 else
2993   echo "configure: failed program was:" >&5
2994   cat conftest.$ac_ext >&5
2995   rm -rf conftest*
2996   echo "$ac_t""no" 1>&6
2997 fi
2998 rm -f conftest*
2999
3000 CFLAGS=$save_CFLAGS
3001
3002 echo $ac_n "checking for boolean_t in sys/types.h""... $ac_c" 1>&6
3003 echo "configure:3004: checking for boolean_t in sys/types.h" >&5
3004 cat > conftest.$ac_ext <<EOF
3005 #line 3006 "configure"
3006 #include "confdefs.h"
3007 #include <sys/types.h>
3008 void quux() { boolean_t foo; }
3009 int main() {
3010
3011 ; return 0; }
3012 EOF
3013 if { (eval echo configure:3014: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3014   rm -rf conftest*
3015   cat >> confdefs.h <<\EOF
3016 #define BOOLEAN_T_IN_SYS_TYPES_H 1
3017 EOF
3018
3019  echo "$ac_t""yes" 1>&6
3020 else
3021   echo "configure: failed program was:" >&5
3022   cat conftest.$ac_ext >&5
3023   rm -rf conftest*
3024   echo "$ac_t""no" 1>&6
3025 fi
3026 rm -f conftest*
3027
3028 echo $ac_n "checking for working const""... $ac_c" 1>&6
3029 echo "configure:3030: checking for working const" >&5
3030 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
3031   echo $ac_n "(cached) $ac_c" 1>&6
3032 else
3033   cat > conftest.$ac_ext <<EOF
3034 #line 3035 "configure"
3035 #include "confdefs.h"
3036
3037 int main() {
3038
3039 /* Ultrix mips cc rejects this.  */
3040 typedef int charset[2]; const charset x = {0,0};
3041 /* SunOS 4.1.1 cc rejects this.  */
3042 char const *const *ccp;
3043 char **p;
3044 /* NEC SVR4.0.2 mips cc rejects this.  */
3045 struct point {int x, y;};
3046 static struct point const zero = {0,0};
3047 /* AIX XL C 1.02.0.0 rejects this.
3048    It does not let you subtract one const X* pointer from another in an arm
3049    of an if-expression whose if-part is not a constant expression */
3050 const char *g = "string";
3051 ccp = &g + (g ? g-g : 0);
3052 /* HPUX 7.0 cc rejects these. */
3053 ++ccp;
3054 p = (char**) ccp;
3055 ccp = (char const *const *) p;
3056 { /* SCO 3.2v4 cc rejects this.  */
3057   char *t;
3058   char const *s = 0 ? (char *) 0 : (char const *) 0;
3059
3060   *t++ = 0;
3061 }
3062 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
3063   int x[] = {25, 17};
3064   const int *foo = &x[0];
3065   ++foo;
3066 }
3067 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
3068   typedef const int *iptr;
3069   iptr p = 0;
3070   ++p;
3071 }
3072 { /* AIX XL C 1.02.0.0 rejects this saying
3073      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
3074   struct s { int j; const int *ap[3]; };
3075   struct s *b; b->j = 5;
3076 }
3077 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
3078   const int foo = 10;
3079 }
3080
3081 ; return 0; }
3082 EOF
3083 if { (eval echo configure:3084: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3084   rm -rf conftest*
3085   ac_cv_c_const=yes
3086 else
3087   echo "configure: failed program was:" >&5
3088   cat conftest.$ac_ext >&5
3089   rm -rf conftest*
3090   ac_cv_c_const=no
3091 fi
3092 rm -f conftest*
3093 fi
3094
3095 echo "$ac_t""$ac_cv_c_const" 1>&6
3096 if test $ac_cv_c_const = no; then
3097   cat >> confdefs.h <<\EOF
3098 #define const 
3099 EOF
3100
3101 fi
3102
3103 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
3104 echo "configure:3105: checking for ANSI C header files" >&5
3105 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
3106   echo $ac_n "(cached) $ac_c" 1>&6
3107 else
3108   cat > conftest.$ac_ext <<EOF
3109 #line 3110 "configure"
3110 #include "confdefs.h"
3111 #include <stdlib.h>
3112 #include <stdarg.h>
3113 #include <string.h>
3114 #include <float.h>
3115 EOF
3116 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3117 { (eval echo configure:3118: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3118 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3119 if test -z "$ac_err"; then
3120   rm -rf conftest*
3121   ac_cv_header_stdc=yes
3122 else
3123   echo "$ac_err" >&5
3124   echo "configure: failed program was:" >&5
3125   cat conftest.$ac_ext >&5
3126   rm -rf conftest*
3127   ac_cv_header_stdc=no
3128 fi
3129 rm -f conftest*
3130
3131 if test $ac_cv_header_stdc = yes; then
3132   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3133 cat > conftest.$ac_ext <<EOF
3134 #line 3135 "configure"
3135 #include "confdefs.h"
3136 #include <string.h>
3137 EOF
3138 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3139   egrep "memchr" >/dev/null 2>&1; then
3140   :
3141 else
3142   rm -rf conftest*
3143   ac_cv_header_stdc=no
3144 fi
3145 rm -f conftest*
3146
3147 fi
3148
3149 if test $ac_cv_header_stdc = yes; then
3150   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3151 cat > conftest.$ac_ext <<EOF
3152 #line 3153 "configure"
3153 #include "confdefs.h"
3154 #include <stdlib.h>
3155 EOF
3156 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3157   egrep "free" >/dev/null 2>&1; then
3158   :
3159 else
3160   rm -rf conftest*
3161   ac_cv_header_stdc=no
3162 fi
3163 rm -f conftest*
3164
3165 fi
3166
3167 if test $ac_cv_header_stdc = yes; then
3168   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3169 if test "$cross_compiling" = yes; then
3170   :
3171 else
3172   cat > conftest.$ac_ext <<EOF
3173 #line 3174 "configure"
3174 #include "confdefs.h"
3175 #include <ctype.h>
3176 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3177 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3178 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3179 int main () { int i; for (i = 0; i < 256; i++)
3180 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
3181 exit (0); }
3182
3183 EOF
3184 if { (eval echo configure:3185: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3185 then
3186   :
3187 else
3188   echo "configure: failed program was:" >&5
3189   cat conftest.$ac_ext >&5
3190   rm -fr conftest*
3191   ac_cv_header_stdc=no
3192 fi
3193 rm -fr conftest*
3194 fi
3195
3196 fi
3197 fi
3198
3199 echo "$ac_t""$ac_cv_header_stdc" 1>&6
3200 if test $ac_cv_header_stdc = yes; then
3201   cat >> confdefs.h <<\EOF
3202 #define STDC_HEADERS 1
3203 EOF
3204
3205 fi
3206
3207 echo $ac_n "checking for size_t""... $ac_c" 1>&6
3208 echo "configure:3209: checking for size_t" >&5
3209 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
3210   echo $ac_n "(cached) $ac_c" 1>&6
3211 else
3212   cat > conftest.$ac_ext <<EOF
3213 #line 3214 "configure"
3214 #include "confdefs.h"
3215 #include <sys/types.h>
3216 #if STDC_HEADERS
3217 #include <stdlib.h>
3218 #include <stddef.h>
3219 #endif
3220 EOF
3221 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3222   egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3223   rm -rf conftest*
3224   ac_cv_type_size_t=yes
3225 else
3226   rm -rf conftest*
3227   ac_cv_type_size_t=no
3228 fi
3229 rm -f conftest*
3230
3231 fi
3232 echo "$ac_t""$ac_cv_type_size_t" 1>&6
3233 if test $ac_cv_type_size_t = no; then
3234   cat >> confdefs.h <<\EOF
3235 #define size_t unsigned
3236 EOF
3237
3238 fi
3239
3240 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
3241 echo "configure:3242: checking whether time.h and sys/time.h may both be included" >&5
3242 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
3243   echo $ac_n "(cached) $ac_c" 1>&6
3244 else
3245   cat > conftest.$ac_ext <<EOF
3246 #line 3247 "configure"
3247 #include "confdefs.h"
3248 #include <sys/types.h>
3249 #include <sys/time.h>
3250 #include <time.h>
3251 int main() {
3252 struct tm *tp;
3253 ; return 0; }
3254 EOF
3255 if { (eval echo configure:3256: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3256   rm -rf conftest*
3257   ac_cv_header_time=yes
3258 else
3259   echo "configure: failed program was:" >&5
3260   cat conftest.$ac_ext >&5
3261   rm -rf conftest*
3262   ac_cv_header_time=no
3263 fi
3264 rm -f conftest*
3265 fi
3266
3267 echo "$ac_t""$ac_cv_header_time" 1>&6
3268 if test $ac_cv_header_time = yes; then
3269   cat >> confdefs.h <<\EOF
3270 #define TIME_WITH_SYS_TIME 1
3271 EOF
3272
3273 fi
3274
3275
3276 for ac_hdr in sys/ioctl.h
3277 do
3278 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3279 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3280 echo "configure:3281: checking for $ac_hdr" >&5
3281 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3282   echo $ac_n "(cached) $ac_c" 1>&6
3283 else
3284   cat > conftest.$ac_ext <<EOF
3285 #line 3286 "configure"
3286 #include "confdefs.h"
3287 #include <$ac_hdr>
3288 EOF
3289 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3290 { (eval echo configure:3291: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3291 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3292 if test -z "$ac_err"; then
3293   rm -rf conftest*
3294   eval "ac_cv_header_$ac_safe=yes"
3295 else
3296   echo "$ac_err" >&5
3297   echo "configure: failed program was:" >&5
3298   cat conftest.$ac_ext >&5
3299   rm -rf conftest*
3300   eval "ac_cv_header_$ac_safe=no"
3301 fi
3302 rm -f conftest*
3303 fi
3304 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3305   echo "$ac_t""yes" 1>&6
3306     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3307   cat >> confdefs.h <<EOF
3308 #define $ac_tr_hdr 1
3309 EOF
3310  for ac_hdr in linux/cdrom.h
3311 do
3312 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3313 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3314 echo "configure:3315: checking for $ac_hdr" >&5
3315 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3316   echo $ac_n "(cached) $ac_c" 1>&6
3317 else
3318   cat > conftest.$ac_ext <<EOF
3319 #line 3320 "configure"
3320 #include "confdefs.h"
3321 #include <$ac_hdr>
3322 EOF
3323 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3324 { (eval echo configure:3325: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3325 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3326 if test -z "$ac_err"; then
3327   rm -rf conftest*
3328   eval "ac_cv_header_$ac_safe=yes"
3329 else
3330   echo "$ac_err" >&5
3331   echo "configure: failed program was:" >&5
3332   cat conftest.$ac_ext >&5
3333   rm -rf conftest*
3334   eval "ac_cv_header_$ac_safe=no"
3335 fi
3336 rm -f conftest*
3337 fi
3338 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3339   echo "$ac_t""yes" 1>&6
3340     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3341   cat >> confdefs.h <<EOF
3342 #define $ac_tr_hdr 1
3343 EOF
3344  
3345 else
3346   echo "$ac_t""no" 1>&6
3347 fi
3348 done
3349
3350    cat > conftest.$ac_ext <<EOF
3351 #line 3352 "configure"
3352 #include "confdefs.h"
3353 #include <linux/cdrom.h>
3354 EOF
3355 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3356   egrep "dvd" >/dev/null 2>&1; then
3357   rm -rf conftest*
3358   cat >> confdefs.h <<\EOF
3359 #define LINUX_DVD 1
3360 EOF
3361
3362 fi
3363 rm -f conftest*
3364
3365 else
3366   echo "$ac_t""no" 1>&6
3367 fi
3368 done
3369
3370
3371 PLUGINS=${PLUGINS}"ps ts dvd yuv idct idctclassic motion ";
3372
3373 ARCH=${host_cpu}
3374 # Check whether --enable-ppro or --disable-ppro was given.
3375 if test "${enable_ppro+set}" = set; then
3376   enableval="$enable_ppro"
3377    if test x$enableval = xyes; then ARCH=${ARCH}" ppro"; fi 
3378 else
3379    if test x${host_cpu} = xi686; then ARCH=${ARCH}" ppro"; fi 
3380 fi
3381
3382 # Check whether --enable-mmx or --disable-mmx was given.
3383 if test "${enable_mmx+set}" = set; then
3384   enableval="$enable_mmx"
3385    if test x$enableval = xyes; then ARCH=${ARCH}" mmx"; PLUGINS=${PLUGINS}"yuvmmx motionmmx motionmmxext idctmmx idctmmxext "; fi 
3386 else
3387    if test x${host_cpu} = xi686 -o x${host_cpu} = xi586; then ARCH=${ARCH}" mmx"; PLUGINS=${PLUGINS}"yuvmmx motionmmx motionmmxext idctmmx idctmmxext "; fi 
3388 fi
3389
3390 # Check whether --enable-debug or --disable-debug was given.
3391 if test "${enable_debug+set}" = set; then
3392   enableval="$enable_debug"
3393    if test x$enableval = xyes; then DEBUG=1; fi 
3394 fi
3395
3396 # Check whether --enable-stats or --disable-stats was given.
3397 if test "${enable_stats+set}" = set; then
3398   enableval="$enable_stats"
3399    if test x$enableval = xyes; then STATS=1; fi 
3400 fi
3401
3402 # Check whether --enable-optimizations or --disable-optimizations was given.
3403 if test "${enable_optimizations+set}" = set; then
3404   enableval="$enable_optimizations"
3405    if test x$enableval = xno; then OPTIMS=0; fi 
3406 else
3407    OPTIMS=1 
3408 fi
3409
3410
3411 SYS=${host_os}
3412
3413 # special cases
3414 if test x$host_os = xbeos; then
3415     PLUGINS=${PLUGINS}"dummy null beos "
3416
3417 else
3418
3419 # Check whether --enable-dummy or --disable-dummy was given.
3420 if test "${enable_dummy+set}" = set; then
3421   enableval="$enable_dummy"
3422   :
3423 fi
3424
3425 if test x$enable_dummy != xno; then PLUGINS=${PLUGINS}"dummy "; fi
3426 # Check whether --enable-null or --disable-null was given.
3427 if test "${enable_null+set}" = set; then
3428   enableval="$enable_null"
3429   :
3430 fi
3431
3432 if test x$enable_null != xno; then PLUGINS=${PLUGINS}"null "; fi
3433 # Check whether --enable-dsp or --disable-dsp was given.
3434 if test "${enable_dsp+set}" = set; then
3435   enableval="$enable_dsp"
3436   :
3437 fi
3438
3439 if test x$enable_dsp != xno; then PLUGINS=${PLUGINS}"dsp "; fi
3440 # Check whether --enable-esd or --disable-esd was given.
3441 if test "${enable_esd+set}" = set; then
3442   enableval="$enable_esd"
3443   if test x$enable_esd = xyes; then PLUGINS=${PLUGINS}"esd "; fi
3444 fi
3445
3446 # Check whether --enable-fb or --disable-fb was given.
3447 if test "${enable_fb+set}" = set; then
3448   enableval="$enable_fb"
3449   if test x$enable_fb = xyes; then PLUGINS=${PLUGINS}"fb "; ALIASES=${ALIASES}"fbvlc "; fi
3450 fi
3451
3452 # Check whether --with-ggi or --without-ggi was given.
3453 if test "${with_ggi+set}" = set; then
3454   withval="$with_ggi"
3455    PLUGINS=${PLUGINS}"ggi ";
3456     if test "x$withval" != "xyes";
3457     then
3458       LIB_GGI="-l"$withval
3459     else
3460       LIB_GGI="-lggi"
3461     fi 
3462 fi
3463
3464 # Check whether --with-sdl or --without-sdl was given.
3465 if test "${with_sdl+set}" = set; then
3466   withval="$with_sdl"
3467    PLUGINS=${PLUGINS}"sdl ";
3468     if test "x$withval" != "xyes";
3469     then
3470       LIB_SDL="-l"$withval
3471     else
3472       LIB_SDL="-lSDL"
3473     fi 
3474 fi
3475
3476     if test "x$withval" == "x";
3477     then
3478       PLUGINS=${PLUGINS}"sdl "
3479       LIB_SDL="-lSDL"
3480     fi
3481 # Check whether --with-glide or --without-glide was given.
3482 if test "${with_glide+set}" = set; then
3483   withval="$with_glide"
3484    PLUGINS=${PLUGINS}"glide ";
3485     if test "x$withval" != "xyes";
3486     then
3487       LIB_GLIDE="-l"$withval
3488     else
3489       LIB_GLIDE="-lglide2x"
3490     fi 
3491 fi
3492
3493 # Check whether --enable-gnome or --disable-gnome was given.
3494 if test "${enable_gnome+set}" = set; then
3495   enableval="$enable_gnome"
3496   :
3497 fi
3498
3499 if test x$enable_gnome != xno; then PLUGINS=${PLUGINS}"gnome "; ALIASES=${ALIASES}"gvlc "; fi
3500 # Check whether --enable-x11 or --disable-x11 was given.
3501 if test "${enable_x11+set}" = set; then
3502   enableval="$enable_x11"
3503   if test x$enable_x11 = xyes; then PLUGINS=${PLUGINS}"x11 "; fi
3504 fi
3505
3506
3507 # Check whether --enable-alsa or --disable-alsa was given.
3508 if test "${enable_alsa+set}" = set; then
3509   enableval="$enable_alsa"
3510   if test x$enable_alsa = xyes; then ac_safe=`echo "sys/asoundlib.h" | sed 'y%./+-%__p_%'`
3511 echo $ac_n "checking for sys/asoundlib.h""... $ac_c" 1>&6
3512 echo "configure:3513: checking for sys/asoundlib.h" >&5
3513 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3514   echo $ac_n "(cached) $ac_c" 1>&6
3515 else
3516   cat > conftest.$ac_ext <<EOF
3517 #line 3518 "configure"
3518 #include "confdefs.h"
3519 #include <sys/asoundlib.h>
3520 EOF
3521 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3522 { (eval echo configure:3523: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3523 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3524 if test -z "$ac_err"; then
3525   rm -rf conftest*
3526   eval "ac_cv_header_$ac_safe=yes"
3527 else
3528   echo "$ac_err" >&5
3529   echo "configure: failed program was:" >&5
3530   cat conftest.$ac_ext >&5
3531   rm -rf conftest*
3532   eval "ac_cv_header_$ac_safe=no"
3533 fi
3534 rm -f conftest*
3535 fi
3536 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3537   echo "$ac_t""yes" 1>&6
3538   echo $ac_n "checking for main in -lasound""... $ac_c" 1>&6
3539 echo "configure:3540: checking for main in -lasound" >&5
3540 ac_lib_var=`echo asound'_'main | sed 'y%./+-%__p_%'`
3541 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3542   echo $ac_n "(cached) $ac_c" 1>&6
3543 else
3544   ac_save_LIBS="$LIBS"
3545 LIBS="-lasound  $LIBS"
3546 cat > conftest.$ac_ext <<EOF
3547 #line 3548 "configure"
3548 #include "confdefs.h"
3549
3550 int main() {
3551 main()
3552 ; return 0; }
3553 EOF
3554 if { (eval echo configure:3555: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3555   rm -rf conftest*
3556   eval "ac_cv_lib_$ac_lib_var=yes"
3557 else
3558   echo "configure: failed program was:" >&5
3559   cat conftest.$ac_ext >&5
3560   rm -rf conftest*
3561   eval "ac_cv_lib_$ac_lib_var=no"
3562 fi
3563 rm -f conftest*
3564 LIBS="$ac_save_LIBS"
3565
3566 fi
3567 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3568   echo "$ac_t""yes" 1>&6
3569   have_alsa="true"
3570 else
3571   echo "$ac_t""no" 1>&6
3572 have_alsa="false"
3573 fi
3574
3575 else
3576   echo "$ac_t""no" 1>&6
3577 have_alsa="false"
3578 fi
3579  if test $have_alsa = true; then PLUGINS=${PLUGINS}"alsa "; fi; fi
3580 fi
3581
3582 fi
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595
3596 trap '' 1 2 15
3597 cat > confcache <<\EOF
3598 # This file is a shell script that caches the results of configure
3599 # tests run on this system so they can be shared between configure
3600 # scripts and configure runs.  It is not useful on other systems.
3601 # If it contains results you don't want to keep, you may remove or edit it.
3602 #
3603 # By default, configure uses ./config.cache as the cache file,
3604 # creating it if it does not exist already.  You can give configure
3605 # the --cache-file=FILE option to use a different cache file; that is
3606 # what configure does when it calls configure scripts in
3607 # subdirectories, so they share the cache.
3608 # Giving --cache-file=/dev/null disables caching, for debugging configure.
3609 # config.status only pays attention to the cache file if you give it the
3610 # --recheck option to rerun configure.
3611 #
3612 EOF
3613 # The following way of writing the cache mishandles newlines in values,
3614 # but we know of no workaround that is simple, portable, and efficient.
3615 # So, don't put newlines in cache variables' values.
3616 # Ultrix sh set writes to stderr and can't be redirected directly,
3617 # and sets the high bit in the cache file unless we assign to the vars.
3618 (set) 2>&1 |
3619   case `(ac_space=' '; set | grep ac_space) 2>&1` in
3620   *ac_space=\ *)
3621     # `set' does not quote correctly, so add quotes (double-quote substitution
3622     # turns \\\\ into \\, and sed turns \\ into \).
3623     sed -n \
3624       -e "s/'/'\\\\''/g" \
3625       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
3626     ;;
3627   *)
3628     # `set' quotes correctly as required by POSIX, so do not add quotes.
3629     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
3630     ;;
3631   esac >> confcache
3632 if cmp -s $cache_file confcache; then
3633   :
3634 else
3635   if test -w $cache_file; then
3636     echo "updating cache $cache_file"
3637     cat confcache > $cache_file
3638   else
3639     echo "not updating unwritable cache $cache_file"
3640   fi
3641 fi
3642 rm -f confcache
3643
3644 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
3645
3646 test "x$prefix" = xNONE && prefix=$ac_default_prefix
3647 # Let make expand exec_prefix.
3648 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
3649
3650 # Any assignment to VPATH causes Sun make to only execute
3651 # the first set of double-colon rules, so remove it if not needed.
3652 # If there is a colon in the path, we need to keep it.
3653 if test "x$srcdir" = x.; then
3654   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
3655 fi
3656
3657 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
3658
3659 DEFS=-DHAVE_CONFIG_H
3660
3661 # Without the "./", some shells look in PATH for config.status.
3662 : ${CONFIG_STATUS=./config.status}
3663
3664 echo creating $CONFIG_STATUS
3665 rm -f $CONFIG_STATUS
3666 cat > $CONFIG_STATUS <<EOF
3667 #! /bin/sh
3668 # Generated automatically by configure.
3669 # Run this file to recreate the current configuration.
3670 # This directory was configured as follows,
3671 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3672 #
3673 # $0 $ac_configure_args
3674 #
3675 # Compiler output produced by configure, useful for debugging
3676 # configure, is in ./config.log if it exists.
3677
3678 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
3679 for ac_option
3680 do
3681   case "\$ac_option" in
3682   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
3683     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
3684     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
3685   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
3686     echo "$CONFIG_STATUS generated by autoconf version 2.13"
3687     exit 0 ;;
3688   -help | --help | --hel | --he | --h)
3689     echo "\$ac_cs_usage"; exit 0 ;;
3690   *) echo "\$ac_cs_usage"; exit 1 ;;
3691   esac
3692 done
3693
3694 ac_given_srcdir=$srcdir
3695 ac_given_INSTALL="$INSTALL"
3696
3697 trap 'rm -fr `echo "Makefile include/config.h include/defs.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
3698 EOF
3699 cat >> $CONFIG_STATUS <<EOF
3700
3701 # Protect against being on the right side of a sed subst in config.status.
3702 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
3703  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
3704 $ac_vpsub
3705 $extrasub
3706 s%@SHELL@%$SHELL%g
3707 s%@CFLAGS@%$CFLAGS%g
3708 s%@CPPFLAGS@%$CPPFLAGS%g
3709 s%@CXXFLAGS@%$CXXFLAGS%g
3710 s%@FFLAGS@%$FFLAGS%g
3711 s%@DEFS@%$DEFS%g
3712 s%@LDFLAGS@%$LDFLAGS%g
3713 s%@LIBS@%$LIBS%g
3714 s%@exec_prefix@%$exec_prefix%g
3715 s%@prefix@%$prefix%g
3716 s%@program_transform_name@%$program_transform_name%g
3717 s%@bindir@%$bindir%g
3718 s%@sbindir@%$sbindir%g
3719 s%@libexecdir@%$libexecdir%g
3720 s%@datadir@%$datadir%g
3721 s%@sysconfdir@%$sysconfdir%g
3722 s%@sharedstatedir@%$sharedstatedir%g
3723 s%@localstatedir@%$localstatedir%g
3724 s%@libdir@%$libdir%g
3725 s%@includedir@%$includedir%g
3726 s%@oldincludedir@%$oldincludedir%g
3727 s%@infodir@%$infodir%g
3728 s%@mandir@%$mandir%g
3729 s%@host@%$host%g
3730 s%@host_alias@%$host_alias%g
3731 s%@host_cpu@%$host_cpu%g
3732 s%@host_vendor@%$host_vendor%g
3733 s%@host_os@%$host_os%g
3734 s%@VLC_VERSION@%$VLC_VERSION%g
3735 s%@VLC_CODENAME@%$VLC_CODENAME%g
3736 s%@SET_MAKE@%$SET_MAKE%g
3737 s%@CC@%$CC%g
3738 s%@CPP@%$CPP%g
3739 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
3740 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
3741 s%@INSTALL_DATA@%$INSTALL_DATA%g
3742 s%@LIBOBJS@%$LIBOBJS%g
3743 s%@SYS@%$SYS%g
3744 s%@ARCH@%$ARCH%g
3745 s%@PLUGINS@%$PLUGINS%g
3746 s%@ALIASES@%$ALIASES%g
3747 s%@DEBUG@%$DEBUG%g
3748 s%@STATS@%$STATS%g
3749 s%@OPTIMS@%$OPTIMS%g
3750 s%@DYNAMIC_FLAG@%$DYNAMIC_FLAG%g
3751 s%@LIB_SDL@%$LIB_SDL%g
3752 s%@LIB_GLIDE@%$LIB_GLIDE%g
3753 s%@LIB_GGI@%$LIB_GGI%g
3754
3755 CEOF
3756 EOF
3757
3758 cat >> $CONFIG_STATUS <<\EOF
3759
3760 # Split the substitutions into bite-sized pieces for seds with
3761 # small command number limits, like on Digital OSF/1 and HP-UX.
3762 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
3763 ac_file=1 # Number of current file.
3764 ac_beg=1 # First line for current file.
3765 ac_end=$ac_max_sed_cmds # Line after last line for current file.
3766 ac_more_lines=:
3767 ac_sed_cmds=""
3768 while $ac_more_lines; do
3769   if test $ac_beg -gt 1; then
3770     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
3771   else
3772     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
3773   fi
3774   if test ! -s conftest.s$ac_file; then
3775     ac_more_lines=false
3776     rm -f conftest.s$ac_file
3777   else
3778     if test -z "$ac_sed_cmds"; then
3779       ac_sed_cmds="sed -f conftest.s$ac_file"
3780     else
3781       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
3782     fi
3783     ac_file=`expr $ac_file + 1`
3784     ac_beg=$ac_end
3785     ac_end=`expr $ac_end + $ac_max_sed_cmds`
3786   fi
3787 done
3788 if test -z "$ac_sed_cmds"; then
3789   ac_sed_cmds=cat
3790 fi
3791 EOF
3792
3793 cat >> $CONFIG_STATUS <<EOF
3794
3795 CONFIG_FILES=\${CONFIG_FILES-"Makefile include/config.h"}
3796 EOF
3797 cat >> $CONFIG_STATUS <<\EOF
3798 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
3799   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3800   case "$ac_file" in
3801   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3802        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3803   *) ac_file_in="${ac_file}.in" ;;
3804   esac
3805
3806   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
3807
3808   # Remove last slash and all that follows it.  Not all systems have dirname.
3809   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3810   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3811     # The file is in a subdirectory.
3812     test ! -d "$ac_dir" && mkdir "$ac_dir"
3813     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
3814     # A "../" for each directory in $ac_dir_suffix.
3815     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
3816   else
3817     ac_dir_suffix= ac_dots=
3818   fi
3819
3820   case "$ac_given_srcdir" in
3821   .)  srcdir=.
3822       if test -z "$ac_dots"; then top_srcdir=.
3823       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
3824   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
3825   *) # Relative path.
3826     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
3827     top_srcdir="$ac_dots$ac_given_srcdir" ;;
3828   esac
3829
3830   case "$ac_given_INSTALL" in
3831   [/$]*) INSTALL="$ac_given_INSTALL" ;;
3832   *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
3833   esac
3834
3835   echo creating "$ac_file"
3836   rm -f "$ac_file"
3837   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
3838   case "$ac_file" in
3839   *Makefile*) ac_comsub="1i\\
3840 # $configure_input" ;;
3841   *) ac_comsub= ;;
3842   esac
3843
3844   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3845   sed -e "$ac_comsub
3846 s%@configure_input@%$configure_input%g
3847 s%@srcdir@%$srcdir%g
3848 s%@top_srcdir@%$top_srcdir%g
3849 s%@INSTALL@%$INSTALL%g
3850 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
3851 fi; done
3852 rm -f conftest.s*
3853
3854 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
3855 # NAME is the cpp macro being defined and VALUE is the value it is being given.
3856 #
3857 # ac_d sets the value in "#define NAME VALUE" lines.
3858 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
3859 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
3860 ac_dC='\3'
3861 ac_dD='%g'
3862 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
3863 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3864 ac_uB='\([      ]\)%\1#\2define\3'
3865 ac_uC=' '
3866 ac_uD='\4%g'
3867 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
3868 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3869 ac_eB='$%\1#\2define\3'
3870 ac_eC=' '
3871 ac_eD='%g'
3872
3873 if test "${CONFIG_HEADERS+set}" != set; then
3874 EOF
3875 cat >> $CONFIG_STATUS <<EOF
3876   CONFIG_HEADERS="include/defs.h"
3877 EOF
3878 cat >> $CONFIG_STATUS <<\EOF
3879 fi
3880 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
3881   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3882   case "$ac_file" in
3883   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3884        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3885   *) ac_file_in="${ac_file}.in" ;;
3886   esac
3887
3888   echo creating $ac_file
3889
3890   rm -f conftest.frag conftest.in conftest.out
3891   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3892   cat $ac_file_inputs > conftest.in
3893
3894 EOF
3895
3896 # Transform confdefs.h into a sed script conftest.vals that substitutes
3897 # the proper values into config.h.in to produce config.h.  And first:
3898 # Protect against being on the right side of a sed subst in config.status.
3899 # Protect against being in an unquoted here document in config.status.
3900 rm -f conftest.vals
3901 cat > conftest.hdr <<\EOF
3902 s/[\\&%]/\\&/g
3903 s%[\\$`]%\\&%g
3904 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
3905 s%ac_d%ac_u%gp
3906 s%ac_u%ac_e%gp
3907 EOF
3908 sed -n -f conftest.hdr confdefs.h > conftest.vals
3909 rm -f conftest.hdr
3910
3911 # This sed command replaces #undef with comments.  This is necessary, for
3912 # example, in the case of _POSIX_SOURCE, which is predefined and required
3913 # on some systems where configure will not decide to define it.
3914 cat >> conftest.vals <<\EOF
3915 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
3916 EOF
3917
3918 # Break up conftest.vals because some shells have a limit on
3919 # the size of here documents, and old seds have small limits too.
3920
3921 rm -f conftest.tail
3922 while :
3923 do
3924   ac_lines=`grep -c . conftest.vals`
3925   # grep -c gives empty output for an empty file on some AIX systems.
3926   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
3927   # Write a limited-size here document to conftest.frag.
3928   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
3929   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
3930   echo 'CEOF
3931   sed -f conftest.frag conftest.in > conftest.out
3932   rm -f conftest.in
3933   mv conftest.out conftest.in
3934 ' >> $CONFIG_STATUS
3935   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
3936   rm -f conftest.vals
3937   mv conftest.tail conftest.vals
3938 done
3939 rm -f conftest.vals
3940
3941 cat >> $CONFIG_STATUS <<\EOF
3942   rm -f conftest.frag conftest.h
3943   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
3944   cat conftest.in >> conftest.h
3945   rm -f conftest.in
3946   if cmp -s $ac_file conftest.h 2>/dev/null; then
3947     echo "$ac_file is unchanged"
3948     rm -f conftest.h
3949   else
3950     # Remove last slash and all that follows it.  Not all systems have dirname.
3951       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3952       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3953       # The file is in a subdirectory.
3954       test ! -d "$ac_dir" && mkdir "$ac_dir"
3955     fi
3956     rm -f $ac_file
3957     mv conftest.h $ac_file
3958   fi
3959 fi; done
3960
3961 EOF
3962 cat >> $CONFIG_STATUS <<EOF
3963
3964 EOF
3965 cat >> $CONFIG_STATUS <<\EOF
3966
3967 exit 0
3968 EOF
3969 chmod +x $CONFIG_STATUS
3970 rm -fr confdefs* $ac_clean_files
3971 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
3972
3973
3974 echo "
3975 vlc configuration
3976 -----------------
3977 vlc version           : ${VLC_VERSION}
3978 system                : ${SYS}
3979 architecture          : ${ARCH}
3980 debug mode            : ${DEBUG}
3981 statistics            : ${STATS}
3982 optimizations         : ${OPTIMS}
3983 plugins               : ${PLUGINS}
3984 vlc aliases           : ${ALIASES}
3985 "
3986