]> git.sesse.net Git - vlc/blob - configure
* X11 output works again. It's just the output, but it works; I now need
[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   --disable-x11           X11 support (default enabled)"
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.60
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;
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
1979 /* This mess was copied from the GNU getpagesize.h.  */
1980 #ifndef HAVE_GETPAGESIZE
1981 # ifdef HAVE_UNISTD_H
1982 #  include <unistd.h>
1983 # endif
1984
1985 /* Assume that all systems that can run configure have sys/param.h.  */
1986 # ifndef HAVE_SYS_PARAM_H
1987 #  define HAVE_SYS_PARAM_H 1
1988 # endif
1989
1990 # ifdef _SC_PAGESIZE
1991 #  define getpagesize() sysconf(_SC_PAGESIZE)
1992 # else /* no _SC_PAGESIZE */
1993 #  ifdef HAVE_SYS_PARAM_H
1994 #   include <sys/param.h>
1995 #   ifdef EXEC_PAGESIZE
1996 #    define getpagesize() EXEC_PAGESIZE
1997 #   else /* no EXEC_PAGESIZE */
1998 #    ifdef NBPG
1999 #     define getpagesize() NBPG * CLSIZE
2000 #     ifndef CLSIZE
2001 #      define CLSIZE 1
2002 #     endif /* no CLSIZE */
2003 #    else /* no NBPG */
2004 #     ifdef NBPC
2005 #      define getpagesize() NBPC
2006 #     else /* no NBPC */
2007 #      ifdef PAGESIZE
2008 #       define getpagesize() PAGESIZE
2009 #      endif /* PAGESIZE */
2010 #     endif /* no NBPC */
2011 #    endif /* no NBPG */
2012 #   endif /* no EXEC_PAGESIZE */
2013 #  else /* no HAVE_SYS_PARAM_H */
2014 #   define getpagesize() 8192   /* punt totally */
2015 #  endif /* no HAVE_SYS_PARAM_H */
2016 # endif /* no _SC_PAGESIZE */
2017
2018 #endif /* no HAVE_GETPAGESIZE */
2019
2020 #ifdef __cplusplus
2021 extern "C" { void *malloc(unsigned); }
2022 #else
2023 char *malloc();
2024 #endif
2025
2026 int
2027 main()
2028 {
2029         char *data, *data2, *data3;
2030         int i, pagesize;
2031         int fd;
2032
2033         pagesize = getpagesize();
2034
2035         /*
2036          * First, make a file with some known garbage in it.
2037          */
2038         data = malloc(pagesize);
2039         if (!data)
2040                 exit(1);
2041         for (i = 0; i < pagesize; ++i)
2042                 *(data + i) = rand();
2043         umask(0);
2044         fd = creat("conftestmmap", 0600);
2045         if (fd < 0)
2046                 exit(1);
2047         if (write(fd, data, pagesize) != pagesize)
2048                 exit(1);
2049         close(fd);
2050
2051         /*
2052          * Next, try to mmap the file at a fixed address which
2053          * already has something else allocated at it.  If we can,
2054          * also make sure that we see the same garbage.
2055          */
2056         fd = open("conftestmmap", O_RDWR);
2057         if (fd < 0)
2058                 exit(1);
2059         data2 = malloc(2 * pagesize);
2060         if (!data2)
2061                 exit(1);
2062         data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
2063         if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
2064             MAP_PRIVATE | MAP_FIXED, fd, 0L))
2065                 exit(1);
2066         for (i = 0; i < pagesize; ++i)
2067                 if (*(data + i) != *(data2 + i))
2068                         exit(1);
2069
2070         /*
2071          * Finally, make sure that changes to the mapped area
2072          * do not percolate back to the file as seen by read().
2073          * (This is a bug on some variants of i386 svr4.0.)
2074          */
2075         for (i = 0; i < pagesize; ++i)
2076                 *(data2 + i) = *(data2 + i) + 1;
2077         data3 = malloc(pagesize);
2078         if (!data3)
2079                 exit(1);
2080         if (read(fd, data3, pagesize) != pagesize)
2081                 exit(1);
2082         for (i = 0; i < pagesize; ++i)
2083                 if (*(data + i) != *(data3 + i))
2084                         exit(1);
2085         close(fd);
2086         unlink("conftestmmap");
2087         exit(0);
2088 }
2089
2090 EOF
2091 if { (eval echo configure:2092: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2092 then
2093   ac_cv_func_mmap_fixed_mapped=yes
2094 else
2095   echo "configure: failed program was:" >&5
2096   cat conftest.$ac_ext >&5
2097   rm -fr conftest*
2098   ac_cv_func_mmap_fixed_mapped=no
2099 fi
2100 rm -fr conftest*
2101 fi
2102
2103 fi
2104
2105 echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
2106 if test $ac_cv_func_mmap_fixed_mapped = yes; then
2107   cat >> confdefs.h <<\EOF
2108 #define HAVE_MMAP 1
2109 EOF
2110
2111 fi
2112
2113 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
2114 echo "configure:2115: checking return type of signal handlers" >&5
2115 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
2116   echo $ac_n "(cached) $ac_c" 1>&6
2117 else
2118   cat > conftest.$ac_ext <<EOF
2119 #line 2120 "configure"
2120 #include "confdefs.h"
2121 #include <sys/types.h>
2122 #include <signal.h>
2123 #ifdef signal
2124 #undef signal
2125 #endif
2126 #ifdef __cplusplus
2127 extern "C" void (*signal (int, void (*)(int)))(int);
2128 #else
2129 void (*signal ()) ();
2130 #endif
2131
2132 int main() {
2133 int i;
2134 ; return 0; }
2135 EOF
2136 if { (eval echo configure:2137: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2137   rm -rf conftest*
2138   ac_cv_type_signal=void
2139 else
2140   echo "configure: failed program was:" >&5
2141   cat conftest.$ac_ext >&5
2142   rm -rf conftest*
2143   ac_cv_type_signal=int
2144 fi
2145 rm -f conftest*
2146 fi
2147
2148 echo "$ac_t""$ac_cv_type_signal" 1>&6
2149 cat >> confdefs.h <<EOF
2150 #define RETSIGTYPE $ac_cv_type_signal
2151 EOF
2152
2153
2154 echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
2155 echo "configure:2156: checking for dlopen in -ldl" >&5
2156 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
2157 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2158   echo $ac_n "(cached) $ac_c" 1>&6
2159 else
2160   ac_save_LIBS="$LIBS"
2161 LIBS="-ldl  $LIBS"
2162 cat > conftest.$ac_ext <<EOF
2163 #line 2164 "configure"
2164 #include "confdefs.h"
2165 /* Override any gcc2 internal prototype to avoid an error.  */
2166 /* We use char because int might match the return type of a gcc2
2167     builtin and then its argument prototype would still apply.  */
2168 char dlopen();
2169
2170 int main() {
2171 dlopen()
2172 ; return 0; }
2173 EOF
2174 if { (eval echo configure:2175: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2175   rm -rf conftest*
2176   eval "ac_cv_lib_$ac_lib_var=yes"
2177 else
2178   echo "configure: failed program was:" >&5
2179   cat conftest.$ac_ext >&5
2180   rm -rf conftest*
2181   eval "ac_cv_lib_$ac_lib_var=no"
2182 fi
2183 rm -f conftest*
2184 LIBS="$ac_save_LIBS"
2185
2186 fi
2187 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2188   echo "$ac_t""yes" 1>&6
2189     ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2190     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2191   cat >> confdefs.h <<EOF
2192 #define $ac_tr_lib 1
2193 EOF
2194
2195   LIBS="-ldl $LIBS"
2196
2197 else
2198   echo "$ac_t""no" 1>&6
2199 fi
2200
2201 echo $ac_n "checking for optarg in -lgnugetopt""... $ac_c" 1>&6
2202 echo "configure:2203: checking for optarg in -lgnugetopt" >&5
2203 ac_lib_var=`echo gnugetopt'_'optarg | sed 'y%./+-%__p_%'`
2204 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2205   echo $ac_n "(cached) $ac_c" 1>&6
2206 else
2207   ac_save_LIBS="$LIBS"
2208 LIBS="-lgnugetopt  $LIBS"
2209 cat > conftest.$ac_ext <<EOF
2210 #line 2211 "configure"
2211 #include "confdefs.h"
2212 /* Override any gcc2 internal prototype to avoid an error.  */
2213 /* We use char because int might match the return type of a gcc2
2214     builtin and then its argument prototype would still apply.  */
2215 char optarg();
2216
2217 int main() {
2218 optarg()
2219 ; return 0; }
2220 EOF
2221 if { (eval echo configure:2222: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2222   rm -rf conftest*
2223   eval "ac_cv_lib_$ac_lib_var=yes"
2224 else
2225   echo "configure: failed program was:" >&5
2226   cat conftest.$ac_ext >&5
2227   rm -rf conftest*
2228   eval "ac_cv_lib_$ac_lib_var=no"
2229 fi
2230 rm -f conftest*
2231 LIBS="$ac_save_LIBS"
2232
2233 fi
2234 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2235   echo "$ac_t""yes" 1>&6
2236     ac_tr_lib=HAVE_LIB`echo gnugetopt | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2237     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2238   cat >> confdefs.h <<EOF
2239 #define $ac_tr_lib 1
2240 EOF
2241
2242   LIBS="-lgnugetopt $LIBS"
2243
2244 else
2245   echo "$ac_t""no" 1>&6
2246 fi
2247
2248 echo $ac_n "checking for _ in -lbe""... $ac_c" 1>&6
2249 echo "configure:2250: checking for _ in -lbe" >&5
2250 ac_lib_var=`echo be'_'_ | sed 'y%./+-%__p_%'`
2251 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2252   echo $ac_n "(cached) $ac_c" 1>&6
2253 else
2254   ac_save_LIBS="$LIBS"
2255 LIBS="-lbe  $LIBS"
2256 cat > conftest.$ac_ext <<EOF
2257 #line 2258 "configure"
2258 #include "confdefs.h"
2259 /* Override any gcc2 internal prototype to avoid an error.  */
2260 /* We use char because int might match the return type of a gcc2
2261     builtin and then its argument prototype would still apply.  */
2262 char _();
2263
2264 int main() {
2265 _()
2266 ; return 0; }
2267 EOF
2268 if { (eval echo configure:2269: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2269   rm -rf conftest*
2270   eval "ac_cv_lib_$ac_lib_var=yes"
2271 else
2272   echo "configure: failed program was:" >&5
2273   cat conftest.$ac_ext >&5
2274   rm -rf conftest*
2275   eval "ac_cv_lib_$ac_lib_var=no"
2276 fi
2277 rm -f conftest*
2278 LIBS="$ac_save_LIBS"
2279
2280 fi
2281 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2282   echo "$ac_t""yes" 1>&6
2283     ac_tr_lib=HAVE_LIB`echo be | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2284     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2285   cat >> confdefs.h <<EOF
2286 #define $ac_tr_lib 1
2287 EOF
2288
2289   LIBS="-lbe $LIBS"
2290
2291 else
2292   echo "$ac_t""no" 1>&6
2293 fi
2294
2295 echo $ac_n "checking for _ in -lgame""... $ac_c" 1>&6
2296 echo "configure:2297: checking for _ in -lgame" >&5
2297 ac_lib_var=`echo game'_'_ | sed 'y%./+-%__p_%'`
2298 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2299   echo $ac_n "(cached) $ac_c" 1>&6
2300 else
2301   ac_save_LIBS="$LIBS"
2302 LIBS="-lgame  $LIBS"
2303 cat > conftest.$ac_ext <<EOF
2304 #line 2305 "configure"
2305 #include "confdefs.h"
2306 /* Override any gcc2 internal prototype to avoid an error.  */
2307 /* We use char because int might match the return type of a gcc2
2308     builtin and then its argument prototype would still apply.  */
2309 char _();
2310
2311 int main() {
2312 _()
2313 ; return 0; }
2314 EOF
2315 if { (eval echo configure:2316: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2316   rm -rf conftest*
2317   eval "ac_cv_lib_$ac_lib_var=yes"
2318 else
2319   echo "configure: failed program was:" >&5
2320   cat conftest.$ac_ext >&5
2321   rm -rf conftest*
2322   eval "ac_cv_lib_$ac_lib_var=no"
2323 fi
2324 rm -f conftest*
2325 LIBS="$ac_save_LIBS"
2326
2327 fi
2328 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2329   echo "$ac_t""yes" 1>&6
2330     ac_tr_lib=HAVE_LIB`echo game | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2331     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2332   cat >> confdefs.h <<EOF
2333 #define $ac_tr_lib 1
2334 EOF
2335
2336   LIBS="-lgame $LIBS"
2337
2338 else
2339   echo "$ac_t""no" 1>&6
2340 fi
2341
2342 echo $ac_n "checking for _ in -lroot""... $ac_c" 1>&6
2343 echo "configure:2344: checking for _ in -lroot" >&5
2344 ac_lib_var=`echo root'_'_ | sed 'y%./+-%__p_%'`
2345 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2346   echo $ac_n "(cached) $ac_c" 1>&6
2347 else
2348   ac_save_LIBS="$LIBS"
2349 LIBS="-lroot  $LIBS"
2350 cat > conftest.$ac_ext <<EOF
2351 #line 2352 "configure"
2352 #include "confdefs.h"
2353 /* Override any gcc2 internal prototype to avoid an error.  */
2354 /* We use char because int might match the return type of a gcc2
2355     builtin and then its argument prototype would still apply.  */
2356 char _();
2357
2358 int main() {
2359 _()
2360 ; return 0; }
2361 EOF
2362 if { (eval echo configure:2363: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2363   rm -rf conftest*
2364   eval "ac_cv_lib_$ac_lib_var=yes"
2365 else
2366   echo "configure: failed program was:" >&5
2367   cat conftest.$ac_ext >&5
2368   rm -rf conftest*
2369   eval "ac_cv_lib_$ac_lib_var=no"
2370 fi
2371 rm -f conftest*
2372 LIBS="$ac_save_LIBS"
2373
2374 fi
2375 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2376   echo "$ac_t""yes" 1>&6
2377     ac_tr_lib=HAVE_LIB`echo root | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2378     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2379   cat >> confdefs.h <<EOF
2380 #define $ac_tr_lib 1
2381 EOF
2382
2383   LIBS="-lroot $LIBS"
2384
2385 else
2386   echo "$ac_t""no" 1>&6
2387 fi
2388
2389 echo $ac_n "checking for powl in -lm""... $ac_c" 1>&6
2390 echo "configure:2391: checking for powl in -lm" >&5
2391 ac_lib_var=`echo m'_'powl | sed 'y%./+-%__p_%'`
2392 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2393   echo $ac_n "(cached) $ac_c" 1>&6
2394 else
2395   ac_save_LIBS="$LIBS"
2396 LIBS="-lm  $LIBS"
2397 cat > conftest.$ac_ext <<EOF
2398 #line 2399 "configure"
2399 #include "confdefs.h"
2400 /* Override any gcc2 internal prototype to avoid an error.  */
2401 /* We use char because int might match the return type of a gcc2
2402     builtin and then its argument prototype would still apply.  */
2403 char powl();
2404
2405 int main() {
2406 powl()
2407 ; return 0; }
2408 EOF
2409 if { (eval echo configure:2410: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2410   rm -rf conftest*
2411   eval "ac_cv_lib_$ac_lib_var=yes"
2412 else
2413   echo "configure: failed program was:" >&5
2414   cat conftest.$ac_ext >&5
2415   rm -rf conftest*
2416   eval "ac_cv_lib_$ac_lib_var=no"
2417 fi
2418 rm -f conftest*
2419 LIBS="$ac_save_LIBS"
2420
2421 fi
2422 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2423   echo "$ac_t""yes" 1>&6
2424     ac_tr_lib=HAVE_LIB`echo m | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2425     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2426   cat >> confdefs.h <<EOF
2427 #define $ac_tr_lib 1
2428 EOF
2429
2430   LIBS="-lm $LIBS"
2431
2432 else
2433   echo "$ac_t""no" 1>&6
2434 fi
2435
2436 echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
2437 echo "configure:2438: checking for pthread_create in -lpthread" >&5
2438 ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'`
2439 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2440   echo $ac_n "(cached) $ac_c" 1>&6
2441 else
2442   ac_save_LIBS="$LIBS"
2443 LIBS="-lpthread  $LIBS"
2444 cat > conftest.$ac_ext <<EOF
2445 #line 2446 "configure"
2446 #include "confdefs.h"
2447 /* Override any gcc2 internal prototype to avoid an error.  */
2448 /* We use char because int might match the return type of a gcc2
2449     builtin and then its argument prototype would still apply.  */
2450 char pthread_create();
2451
2452 int main() {
2453 pthread_create()
2454 ; return 0; }
2455 EOF
2456 if { (eval echo configure:2457: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2457   rm -rf conftest*
2458   eval "ac_cv_lib_$ac_lib_var=yes"
2459 else
2460   echo "configure: failed program was:" >&5
2461   cat conftest.$ac_ext >&5
2462   rm -rf conftest*
2463   eval "ac_cv_lib_$ac_lib_var=no"
2464 fi
2465 rm -f conftest*
2466 LIBS="$ac_save_LIBS"
2467
2468 fi
2469 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2470   echo "$ac_t""yes" 1>&6
2471     ac_tr_lib=HAVE_LIB`echo pthread | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2472     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2473   cat >> confdefs.h <<EOF
2474 #define $ac_tr_lib 1
2475 EOF
2476
2477   LIBS="-lpthread $LIBS"
2478
2479 else
2480   echo "$ac_t""no" 1>&6
2481 fi
2482
2483 echo $ac_n "checking for thread_create in -lthreads""... $ac_c" 1>&6
2484 echo "configure:2485: checking for thread_create in -lthreads" >&5
2485 ac_lib_var=`echo threads'_'thread_create | sed 'y%./+-%__p_%'`
2486 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2487   echo $ac_n "(cached) $ac_c" 1>&6
2488 else
2489   ac_save_LIBS="$LIBS"
2490 LIBS="-lthreads  $LIBS"
2491 cat > conftest.$ac_ext <<EOF
2492 #line 2493 "configure"
2493 #include "confdefs.h"
2494 /* Override any gcc2 internal prototype to avoid an error.  */
2495 /* We use char because int might match the return type of a gcc2
2496     builtin and then its argument prototype would still apply.  */
2497 char thread_create();
2498
2499 int main() {
2500 thread_create()
2501 ; return 0; }
2502 EOF
2503 if { (eval echo configure:2504: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2504   rm -rf conftest*
2505   eval "ac_cv_lib_$ac_lib_var=yes"
2506 else
2507   echo "configure: failed program was:" >&5
2508   cat conftest.$ac_ext >&5
2509   rm -rf conftest*
2510   eval "ac_cv_lib_$ac_lib_var=no"
2511 fi
2512 rm -f conftest*
2513 LIBS="$ac_save_LIBS"
2514
2515 fi
2516 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2517   echo "$ac_t""yes" 1>&6
2518     ac_tr_lib=HAVE_LIB`echo threads | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2519     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2520   cat >> confdefs.h <<EOF
2521 #define $ac_tr_lib 1
2522 EOF
2523
2524   LIBS="-lthreads $LIBS"
2525
2526 else
2527   echo "$ac_t""no" 1>&6
2528 fi
2529
2530
2531 echo $ac_n "checking for getopt_long""... $ac_c" 1>&6
2532 echo "configure:2533: checking for getopt_long" >&5
2533 if eval "test \"`echo '$''{'ac_cv_func_getopt_long'+set}'`\" = set"; then
2534   echo $ac_n "(cached) $ac_c" 1>&6
2535 else
2536   cat > conftest.$ac_ext <<EOF
2537 #line 2538 "configure"
2538 #include "confdefs.h"
2539 /* System header to define __stub macros and hopefully few prototypes,
2540     which can conflict with char getopt_long(); below.  */
2541 #include <assert.h>
2542 /* Override any gcc2 internal prototype to avoid an error.  */
2543 /* We use char because int might match the return type of a gcc2
2544     builtin and then its argument prototype would still apply.  */
2545 char getopt_long();
2546
2547 int main() {
2548
2549 /* The GNU C library defines this for functions which it implements
2550     to always fail with ENOSYS.  Some functions are actually named
2551     something starting with __ and the normal name is an alias.  */
2552 #if defined (__stub_getopt_long) || defined (__stub___getopt_long)
2553 choke me
2554 #else
2555 getopt_long();
2556 #endif
2557
2558 ; return 0; }
2559 EOF
2560 if { (eval echo configure:2561: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2561   rm -rf conftest*
2562   eval "ac_cv_func_getopt_long=yes"
2563 else
2564   echo "configure: failed program was:" >&5
2565   cat conftest.$ac_ext >&5
2566   rm -rf conftest*
2567   eval "ac_cv_func_getopt_long=no"
2568 fi
2569 rm -f conftest*
2570 fi
2571
2572 if eval "test \"`echo '$ac_cv_func_'getopt_long`\" = yes"; then
2573   echo "$ac_t""yes" 1>&6
2574   :
2575 else
2576   echo "$ac_t""no" 1>&6
2577 LIBOBJS="$LIBOBJS getopt.o getopt1.o"
2578 fi
2579
2580
2581
2582 CPPFLAGS="${CPPFLAGS} -I/usr/local/include"
2583 for ac_hdr in stddef.h
2584 do
2585 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2586 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2587 echo "configure:2588: checking for $ac_hdr" >&5
2588 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2589   echo $ac_n "(cached) $ac_c" 1>&6
2590 else
2591   cat > conftest.$ac_ext <<EOF
2592 #line 2593 "configure"
2593 #include "confdefs.h"
2594 #include <$ac_hdr>
2595 EOF
2596 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2597 { (eval echo configure:2598: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2598 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2599 if test -z "$ac_err"; then
2600   rm -rf conftest*
2601   eval "ac_cv_header_$ac_safe=yes"
2602 else
2603   echo "$ac_err" >&5
2604   echo "configure: failed program was:" >&5
2605   cat conftest.$ac_ext >&5
2606   rm -rf conftest*
2607   eval "ac_cv_header_$ac_safe=no"
2608 fi
2609 rm -f conftest*
2610 fi
2611 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2612   echo "$ac_t""yes" 1>&6
2613     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2614   cat >> confdefs.h <<EOF
2615 #define $ac_tr_hdr 1
2616 EOF
2617  
2618 else
2619   echo "$ac_t""no" 1>&6
2620 fi
2621 done
2622
2623 for ac_hdr in getopt.h
2624 do
2625 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2626 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2627 echo "configure:2628: checking for $ac_hdr" >&5
2628 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2629   echo $ac_n "(cached) $ac_c" 1>&6
2630 else
2631   cat > conftest.$ac_ext <<EOF
2632 #line 2633 "configure"
2633 #include "confdefs.h"
2634 #include <$ac_hdr>
2635 EOF
2636 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2637 { (eval echo configure:2638: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2638 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2639 if test -z "$ac_err"; then
2640   rm -rf conftest*
2641   eval "ac_cv_header_$ac_safe=yes"
2642 else
2643   echo "$ac_err" >&5
2644   echo "configure: failed program was:" >&5
2645   cat conftest.$ac_ext >&5
2646   rm -rf conftest*
2647   eval "ac_cv_header_$ac_safe=no"
2648 fi
2649 rm -f conftest*
2650 fi
2651 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2652   echo "$ac_t""yes" 1>&6
2653     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2654   cat >> confdefs.h <<EOF
2655 #define $ac_tr_hdr 1
2656 EOF
2657  
2658 else
2659   echo "$ac_t""no" 1>&6
2660 fi
2661 done
2662
2663 for ac_hdr in sys/sockio.h
2664 do
2665 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2666 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2667 echo "configure:2668: checking for $ac_hdr" >&5
2668 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2669   echo $ac_n "(cached) $ac_c" 1>&6
2670 else
2671   cat > conftest.$ac_ext <<EOF
2672 #line 2673 "configure"
2673 #include "confdefs.h"
2674 #include <$ac_hdr>
2675 EOF
2676 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2677 { (eval echo configure:2678: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2678 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2679 if test -z "$ac_err"; then
2680   rm -rf conftest*
2681   eval "ac_cv_header_$ac_safe=yes"
2682 else
2683   echo "$ac_err" >&5
2684   echo "configure: failed program was:" >&5
2685   cat conftest.$ac_ext >&5
2686   rm -rf conftest*
2687   eval "ac_cv_header_$ac_safe=no"
2688 fi
2689 rm -f conftest*
2690 fi
2691 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2692   echo "$ac_t""yes" 1>&6
2693     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2694   cat >> confdefs.h <<EOF
2695 #define $ac_tr_hdr 1
2696 EOF
2697  
2698 else
2699   echo "$ac_t""no" 1>&6
2700 fi
2701 done
2702
2703 for ac_hdr in fcntl.h sys/ioctl.h sys/time.h unistd.h
2704 do
2705 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2706 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2707 echo "configure:2708: checking for $ac_hdr" >&5
2708 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2709   echo $ac_n "(cached) $ac_c" 1>&6
2710 else
2711   cat > conftest.$ac_ext <<EOF
2712 #line 2713 "configure"
2713 #include "confdefs.h"
2714 #include <$ac_hdr>
2715 EOF
2716 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2717 { (eval echo configure:2718: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2718 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2719 if test -z "$ac_err"; then
2720   rm -rf conftest*
2721   eval "ac_cv_header_$ac_safe=yes"
2722 else
2723   echo "$ac_err" >&5
2724   echo "configure: failed program was:" >&5
2725   cat conftest.$ac_ext >&5
2726   rm -rf conftest*
2727   eval "ac_cv_header_$ac_safe=no"
2728 fi
2729 rm -f conftest*
2730 fi
2731 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2732   echo "$ac_t""yes" 1>&6
2733     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2734   cat >> confdefs.h <<EOF
2735 #define $ac_tr_hdr 1
2736 EOF
2737  
2738 else
2739   echo "$ac_t""no" 1>&6
2740 fi
2741 done
2742
2743 for ac_hdr in sys/soundcard.h machine/soundcard.h
2744 do
2745 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2746 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2747 echo "configure:2748: checking for $ac_hdr" >&5
2748 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2749   echo $ac_n "(cached) $ac_c" 1>&6
2750 else
2751   cat > conftest.$ac_ext <<EOF
2752 #line 2753 "configure"
2753 #include "confdefs.h"
2754 #include <$ac_hdr>
2755 EOF
2756 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2757 { (eval echo configure:2758: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2758 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2759 if test -z "$ac_err"; then
2760   rm -rf conftest*
2761   eval "ac_cv_header_$ac_safe=yes"
2762 else
2763   echo "$ac_err" >&5
2764   echo "configure: failed program was:" >&5
2765   cat conftest.$ac_ext >&5
2766   rm -rf conftest*
2767   eval "ac_cv_header_$ac_safe=no"
2768 fi
2769 rm -f conftest*
2770 fi
2771 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2772   echo "$ac_t""yes" 1>&6
2773     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2774   cat >> confdefs.h <<EOF
2775 #define $ac_tr_hdr 1
2776 EOF
2777  
2778 else
2779   echo "$ac_t""no" 1>&6
2780 fi
2781 done
2782
2783 for ac_hdr in dlfcn.h image.h
2784 do
2785 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2786 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2787 echo "configure:2788: checking for $ac_hdr" >&5
2788 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2789   echo $ac_n "(cached) $ac_c" 1>&6
2790 else
2791   cat > conftest.$ac_ext <<EOF
2792 #line 2793 "configure"
2793 #include "confdefs.h"
2794 #include <$ac_hdr>
2795 EOF
2796 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2797 { (eval echo configure:2798: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2798 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2799 if test -z "$ac_err"; then
2800   rm -rf conftest*
2801   eval "ac_cv_header_$ac_safe=yes"
2802 else
2803   echo "$ac_err" >&5
2804   echo "configure: failed program was:" >&5
2805   cat conftest.$ac_ext >&5
2806   rm -rf conftest*
2807   eval "ac_cv_header_$ac_safe=no"
2808 fi
2809 rm -f conftest*
2810 fi
2811 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2812   echo "$ac_t""yes" 1>&6
2813     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2814   cat >> confdefs.h <<EOF
2815 #define $ac_tr_hdr 1
2816 EOF
2817  
2818 else
2819   echo "$ac_t""no" 1>&6
2820 fi
2821 done
2822
2823 for ac_hdr in arpa/inet.h net/if.h netinet/in.h sys/socket.h
2824 do
2825 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2826 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2827 echo "configure:2828: checking for $ac_hdr" >&5
2828 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2829   echo $ac_n "(cached) $ac_c" 1>&6
2830 else
2831   cat > conftest.$ac_ext <<EOF
2832 #line 2833 "configure"
2833 #include "confdefs.h"
2834 #include <$ac_hdr>
2835 EOF
2836 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2837 { (eval echo configure:2838: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2838 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2839 if test -z "$ac_err"; then
2840   rm -rf conftest*
2841   eval "ac_cv_header_$ac_safe=yes"
2842 else
2843   echo "$ac_err" >&5
2844   echo "configure: failed program was:" >&5
2845   cat conftest.$ac_ext >&5
2846   rm -rf conftest*
2847   eval "ac_cv_header_$ac_safe=no"
2848 fi
2849 rm -f conftest*
2850 fi
2851 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2852   echo "$ac_t""yes" 1>&6
2853     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2854   cat >> confdefs.h <<EOF
2855 #define $ac_tr_hdr 1
2856 EOF
2857  
2858 else
2859   echo "$ac_t""no" 1>&6
2860 fi
2861 done
2862
2863 for ac_hdr in machine/param.h
2864 do
2865 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2866 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2867 echo "configure:2868: checking for $ac_hdr" >&5
2868 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2869   echo $ac_n "(cached) $ac_c" 1>&6
2870 else
2871   cat > conftest.$ac_ext <<EOF
2872 #line 2873 "configure"
2873 #include "confdefs.h"
2874 #include <$ac_hdr>
2875 EOF
2876 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2877 { (eval echo configure:2878: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2878 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2879 if test -z "$ac_err"; then
2880   rm -rf conftest*
2881   eval "ac_cv_header_$ac_safe=yes"
2882 else
2883   echo "$ac_err" >&5
2884   echo "configure: failed program was:" >&5
2885   cat conftest.$ac_ext >&5
2886   rm -rf conftest*
2887   eval "ac_cv_header_$ac_safe=no"
2888 fi
2889 rm -f conftest*
2890 fi
2891 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2892   echo "$ac_t""yes" 1>&6
2893     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2894   cat >> confdefs.h <<EOF
2895 #define $ac_tr_hdr 1
2896 EOF
2897  
2898 else
2899   echo "$ac_t""no" 1>&6
2900 fi
2901 done
2902
2903
2904 for ac_hdr in cthreads.h pthread.h kernel/scheduler.h kernel/OS.h
2905 do
2906 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2907 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2908 echo "configure:2909: checking for $ac_hdr" >&5
2909 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2910   echo $ac_n "(cached) $ac_c" 1>&6
2911 else
2912   cat > conftest.$ac_ext <<EOF
2913 #line 2914 "configure"
2914 #include "confdefs.h"
2915 #include <$ac_hdr>
2916 EOF
2917 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2918 { (eval echo configure:2919: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2919 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2920 if test -z "$ac_err"; then
2921   rm -rf conftest*
2922   eval "ac_cv_header_$ac_safe=yes"
2923 else
2924   echo "$ac_err" >&5
2925   echo "configure: failed program was:" >&5
2926   cat conftest.$ac_ext >&5
2927   rm -rf conftest*
2928   eval "ac_cv_header_$ac_safe=no"
2929 fi
2930 rm -f conftest*
2931 fi
2932 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2933   echo "$ac_t""yes" 1>&6
2934     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2935   cat >> confdefs.h <<EOF
2936 #define $ac_tr_hdr 1
2937 EOF
2938  
2939 else
2940   echo "$ac_t""no" 1>&6
2941 fi
2942 done
2943
2944
2945 save_CFLAGS=$CFLAGS
2946
2947 CFLAGS="${CFLAGS} -Wall -Werror"
2948 echo $ac_n "checking for ntohl in sys/param.h""... $ac_c" 1>&6
2949 echo "configure:2950: checking for ntohl in sys/param.h" >&5
2950 cat > conftest.$ac_ext <<EOF
2951 #line 2952 "configure"
2952 #include "confdefs.h"
2953 #include <sys/param.h>
2954 void foo() { int meuh; ntohl(meuh); }
2955 int main() {
2956
2957 ; return 0; }
2958 EOF
2959 if { (eval echo configure:2960: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2960   rm -rf conftest*
2961   cat >> confdefs.h <<\EOF
2962 #define NTOHL_IN_SYS_PARAM_H 1
2963 EOF
2964
2965  echo "$ac_t""yes" 1>&6
2966 else
2967   echo "configure: failed program was:" >&5
2968   cat conftest.$ac_ext >&5
2969   rm -rf conftest*
2970   echo "$ac_t""no" 1>&6
2971 fi
2972 rm -f conftest*
2973
2974 CFLAGS="${CFLAGS} -rdynamic"
2975 echo $ac_n "checking if \$CC accepts -rdynamic""... $ac_c" 1>&6
2976 echo "configure:2977: checking if \$CC accepts -rdynamic" >&5
2977 cat > conftest.$ac_ext <<EOF
2978 #line 2979 "configure"
2979 #include "confdefs.h"
2980
2981 int main() {
2982
2983 ; return 0; }
2984 EOF
2985 if { (eval echo configure:2986: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2986   rm -rf conftest*
2987   DYNAMIC_FLAG="-rdynamic"
2988  echo "$ac_t""yes" 1>&6
2989 else
2990   echo "configure: failed program was:" >&5
2991   cat conftest.$ac_ext >&5
2992   rm -rf conftest*
2993   echo "$ac_t""no" 1>&6
2994 fi
2995 rm -f conftest*
2996
2997 CFLAGS=$save_CFLAGS
2998
2999 echo $ac_n "checking for boolean_t in sys/types.h""... $ac_c" 1>&6
3000 echo "configure:3001: checking for boolean_t in sys/types.h" >&5
3001 cat > conftest.$ac_ext <<EOF
3002 #line 3003 "configure"
3003 #include "confdefs.h"
3004 #include <sys/types.h>
3005 void quux() { boolean_t foo; }
3006 int main() {
3007
3008 ; return 0; }
3009 EOF
3010 if { (eval echo configure:3011: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3011   rm -rf conftest*
3012   cat >> confdefs.h <<\EOF
3013 #define BOOLEAN_T_IN_SYS_TYPES_H 1
3014 EOF
3015
3016  echo "$ac_t""yes" 1>&6
3017 else
3018   echo "configure: failed program was:" >&5
3019   cat conftest.$ac_ext >&5
3020   rm -rf conftest*
3021   echo "$ac_t""no" 1>&6
3022 fi
3023 rm -f conftest*
3024
3025 echo $ac_n "checking for working const""... $ac_c" 1>&6
3026 echo "configure:3027: checking for working const" >&5
3027 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
3028   echo $ac_n "(cached) $ac_c" 1>&6
3029 else
3030   cat > conftest.$ac_ext <<EOF
3031 #line 3032 "configure"
3032 #include "confdefs.h"
3033
3034 int main() {
3035
3036 /* Ultrix mips cc rejects this.  */
3037 typedef int charset[2]; const charset x;
3038 /* SunOS 4.1.1 cc rejects this.  */
3039 char const *const *ccp;
3040 char **p;
3041 /* NEC SVR4.0.2 mips cc rejects this.  */
3042 struct point {int x, y;};
3043 static struct point const zero = {0,0};
3044 /* AIX XL C 1.02.0.0 rejects this.
3045    It does not let you subtract one const X* pointer from another in an arm
3046    of an if-expression whose if-part is not a constant expression */
3047 const char *g = "string";
3048 ccp = &g + (g ? g-g : 0);
3049 /* HPUX 7.0 cc rejects these. */
3050 ++ccp;
3051 p = (char**) ccp;
3052 ccp = (char const *const *) p;
3053 { /* SCO 3.2v4 cc rejects this.  */
3054   char *t;
3055   char const *s = 0 ? (char *) 0 : (char const *) 0;
3056
3057   *t++ = 0;
3058 }
3059 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
3060   int x[] = {25, 17};
3061   const int *foo = &x[0];
3062   ++foo;
3063 }
3064 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
3065   typedef const int *iptr;
3066   iptr p = 0;
3067   ++p;
3068 }
3069 { /* AIX XL C 1.02.0.0 rejects this saying
3070      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
3071   struct s { int j; const int *ap[3]; };
3072   struct s *b; b->j = 5;
3073 }
3074 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
3075   const int foo = 10;
3076 }
3077
3078 ; return 0; }
3079 EOF
3080 if { (eval echo configure:3081: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3081   rm -rf conftest*
3082   ac_cv_c_const=yes
3083 else
3084   echo "configure: failed program was:" >&5
3085   cat conftest.$ac_ext >&5
3086   rm -rf conftest*
3087   ac_cv_c_const=no
3088 fi
3089 rm -f conftest*
3090 fi
3091
3092 echo "$ac_t""$ac_cv_c_const" 1>&6
3093 if test $ac_cv_c_const = no; then
3094   cat >> confdefs.h <<\EOF
3095 #define const 
3096 EOF
3097
3098 fi
3099
3100 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
3101 echo "configure:3102: checking for ANSI C header files" >&5
3102 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
3103   echo $ac_n "(cached) $ac_c" 1>&6
3104 else
3105   cat > conftest.$ac_ext <<EOF
3106 #line 3107 "configure"
3107 #include "confdefs.h"
3108 #include <stdlib.h>
3109 #include <stdarg.h>
3110 #include <string.h>
3111 #include <float.h>
3112 EOF
3113 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3114 { (eval echo configure:3115: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3115 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3116 if test -z "$ac_err"; then
3117   rm -rf conftest*
3118   ac_cv_header_stdc=yes
3119 else
3120   echo "$ac_err" >&5
3121   echo "configure: failed program was:" >&5
3122   cat conftest.$ac_ext >&5
3123   rm -rf conftest*
3124   ac_cv_header_stdc=no
3125 fi
3126 rm -f conftest*
3127
3128 if test $ac_cv_header_stdc = yes; then
3129   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3130 cat > conftest.$ac_ext <<EOF
3131 #line 3132 "configure"
3132 #include "confdefs.h"
3133 #include <string.h>
3134 EOF
3135 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3136   egrep "memchr" >/dev/null 2>&1; then
3137   :
3138 else
3139   rm -rf conftest*
3140   ac_cv_header_stdc=no
3141 fi
3142 rm -f conftest*
3143
3144 fi
3145
3146 if test $ac_cv_header_stdc = yes; then
3147   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3148 cat > conftest.$ac_ext <<EOF
3149 #line 3150 "configure"
3150 #include "confdefs.h"
3151 #include <stdlib.h>
3152 EOF
3153 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3154   egrep "free" >/dev/null 2>&1; then
3155   :
3156 else
3157   rm -rf conftest*
3158   ac_cv_header_stdc=no
3159 fi
3160 rm -f conftest*
3161
3162 fi
3163
3164 if test $ac_cv_header_stdc = yes; then
3165   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3166 if test "$cross_compiling" = yes; then
3167   :
3168 else
3169   cat > conftest.$ac_ext <<EOF
3170 #line 3171 "configure"
3171 #include "confdefs.h"
3172 #include <ctype.h>
3173 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3174 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3175 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3176 int main () { int i; for (i = 0; i < 256; i++)
3177 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
3178 exit (0); }
3179
3180 EOF
3181 if { (eval echo configure:3182: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3182 then
3183   :
3184 else
3185   echo "configure: failed program was:" >&5
3186   cat conftest.$ac_ext >&5
3187   rm -fr conftest*
3188   ac_cv_header_stdc=no
3189 fi
3190 rm -fr conftest*
3191 fi
3192
3193 fi
3194 fi
3195
3196 echo "$ac_t""$ac_cv_header_stdc" 1>&6
3197 if test $ac_cv_header_stdc = yes; then
3198   cat >> confdefs.h <<\EOF
3199 #define STDC_HEADERS 1
3200 EOF
3201
3202 fi
3203
3204 echo $ac_n "checking for size_t""... $ac_c" 1>&6
3205 echo "configure:3206: checking for size_t" >&5
3206 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
3207   echo $ac_n "(cached) $ac_c" 1>&6
3208 else
3209   cat > conftest.$ac_ext <<EOF
3210 #line 3211 "configure"
3211 #include "confdefs.h"
3212 #include <sys/types.h>
3213 #if STDC_HEADERS
3214 #include <stdlib.h>
3215 #include <stddef.h>
3216 #endif
3217 EOF
3218 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3219   egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3220   rm -rf conftest*
3221   ac_cv_type_size_t=yes
3222 else
3223   rm -rf conftest*
3224   ac_cv_type_size_t=no
3225 fi
3226 rm -f conftest*
3227
3228 fi
3229 echo "$ac_t""$ac_cv_type_size_t" 1>&6
3230 if test $ac_cv_type_size_t = no; then
3231   cat >> confdefs.h <<\EOF
3232 #define size_t unsigned
3233 EOF
3234
3235 fi
3236
3237 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
3238 echo "configure:3239: checking whether time.h and sys/time.h may both be included" >&5
3239 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
3240   echo $ac_n "(cached) $ac_c" 1>&6
3241 else
3242   cat > conftest.$ac_ext <<EOF
3243 #line 3244 "configure"
3244 #include "confdefs.h"
3245 #include <sys/types.h>
3246 #include <sys/time.h>
3247 #include <time.h>
3248 int main() {
3249 struct tm *tp;
3250 ; return 0; }
3251 EOF
3252 if { (eval echo configure:3253: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3253   rm -rf conftest*
3254   ac_cv_header_time=yes
3255 else
3256   echo "configure: failed program was:" >&5
3257   cat conftest.$ac_ext >&5
3258   rm -rf conftest*
3259   ac_cv_header_time=no
3260 fi
3261 rm -f conftest*
3262 fi
3263
3264 echo "$ac_t""$ac_cv_header_time" 1>&6
3265 if test $ac_cv_header_time = yes; then
3266   cat >> confdefs.h <<\EOF
3267 #define TIME_WITH_SYS_TIME 1
3268 EOF
3269
3270 fi
3271
3272
3273 for ac_hdr in sys/ioctl.h
3274 do
3275 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3276 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3277 echo "configure:3278: checking for $ac_hdr" >&5
3278 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3279   echo $ac_n "(cached) $ac_c" 1>&6
3280 else
3281   cat > conftest.$ac_ext <<EOF
3282 #line 3283 "configure"
3283 #include "confdefs.h"
3284 #include <$ac_hdr>
3285 EOF
3286 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3287 { (eval echo configure:3288: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3288 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3289 if test -z "$ac_err"; then
3290   rm -rf conftest*
3291   eval "ac_cv_header_$ac_safe=yes"
3292 else
3293   echo "$ac_err" >&5
3294   echo "configure: failed program was:" >&5
3295   cat conftest.$ac_ext >&5
3296   rm -rf conftest*
3297   eval "ac_cv_header_$ac_safe=no"
3298 fi
3299 rm -f conftest*
3300 fi
3301 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3302   echo "$ac_t""yes" 1>&6
3303     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3304   cat >> confdefs.h <<EOF
3305 #define $ac_tr_hdr 1
3306 EOF
3307  for ac_hdr in linux/cdrom.h
3308 do
3309 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3310 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3311 echo "configure:3312: checking for $ac_hdr" >&5
3312 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3313   echo $ac_n "(cached) $ac_c" 1>&6
3314 else
3315   cat > conftest.$ac_ext <<EOF
3316 #line 3317 "configure"
3317 #include "confdefs.h"
3318 #include <$ac_hdr>
3319 EOF
3320 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3321 { (eval echo configure:3322: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3322 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3323 if test -z "$ac_err"; then
3324   rm -rf conftest*
3325   eval "ac_cv_header_$ac_safe=yes"
3326 else
3327   echo "$ac_err" >&5
3328   echo "configure: failed program was:" >&5
3329   cat conftest.$ac_ext >&5
3330   rm -rf conftest*
3331   eval "ac_cv_header_$ac_safe=no"
3332 fi
3333 rm -f conftest*
3334 fi
3335 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3336   echo "$ac_t""yes" 1>&6
3337     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3338   cat >> confdefs.h <<EOF
3339 #define $ac_tr_hdr 1
3340 EOF
3341  
3342 else
3343   echo "$ac_t""no" 1>&6
3344 fi
3345 done
3346
3347    cat > conftest.$ac_ext <<EOF
3348 #line 3349 "configure"
3349 #include "confdefs.h"
3350 #include <linux/cdrom.h>
3351 EOF
3352 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3353   egrep "dvd" >/dev/null 2>&1; then
3354   rm -rf conftest*
3355   cat >> confdefs.h <<\EOF
3356 #define LINUX_DVD 1
3357 EOF
3358
3359 fi
3360 rm -f conftest*
3361
3362 else
3363   echo "$ac_t""no" 1>&6
3364 fi
3365 done
3366
3367
3368 PLUGINS=${PLUGINS}"ps ts dvd yuv idct idctclassic motion ";
3369
3370 ARCH=${host_cpu}
3371 # Check whether --enable-ppro or --disable-ppro was given.
3372 if test "${enable_ppro+set}" = set; then
3373   enableval="$enable_ppro"
3374    if test x$enableval = xyes; then ARCH=${ARCH}" ppro"; fi 
3375 else
3376    if test x${host_cpu} = xi686; then ARCH=${ARCH}" ppro"; fi 
3377 fi
3378
3379 # Check whether --enable-mmx or --disable-mmx was given.
3380 if test "${enable_mmx+set}" = set; then
3381   enableval="$enable_mmx"
3382    if test x$enableval = xyes; then ARCH=${ARCH}" mmx"; PLUGINS=${PLUGINS}"yuvmmx motionmmx motionmmxext idctmmx idctmmxext "; fi 
3383 else
3384    if test x${host_cpu} = xi686 -o x${host_cpu} = xi586; then ARCH=${ARCH}" mmx"; PLUGINS=${PLUGINS}"yuvmmx motionmmx motionmmxext idctmmx idctmmxext "; fi 
3385 fi
3386
3387 # Check whether --enable-debug or --disable-debug was given.
3388 if test "${enable_debug+set}" = set; then
3389   enableval="$enable_debug"
3390    if test x$enableval = xyes; then DEBUG=1; fi 
3391 fi
3392
3393 # Check whether --enable-stats or --disable-stats was given.
3394 if test "${enable_stats+set}" = set; then
3395   enableval="$enable_stats"
3396    if test x$enableval = xyes; then STATS=1; fi 
3397 fi
3398
3399 # Check whether --enable-optimizations or --disable-optimizations was given.
3400 if test "${enable_optimizations+set}" = set; then
3401   enableval="$enable_optimizations"
3402    if test x$enableval = xno; then OPTIMS=0; fi 
3403 else
3404    OPTIMS=1 
3405 fi
3406
3407
3408 SYS=${host_os}
3409
3410 # special cases
3411 if test x$host_os = xbeos; then
3412     PLUGINS=${PLUGINS}"dummy null beos "
3413
3414 else
3415
3416 # Check whether --enable-dummy or --disable-dummy was given.
3417 if test "${enable_dummy+set}" = set; then
3418   enableval="$enable_dummy"
3419   :
3420 fi
3421
3422 if test x$enable_dummy != xno; then PLUGINS=${PLUGINS}"dummy "; fi
3423 # Check whether --enable-null or --disable-null was given.
3424 if test "${enable_null+set}" = set; then
3425   enableval="$enable_null"
3426   :
3427 fi
3428
3429 if test x$enable_null != xno; then PLUGINS=${PLUGINS}"null "; fi
3430 # Check whether --enable-dsp or --disable-dsp was given.
3431 if test "${enable_dsp+set}" = set; then
3432   enableval="$enable_dsp"
3433   :
3434 fi
3435
3436 if test x$enable_dsp != xno; then PLUGINS=${PLUGINS}"dsp "; fi
3437 # Check whether --enable-esd or --disable-esd was given.
3438 if test "${enable_esd+set}" = set; then
3439   enableval="$enable_esd"
3440   if test x$enable_esd = xyes; then PLUGINS=${PLUGINS}"esd "; fi
3441 fi
3442
3443 # Check whether --enable-fb or --disable-fb was given.
3444 if test "${enable_fb+set}" = set; then
3445   enableval="$enable_fb"
3446   if test x$enable_fb = xyes; then PLUGINS=${PLUGINS}"fb "; ALIASES=${ALIASES}"fbvlc "; fi
3447 fi
3448
3449 # Check whether --with-ggi or --without-ggi was given.
3450 if test "${with_ggi+set}" = set; then
3451   withval="$with_ggi"
3452    PLUGINS=${PLUGINS}"ggi ";
3453     if test "x$withval" != "xyes";
3454     then
3455       LIB_GGI="-l"$withval
3456     else
3457       LIB_GGI="-lggi"
3458     fi 
3459 fi
3460
3461 # Check whether --with-sdl or --without-sdl was given.
3462 if test "${with_sdl+set}" = set; then
3463   withval="$with_sdl"
3464    PLUGINS=${PLUGINS}"sdl ";
3465     if test "x$withval" != "xyes";
3466     then
3467       LIB_SDL="-l"$withval
3468     else
3469       LIB_SDL="-lSDL"
3470     fi 
3471 fi
3472
3473     if test "x$withval" == "x";
3474     then
3475       PLUGINS=${PLUGINS}"sdl "
3476       LIB_SDL="-lSDL"
3477     fi
3478 # Check whether --with-glide or --without-glide was given.
3479 if test "${with_glide+set}" = set; then
3480   withval="$with_glide"
3481    PLUGINS=${PLUGINS}"glide ";
3482     if test "x$withval" != "xyes";
3483     then
3484       LIB_GLIDE="-l"$withval
3485     else
3486       LIB_GLIDE="-lglide2x"
3487     fi 
3488 fi
3489
3490 # Check whether --enable-gnome or --disable-gnome was given.
3491 if test "${enable_gnome+set}" = set; then
3492   enableval="$enable_gnome"
3493   :
3494 fi
3495
3496 if test x$enable_gnome != xno; then PLUGINS=${PLUGINS}"gnome "; ALIASES=${ALIASES}"gvlc "; fi
3497 # Check whether --enable-gnome or --disable-gnome was given.
3498 if test "${enable_gnome+set}" = set; then
3499   enableval="$enable_gnome"
3500   :
3501 fi
3502
3503 if test x$enable_x11 != xno; then PLUGINS=${PLUGINS}"x11 "; fi
3504
3505 # Check whether --enable-alsa or --disable-alsa was given.
3506 if test "${enable_alsa+set}" = set; then
3507   enableval="$enable_alsa"
3508   if test x$enable_alsa = xyes; then ac_safe=`echo "sys/asoundlib.h" | sed 'y%./+-%__p_%'`
3509 echo $ac_n "checking for sys/asoundlib.h""... $ac_c" 1>&6
3510 echo "configure:3511: checking for sys/asoundlib.h" >&5
3511 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3512   echo $ac_n "(cached) $ac_c" 1>&6
3513 else
3514   cat > conftest.$ac_ext <<EOF
3515 #line 3516 "configure"
3516 #include "confdefs.h"
3517 #include <sys/asoundlib.h>
3518 EOF
3519 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3520 { (eval echo configure:3521: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3521 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3522 if test -z "$ac_err"; then
3523   rm -rf conftest*
3524   eval "ac_cv_header_$ac_safe=yes"
3525 else
3526   echo "$ac_err" >&5
3527   echo "configure: failed program was:" >&5
3528   cat conftest.$ac_ext >&5
3529   rm -rf conftest*
3530   eval "ac_cv_header_$ac_safe=no"
3531 fi
3532 rm -f conftest*
3533 fi
3534 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3535   echo "$ac_t""yes" 1>&6
3536   echo $ac_n "checking for main in -lasound""... $ac_c" 1>&6
3537 echo "configure:3538: checking for main in -lasound" >&5
3538 ac_lib_var=`echo asound'_'main | sed 'y%./+-%__p_%'`
3539 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3540   echo $ac_n "(cached) $ac_c" 1>&6
3541 else
3542   ac_save_LIBS="$LIBS"
3543 LIBS="-lasound  $LIBS"
3544 cat > conftest.$ac_ext <<EOF
3545 #line 3546 "configure"
3546 #include "confdefs.h"
3547
3548 int main() {
3549 main()
3550 ; return 0; }
3551 EOF
3552 if { (eval echo configure:3553: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3553   rm -rf conftest*
3554   eval "ac_cv_lib_$ac_lib_var=yes"
3555 else
3556   echo "configure: failed program was:" >&5
3557   cat conftest.$ac_ext >&5
3558   rm -rf conftest*
3559   eval "ac_cv_lib_$ac_lib_var=no"
3560 fi
3561 rm -f conftest*
3562 LIBS="$ac_save_LIBS"
3563
3564 fi
3565 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3566   echo "$ac_t""yes" 1>&6
3567   have_alsa="true"
3568 else
3569   echo "$ac_t""no" 1>&6
3570 have_alsa="false"
3571 fi
3572
3573 else
3574   echo "$ac_t""no" 1>&6
3575 have_alsa="false"
3576 fi
3577  if test $have_alsa = true; then PLUGINS=${PLUGINS}"alsa "; fi; fi
3578 fi
3579
3580 fi
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594 trap '' 1 2 15
3595 cat > confcache <<\EOF
3596 # This file is a shell script that caches the results of configure
3597 # tests run on this system so they can be shared between configure
3598 # scripts and configure runs.  It is not useful on other systems.
3599 # If it contains results you don't want to keep, you may remove or edit it.
3600 #
3601 # By default, configure uses ./config.cache as the cache file,
3602 # creating it if it does not exist already.  You can give configure
3603 # the --cache-file=FILE option to use a different cache file; that is
3604 # what configure does when it calls configure scripts in
3605 # subdirectories, so they share the cache.
3606 # Giving --cache-file=/dev/null disables caching, for debugging configure.
3607 # config.status only pays attention to the cache file if you give it the
3608 # --recheck option to rerun configure.
3609 #
3610 EOF
3611 # The following way of writing the cache mishandles newlines in values,
3612 # but we know of no workaround that is simple, portable, and efficient.
3613 # So, don't put newlines in cache variables' values.
3614 # Ultrix sh set writes to stderr and can't be redirected directly,
3615 # and sets the high bit in the cache file unless we assign to the vars.
3616 (set) 2>&1 |
3617   case `(ac_space=' '; set | grep ac_space) 2>&1` in
3618   *ac_space=\ *)
3619     # `set' does not quote correctly, so add quotes (double-quote substitution
3620     # turns \\\\ into \\, and sed turns \\ into \).
3621     sed -n \
3622       -e "s/'/'\\\\''/g" \
3623       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
3624     ;;
3625   *)
3626     # `set' quotes correctly as required by POSIX, so do not add quotes.
3627     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
3628     ;;
3629   esac >> confcache
3630 if cmp -s $cache_file confcache; then
3631   :
3632 else
3633   if test -w $cache_file; then
3634     echo "updating cache $cache_file"
3635     cat confcache > $cache_file
3636   else
3637     echo "not updating unwritable cache $cache_file"
3638   fi
3639 fi
3640 rm -f confcache
3641
3642 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
3643
3644 test "x$prefix" = xNONE && prefix=$ac_default_prefix
3645 # Let make expand exec_prefix.
3646 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
3647
3648 # Any assignment to VPATH causes Sun make to only execute
3649 # the first set of double-colon rules, so remove it if not needed.
3650 # If there is a colon in the path, we need to keep it.
3651 if test "x$srcdir" = x.; then
3652   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
3653 fi
3654
3655 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
3656
3657 DEFS=-DHAVE_CONFIG_H
3658
3659 # Without the "./", some shells look in PATH for config.status.
3660 : ${CONFIG_STATUS=./config.status}
3661
3662 echo creating $CONFIG_STATUS
3663 rm -f $CONFIG_STATUS
3664 cat > $CONFIG_STATUS <<EOF
3665 #! /bin/sh
3666 # Generated automatically by configure.
3667 # Run this file to recreate the current configuration.
3668 # This directory was configured as follows,
3669 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3670 #
3671 # $0 $ac_configure_args
3672 #
3673 # Compiler output produced by configure, useful for debugging
3674 # configure, is in ./config.log if it exists.
3675
3676 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
3677 for ac_option
3678 do
3679   case "\$ac_option" in
3680   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
3681     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
3682     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
3683   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
3684     echo "$CONFIG_STATUS generated by autoconf version 2.13"
3685     exit 0 ;;
3686   -help | --help | --hel | --he | --h)
3687     echo "\$ac_cs_usage"; exit 0 ;;
3688   *) echo "\$ac_cs_usage"; exit 1 ;;
3689   esac
3690 done
3691
3692 ac_given_srcdir=$srcdir
3693 ac_given_INSTALL="$INSTALL"
3694
3695 trap 'rm -fr `echo "Makefile include/config.h include/defs.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
3696 EOF
3697 cat >> $CONFIG_STATUS <<EOF
3698
3699 # Protect against being on the right side of a sed subst in config.status.
3700 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
3701  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
3702 $ac_vpsub
3703 $extrasub
3704 s%@SHELL@%$SHELL%g
3705 s%@CFLAGS@%$CFLAGS%g
3706 s%@CPPFLAGS@%$CPPFLAGS%g
3707 s%@CXXFLAGS@%$CXXFLAGS%g
3708 s%@FFLAGS@%$FFLAGS%g
3709 s%@DEFS@%$DEFS%g
3710 s%@LDFLAGS@%$LDFLAGS%g
3711 s%@LIBS@%$LIBS%g
3712 s%@exec_prefix@%$exec_prefix%g
3713 s%@prefix@%$prefix%g
3714 s%@program_transform_name@%$program_transform_name%g
3715 s%@bindir@%$bindir%g
3716 s%@sbindir@%$sbindir%g
3717 s%@libexecdir@%$libexecdir%g
3718 s%@datadir@%$datadir%g
3719 s%@sysconfdir@%$sysconfdir%g
3720 s%@sharedstatedir@%$sharedstatedir%g
3721 s%@localstatedir@%$localstatedir%g
3722 s%@libdir@%$libdir%g
3723 s%@includedir@%$includedir%g
3724 s%@oldincludedir@%$oldincludedir%g
3725 s%@infodir@%$infodir%g
3726 s%@mandir@%$mandir%g
3727 s%@host@%$host%g
3728 s%@host_alias@%$host_alias%g
3729 s%@host_cpu@%$host_cpu%g
3730 s%@host_vendor@%$host_vendor%g
3731 s%@host_os@%$host_os%g
3732 s%@VLC_VERSION@%$VLC_VERSION%g
3733 s%@VLC_CODENAME@%$VLC_CODENAME%g
3734 s%@SET_MAKE@%$SET_MAKE%g
3735 s%@CC@%$CC%g
3736 s%@CPP@%$CPP%g
3737 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
3738 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
3739 s%@INSTALL_DATA@%$INSTALL_DATA%g
3740 s%@LIBOBJS@%$LIBOBJS%g
3741 s%@SYS@%$SYS%g
3742 s%@ARCH@%$ARCH%g
3743 s%@PLUGINS@%$PLUGINS%g
3744 s%@ALIASES@%$ALIASES%g
3745 s%@DEBUG@%$DEBUG%g
3746 s%@STATS@%$STATS%g
3747 s%@OPTIMS@%$OPTIMS%g
3748 s%@DYNAMIC_FLAG@%$DYNAMIC_FLAG%g
3749 s%@LIB_SDL@%$LIB_SDL%g
3750 s%@LIB_GLIDE@%$LIB_GLIDE%g
3751 s%@LIB_GGI@%$LIB_GGI%g
3752
3753 CEOF
3754 EOF
3755
3756 cat >> $CONFIG_STATUS <<\EOF
3757
3758 # Split the substitutions into bite-sized pieces for seds with
3759 # small command number limits, like on Digital OSF/1 and HP-UX.
3760 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
3761 ac_file=1 # Number of current file.
3762 ac_beg=1 # First line for current file.
3763 ac_end=$ac_max_sed_cmds # Line after last line for current file.
3764 ac_more_lines=:
3765 ac_sed_cmds=""
3766 while $ac_more_lines; do
3767   if test $ac_beg -gt 1; then
3768     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
3769   else
3770     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
3771   fi
3772   if test ! -s conftest.s$ac_file; then
3773     ac_more_lines=false
3774     rm -f conftest.s$ac_file
3775   else
3776     if test -z "$ac_sed_cmds"; then
3777       ac_sed_cmds="sed -f conftest.s$ac_file"
3778     else
3779       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
3780     fi
3781     ac_file=`expr $ac_file + 1`
3782     ac_beg=$ac_end
3783     ac_end=`expr $ac_end + $ac_max_sed_cmds`
3784   fi
3785 done
3786 if test -z "$ac_sed_cmds"; then
3787   ac_sed_cmds=cat
3788 fi
3789 EOF
3790
3791 cat >> $CONFIG_STATUS <<EOF
3792
3793 CONFIG_FILES=\${CONFIG_FILES-"Makefile include/config.h"}
3794 EOF
3795 cat >> $CONFIG_STATUS <<\EOF
3796 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
3797   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3798   case "$ac_file" in
3799   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3800        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3801   *) ac_file_in="${ac_file}.in" ;;
3802   esac
3803
3804   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
3805
3806   # Remove last slash and all that follows it.  Not all systems have dirname.
3807   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3808   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3809     # The file is in a subdirectory.
3810     test ! -d "$ac_dir" && mkdir "$ac_dir"
3811     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
3812     # A "../" for each directory in $ac_dir_suffix.
3813     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
3814   else
3815     ac_dir_suffix= ac_dots=
3816   fi
3817
3818   case "$ac_given_srcdir" in
3819   .)  srcdir=.
3820       if test -z "$ac_dots"; then top_srcdir=.
3821       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
3822   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
3823   *) # Relative path.
3824     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
3825     top_srcdir="$ac_dots$ac_given_srcdir" ;;
3826   esac
3827
3828   case "$ac_given_INSTALL" in
3829   [/$]*) INSTALL="$ac_given_INSTALL" ;;
3830   *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
3831   esac
3832
3833   echo creating "$ac_file"
3834   rm -f "$ac_file"
3835   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
3836   case "$ac_file" in
3837   *Makefile*) ac_comsub="1i\\
3838 # $configure_input" ;;
3839   *) ac_comsub= ;;
3840   esac
3841
3842   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3843   sed -e "$ac_comsub
3844 s%@configure_input@%$configure_input%g
3845 s%@srcdir@%$srcdir%g
3846 s%@top_srcdir@%$top_srcdir%g
3847 s%@INSTALL@%$INSTALL%g
3848 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
3849 fi; done
3850 rm -f conftest.s*
3851
3852 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
3853 # NAME is the cpp macro being defined and VALUE is the value it is being given.
3854 #
3855 # ac_d sets the value in "#define NAME VALUE" lines.
3856 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
3857 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
3858 ac_dC='\3'
3859 ac_dD='%g'
3860 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
3861 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3862 ac_uB='\([      ]\)%\1#\2define\3'
3863 ac_uC=' '
3864 ac_uD='\4%g'
3865 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
3866 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3867 ac_eB='$%\1#\2define\3'
3868 ac_eC=' '
3869 ac_eD='%g'
3870
3871 if test "${CONFIG_HEADERS+set}" != set; then
3872 EOF
3873 cat >> $CONFIG_STATUS <<EOF
3874   CONFIG_HEADERS="include/defs.h"
3875 EOF
3876 cat >> $CONFIG_STATUS <<\EOF
3877 fi
3878 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
3879   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3880   case "$ac_file" in
3881   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3882        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3883   *) ac_file_in="${ac_file}.in" ;;
3884   esac
3885
3886   echo creating $ac_file
3887
3888   rm -f conftest.frag conftest.in conftest.out
3889   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3890   cat $ac_file_inputs > conftest.in
3891
3892 EOF
3893
3894 # Transform confdefs.h into a sed script conftest.vals that substitutes
3895 # the proper values into config.h.in to produce config.h.  And first:
3896 # Protect against being on the right side of a sed subst in config.status.
3897 # Protect against being in an unquoted here document in config.status.
3898 rm -f conftest.vals
3899 cat > conftest.hdr <<\EOF
3900 s/[\\&%]/\\&/g
3901 s%[\\$`]%\\&%g
3902 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
3903 s%ac_d%ac_u%gp
3904 s%ac_u%ac_e%gp
3905 EOF
3906 sed -n -f conftest.hdr confdefs.h > conftest.vals
3907 rm -f conftest.hdr
3908
3909 # This sed command replaces #undef with comments.  This is necessary, for
3910 # example, in the case of _POSIX_SOURCE, which is predefined and required
3911 # on some systems where configure will not decide to define it.
3912 cat >> conftest.vals <<\EOF
3913 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
3914 EOF
3915
3916 # Break up conftest.vals because some shells have a limit on
3917 # the size of here documents, and old seds have small limits too.
3918
3919 rm -f conftest.tail
3920 while :
3921 do
3922   ac_lines=`grep -c . conftest.vals`
3923   # grep -c gives empty output for an empty file on some AIX systems.
3924   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
3925   # Write a limited-size here document to conftest.frag.
3926   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
3927   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
3928   echo 'CEOF
3929   sed -f conftest.frag conftest.in > conftest.out
3930   rm -f conftest.in
3931   mv conftest.out conftest.in
3932 ' >> $CONFIG_STATUS
3933   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
3934   rm -f conftest.vals
3935   mv conftest.tail conftest.vals
3936 done
3937 rm -f conftest.vals
3938
3939 cat >> $CONFIG_STATUS <<\EOF
3940   rm -f conftest.frag conftest.h
3941   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
3942   cat conftest.in >> conftest.h
3943   rm -f conftest.in
3944   if cmp -s $ac_file conftest.h 2>/dev/null; then
3945     echo "$ac_file is unchanged"
3946     rm -f conftest.h
3947   else
3948     # Remove last slash and all that follows it.  Not all systems have dirname.
3949       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3950       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3951       # The file is in a subdirectory.
3952       test ! -d "$ac_dir" && mkdir "$ac_dir"
3953     fi
3954     rm -f $ac_file
3955     mv conftest.h $ac_file
3956   fi
3957 fi; done
3958
3959 EOF
3960 cat >> $CONFIG_STATUS <<EOF
3961
3962 EOF
3963 cat >> $CONFIG_STATUS <<\EOF
3964
3965 exit 0
3966 EOF
3967 chmod +x $CONFIG_STATUS
3968 rm -fr confdefs* $ac_clean_files
3969 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
3970
3971
3972 echo "
3973 vlc configuration
3974 -----------------
3975 vlc version           : ${VLC_VERSION}
3976 system                : ${SYS}
3977 architecture          : ${ARCH}
3978 debug mode            : ${DEBUG}
3979 statistics            : ${STATS}
3980 optimizations         : ${OPTIMS}
3981 plugins               : ${PLUGINS}
3982 vlc aliases           : ${ALIASES}
3983 "
3984