X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=configure;h=60663e3ce20f8b2665889a435c47a018773ad862;hb=9999e41e4408c65eef2b71679752487edec3cbb3;hp=b9a166cfb971acb3772ee77ad3b68c59a0d01ac4;hpb=a276a98ae40d306bd021281911087448f4b0563c;p=vlc diff --git a/configure b/configure index b9a166cfb9..60663e3ce2 100755 --- a/configure +++ b/configure @@ -12,80 +12,124 @@ ac_help= ac_default_prefix=/usr/local # Any additions from configure.in: ac_help="$ac_help - --with-words=endianness Set endianness (big or little)" + --with-libiconv-prefix=DIR search for libiconv in DIR/include and DIR/lib" ac_help="$ac_help - --with-tuning=[arch] Enable special tuning for an architecture - (default i686 on IA-32 and 750 on PPC)" + --disable-nls do not use Native Language Support" ac_help="$ac_help - --disable-mmx Disable MMX optimizations (default enabled for x86)" + --with-included-gettext use the GNU gettext library included here" ac_help="$ac_help - --disable-altivec Disable altivec optimizations (default enabled on PPC)" +" ac_help="$ac_help - --enable-debug Enable debug mode (default disabled)" +Optimization options:" ac_help="$ac_help - --enable-trace Enable trace mode (default disabled)" + --with-tuning=ARCH enable special tuning for an architecture + (default i686 on IA-32 and 750 on PPC)" ac_help="$ac_help - --enable-gprof Enable gprof profiling (default disabled)" + --disable-optimizations disable compiler optimizations (default enabled)" ac_help="$ac_help - --enable-cprof Enable cprof profiling (default disabled)" + --disable-altivec disable altivec optimizations (default enabled on PPC)" ac_help="$ac_help - --disable-optimizations Disable compiler optimizations (default enabled)" + --enable-debug debug mode (default disabled)" ac_help="$ac_help - --enable-pth Enable GNU Pth support (default disabled)" + --enable-release activate extra optimizations (default disabled)" ac_help="$ac_help - --with-dvdcss[=name] way to use libdvdcss, either 'yes' or 'no', - or 'local-static', 'local-shared', or a path to - another libdvdcss such as '/usr/local' - (default 'local-static')" +Input plugins:" ac_help="$ac_help - --enable-vcd VCDs support (default disabled)" + --with-dvdcss[=name] use libdvdcss, either 'yes', 'no', 'local-static', + 'local-shared', or a path to another libdvdcss such + as '/usr/local' (default 'local-static')" ac_help="$ac_help - --disable-dummy dummy module (default enabled)" + --with-dvdread[=name] use libdvdread, same options as dvdcss (default 'no')" ac_help="$ac_help - --disable-null Null module (default enabled)" + --enable-vcd VCD support for Linux (default enabled)" ac_help="$ac_help - --disable-rc rc module (default enabled)" + --enable-satellite Satellite card support (default disabled)" ac_help="$ac_help - --disable-dsp Linux /dev/dsp support (default enabled)" +Codec plugins:" ac_help="$ac_help - --enable-esd Esound library support (default disabled)" + --enable-mad libmad module (default disabled)" ac_help="$ac_help - --enable-darwin Darwin sound support (default enabled on MacOS X)" + --with-mad=PATH path to libmad" ac_help="$ac_help - --enable-macosx MacOS X support (default enabled on MacOS X)" + --disable-a52 AC3 support with liba52 (default enabled)" ac_help="$ac_help - --disable-qnx QNX RTOS support (default enabled on QNX RTOS)" +Video plugins:" ac_help="$ac_help - --enable-fb Linux framebuffer support (default disabled)" + --disable-x11 X11 support (default enabled)" ac_help="$ac_help - --with-ggi[=name] GGI support (default disabled)" + --disable-xvideo XVideo support (default enabled)" ac_help="$ac_help --disable-sdl SDL support (default enabled)" ac_help="$ac_help - --with-sdl-config-path=path sdl-config path (default search in \$PATH)" + --with-sdl-config-path=PATH sdl-config path (default search in \$PATH)" ac_help="$ac_help - --with-directx[=name] Windows DirectX support (default enabled)" + --enable-directx Win32 DirectX support (default enabled on Win32)" ac_help="$ac_help - --with-glide[=name] Glide (3dfx) support (default disabled)" + --with-directx=PATH Win32 DirectX headers and libraries" ac_help="$ac_help - --enable-ncurses ncurses interface support (default disabled)" + --enable-fb Linux framebuffer support (default enabled on Linux)" +ac_help="$ac_help + --enable-mga Linux kernel Matrox support (default disabled)" +ac_help="$ac_help + --enable-ggi GGI support (default disabled)" +ac_help="$ac_help + --with-ggi=PATH path to libggi" +ac_help="$ac_help + --enable-glide Glide (3dfx) support (default disabled)" +ac_help="$ac_help + --with-glide=PATH path to libglide" +ac_help="$ac_help + --enable-aa aalib output (default disabled)" +ac_help="$ac_help +Audio plugins:" +ac_help="$ac_help + --enable-dsp Linux /dev/dsp support (enabled on Linux)" +ac_help="$ac_help + --enable-esd Esound library support (default disabled)" +ac_help="$ac_help + --enable-arts aRts sound server (default disabled)" +ac_help="$ac_help + --enable-alsa ALSA sound support for Linux (default disabled)" +ac_help="$ac_help + --enable-waveout Win32 waveOut module (default enabled on Win32)" +ac_help="$ac_help +Interface plugins:" +ac_help="$ac_help + --disable-gtk Gtk+ support (default enabled)" +ac_help="$ac_help + --with-gtk-config-path=PATH gtk-config path (default search in \$PATH)" +ac_help="$ac_help + --enable-gnome Gnome interface support (default disabled)" ac_help="$ac_help --enable-qt Qt interface support (default disabled)" ac_help="$ac_help --enable-kde KDE interface support (default disabled)" ac_help="$ac_help - --enable-gnome Gnome interface support (default disabled)" + --enable-macosx MacOS X support (default enabled on MacOS X)" ac_help="$ac_help - --disable-gtk Gtk+ support (default enabled)" + --enable-qnx QNX RTOS support (default enabled on QNX RTOS)" ac_help="$ac_help - --disable-x11 X11 support (default enabled)" + --enable-win32 Win32 interface support (default disabled)" ac_help="$ac_help - --disable-xvideo XVideo support (default enabled)" + --enable-ncurses ncurses interface support (default disabled)" +ac_help="$ac_help + --enable-lirc lirc support (default disabled)" +ac_help="$ac_help +Misc options:" +ac_help="$ac_help + --with-words=endianness set endianness (big or little)" +ac_help="$ac_help + --with-dll-path=PATH path to Win32 DLLs (default search in \$PWD)" +ac_help="$ac_help + --enable-gprof gprof profiling (default disabled)" +ac_help="$ac_help + --enable-cprof cprof profiling (default disabled)" +ac_help="$ac_help + --enable-pth GNU Pth support (default disabled)" ac_help="$ac_help - --enable-alsa Alsa sound drivers support (Only for linux) - (default disabled)" + --enable-st State Threads (default disabled)" ac_help="$ac_help - --disable-plugins Make all plug-ins built-in (default plug-ins enabled)" + --disable-plugins make all plug-ins built-in (default plug-ins enabled)" # Initialize some variables set by options. # The variables have the same names as the options, with @@ -526,7 +570,7 @@ echo > confdefs.h # A filename unique to this package, relative to the directory that # configure is in, which we can look for to find out if srcdir is correct. -ac_unique_file=include/common.h +ac_unique_file=include/main.h # Find the source files, if location was not specified. if test -z "$srcdir"; then @@ -645,7 +689,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } fi echo $ac_n "checking host system type""... $ac_c" 1>&6 -echo "configure:649: checking host system type" >&5 +echo "configure:693: checking host system type" >&5 host_alias=$host case "$host_alias" in @@ -666,7 +710,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` echo "$ac_t""$host" 1>&6 echo $ac_n "checking target system type""... $ac_c" 1>&6 -echo "configure:670: checking target system type" >&5 +echo "configure:714: checking target system type" >&5 target_alias=$target case "$target_alias" in @@ -684,7 +728,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` echo "$ac_t""$target" 1>&6 echo $ac_n "checking build system type""... $ac_c" 1>&6 -echo "configure:688: checking build system type" >&5 +echo "configure:732: checking build system type" >&5 build_alias=$build case "$build_alias" in @@ -710,16 +754,14 @@ test "$host_alias" != "$target_alias" && HAVE_VLC=0 if test -r src/interface/main.c; then HAVE_VLC=1 - VLC_VERSION=0.2.90 - + VLC_VERSION="0.2.92-dev" VLC_CODENAME=Ourumov - fi HAVE_LIBDVDCSS=0 if test -r extras/libdvdcss/libdvdcss.c; then HAVE_LIBDVDCSS=1 - LIBDVDCSS_VERSION=0.0.3 + LIBDVDCSS_VERSION="1.0.1-dev" if test -r extras/libdvdcss/csskeys.h; then cat >> confdefs.h <<\EOF @@ -733,7 +775,7 @@ save_CFLAGS="${CFLAGS}" save_LDFLAGS="${LDFLAGS}" echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 -echo "configure:737: checking whether ${MAKE-make} sets \${MAKE}" >&5 +echo "configure:779: checking whether ${MAKE-make} sets \${MAKE}" >&5 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -762,7 +804,7 @@ fi # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:766: checking for $ac_word" >&5 +echo "configure:808: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -792,7 +834,7 @@ if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:796: checking for $ac_word" >&5 +echo "configure:838: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -843,7 +885,7 @@ fi # Extract the first word of "cl", so it can be a program name with args. set dummy cl; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:847: checking for $ac_word" >&5 +echo "configure:889: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -875,7 +917,7 @@ fi fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 -echo "configure:879: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +echo "configure:921: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ac_ext=c # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. @@ -886,12 +928,12 @@ cross_compiling=$ac_cv_prog_cc_cross cat > conftest.$ac_ext << EOF -#line 890 "configure" +#line 932 "configure" #include "confdefs.h" main(){return(0);} EOF -if { (eval echo configure:895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:937: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ac_cv_prog_cc_works=yes # If we can't run a trivial program, we are probably using a cross compiler. if (./conftest; exit) 2>/dev/null; then @@ -917,12 +959,12 @@ if test $ac_cv_prog_cc_works = no; then { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 -echo "configure:921: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:963: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 cross_compiling=$ac_cv_prog_cc_cross echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 -echo "configure:926: checking whether we are using GNU C" >&5 +echo "configure:968: checking whether we are using GNU C" >&5 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -931,7 +973,7 @@ else yes; #endif EOF -if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:935: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:977: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then ac_cv_prog_gcc=yes else ac_cv_prog_gcc=no @@ -950,7 +992,7 @@ ac_test_CFLAGS="${CFLAGS+set}" ac_save_CFLAGS="$CFLAGS" CFLAGS= echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 -echo "configure:954: checking whether ${CC-cc} accepts -g" >&5 +echo "configure:996: checking whether ${CC-cc} accepts -g" >&5 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -982,7 +1024,7 @@ else fi echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 -echo "configure:986: checking how to run the C preprocessor" >&5 +echo "configure:1028: checking how to run the C preprocessor" >&5 # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= @@ -997,13 +1039,13 @@ else # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1007: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1049: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -1014,13 +1056,13 @@ else rm -rf conftest* CPP="${CC-cc} -E -traditional-cpp" cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1024: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1066: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -1031,13 +1073,13 @@ else rm -rf conftest* CPP="${CC-cc} -nologo -E" cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1041: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1083: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -1061,10 +1103,49 @@ else fi echo "$ac_t""$CPP" 1>&6 -# Extract the first word of "ranlib", so it can be a program name with args. + +if test $host != $build; then + ac_tool_prefix=${host_alias}- +else + ac_tool_prefix= +fi + +# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. +set dummy ${ac_tool_prefix}ranlib; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:1117: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" + break + fi + done + IFS="$ac_save_ifs" +fi +fi +RANLIB="$ac_cv_prog_RANLIB" +if test -n "$RANLIB"; then + echo "$ac_t""$RANLIB" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + + +if test -z "$ac_cv_prog_RANLIB"; then +if test -n "$ac_tool_prefix"; then + # Extract the first word of "ranlib", so it can be a program name with args. set dummy ranlib; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1068: checking for $ac_word" >&5 +echo "configure:1149: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1091,653 +1172,720 @@ else echo "$ac_t""no" 1>&6 fi +else + RANLIB=":" +fi +fi -# Find a good install program. We prefer a C program (faster), -# so one script is as good as another. But avoid the broken or -# incompatible versions: -# SysV /etc/install, /usr/sbin/install -# SunOS /usr/etc/install -# IRIX /sbin/install -# AIX /bin/install -# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag -# AFS /usr/afsws/bin/install, which mishandles nonexistent args -# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" -# ./install, which can be erroneously created by make from ./install.sh. -echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 -echo "configure:1108: checking for a BSD compatible install" >&5 -if test -z "$INSTALL"; then -if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then + +# Extract the first word of "gmake", so it can be a program name with args. +set dummy gmake; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:1185: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_GMAKE'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" - for ac_dir in $PATH; do - # Account for people who put trailing slashes in PATH elements. - case "$ac_dir/" in - /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; - *) - # OSF1 and SCO ODT 3.0 have their own names for install. - # Don't use installbsd from OSF since it installs stuff as root - # by default. - for ac_prog in ginstall scoinst install; do - if test -f $ac_dir/$ac_prog; then - if test $ac_prog = install && - grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then - # AIX install. It has an incompatible calling convention. - : - else - ac_cv_path_install="$ac_dir/$ac_prog -c" - break 2 - fi - fi - done - ;; - esac + case "$GMAKE" in + /*) + ac_cv_path_GMAKE="$GMAKE" # Let the user override the test with a path. + ;; + ?:/*) + ac_cv_path_GMAKE="$GMAKE" # Let the user override the test with a dos path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_path_GMAKE="$ac_dir/$ac_word" + break + fi done - IFS="$ac_save_IFS" + IFS="$ac_save_ifs" + test -z "$ac_cv_path_GMAKE" && ac_cv_path_GMAKE="no" + ;; +esac +fi +GMAKE="$ac_cv_path_GMAKE" +if test -n "$GMAKE"; then + echo "$ac_t""$GMAKE" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi +if test "x$GMAKE" = "xno"; then + echo $ac_n "checking whether GNU make is installed""... $ac_c" 1>&6 +echo "configure:1220: checking whether GNU make is installed" >&5 +if eval "test \"`echo '$''{'ac_cv_gmake'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if make --version | grep -q -i gnu; then + ac_cv_gmake="yes" + else + echo "This software needs you to install GNU make to compile properly." + echo "You can get it from http://www.gnu.org/." + exit + fi fi - if test "${ac_cv_path_install+set}" = set; then - INSTALL="$ac_cv_path_install" - else - # As a last resort, use the slow shell script. We don't cache a - # path for INSTALL within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the path is relative. - INSTALL="$ac_install_sh" - fi + +echo "$ac_t""$ac_cv_gmake" 1>&6 + VLC_MAKE="make" +else + VLC_MAKE="gmake" fi -echo "$ac_t""$INSTALL" 1>&6 -# Use test -z because SunOS4 sh mishandles braces in ${var-val}. -# It thinks the first close brace ends the variable substitution. -test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' +ALL_LINGUAS="de fr no ru nl" -test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' +cat >> confdefs.h <> confdefs.h <&6 +echo "configure:1252: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_RANLIB="ranlib" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" +fi +fi +RANLIB="$ac_cv_prog_RANLIB" +if test -n "$RANLIB"; then + echo "$ac_t""$RANLIB" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi -if test x${cross_compiling} != xyes; then - echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 -echo "configure:1163: checking whether byte ordering is bigendian" >&5 -if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then + echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6 +echo "configure:1281: checking for strerror in -lcposix" >&5 +ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_cv_c_bigendian=unknown -# See if sys/param.h defines the BYTE_ORDER macro. + ac_save_LIBS="$LIBS" +LIBS="-lcposix $LIBS" cat > conftest.$ac_ext < -#include -int main() { +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char strerror(); -#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN - bogus endian macros -#endif -; return 0; } -EOF -if { (eval echo configure:1181: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then - rm -rf conftest* - # It does; now see whether it defined to BIG_ENDIAN or not. -cat > conftest.$ac_ext < -#include int main() { - -#if BYTE_ORDER != BIG_ENDIAN - not big endian -#endif +strerror() ; return 0; } EOF -if { (eval echo configure:1196: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1300: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - ac_cv_c_bigendian=yes + eval "ac_cv_lib_$ac_lib_var=yes" else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_c_bigendian=no + eval "ac_cv_lib_$ac_lib_var=no" fi rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIBS="$LIBS -lcposix" else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 + echo "$ac_t""no" 1>&6 fi -rm -f conftest* -if test $ac_cv_c_bigendian = unknown; then -if test "$cross_compiling" = yes; then - { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } + + + +echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 +echo "configure:1323: checking for ANSI C header files" >&5 +if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < +#include +#include +#include EOF -if { (eval echo configure:1229: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null -then - ac_cv_c_bigendian=no +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:1336: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + ac_cv_header_stdc=yes else + echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 - rm -fr conftest* - ac_cv_c_bigendian=yes -fi -rm -fr conftest* -fi - -fi + rm -rf conftest* + ac_cv_header_stdc=no fi +rm -f conftest* -echo "$ac_t""$ac_cv_c_bigendian" 1>&6 -if test $ac_cv_c_bigendian = yes; then - cat >> confdefs.h <<\EOF -#define WORDS_BIGENDIAN 1 +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. +cat > conftest.$ac_ext < EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "memchr" >/dev/null 2>&1; then + : +else + rm -rf conftest* + ac_cv_header_stdc=no +fi +rm -f conftest* fi -else - # Check whether --with-words or --without-words was given. -if test "${with_words+set}" = set; then - withval="$with_words" +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. +cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "free" >/dev/null 2>&1; then : +else + rm -rf conftest* + ac_cv_header_stdc=no fi +rm -f conftest* - case "x$withval" in - xbig) - ac_cv_c_bigendian=yes - ;; - xlittle) - ac_cv_c_bigendian=no - ;; - *) - ac_cv_c_bigendian=unknown - echo $ac_n "checking what the byte order looks to be""... $ac_c" 1>&6 -echo "configure:1269: checking what the byte order looks to be" >&5 - cat >conftest.c <config.log 2>&1 \ - && test -f conftest.o - then - if test `grep -l BIGenDianSyS conftest.o` - then - echo "$ac_t"""big endian"" 1>&6 - ac_cv_c_bigendian=yes - fi - if test `grep -l LiTTleEnDian conftest.o` - then - echo "$ac_t"""little endian"" 1>&6 - ac_cv_c_bigendian=no - fi - fi - fi - if test $ac_cv_c_bigendian = xunknown - then - { echo "configure: error: Could not guess endianness, please use --with-words" 1>&2; exit 1; } - fi - if test $ac_cv_c_bigendian = yes - then - cat >> confdefs.h <<\EOF -#define WORDS_BIGENDIAN 1 -EOF - fi - ;; - esac fi -for ac_func in gettimeofday select strerror strtod strtol -do -echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:1314: checking for $ac_func" >&5 -if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. +if test "$cross_compiling" = yes; then + : else cat > conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char $ac_func(); - -int main() { - -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_$ac_func) || defined (__stub___$ac_func) -choke me -#else -$ac_func(); -#endif +#include +#define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +int main () { int i; for (i = 0; i < 256; i++) +if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); +exit (0); } -; return 0; } EOF -if { (eval echo configure:1342: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_func_$ac_func=yes" +if { (eval echo configure:1403: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +then + : else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_func_$ac_func=no" + rm -fr conftest* + ac_cv_header_stdc=no fi -rm -f conftest* +rm -fr conftest* fi -if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` - cat >> confdefs.h <&6 +if test $ac_cv_header_stdc = yes; then + cat >> confdefs.h <<\EOF +#define STDC_HEADERS 1 EOF - -else - echo "$ac_t""no" 1>&6 + fi -done -for ac_func in setenv putenv -do -echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:1369: checking for $ac_func" >&5 -if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then +echo $ac_n "checking for working const""... $ac_c" 1>&6 +echo "configure:1427: checking for working const" >&5 +if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char $ac_func(); int main() { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_$ac_func) || defined (__stub___$ac_func) -choke me -#else -$ac_func(); -#endif +/* Ultrix mips cc rejects this. */ +typedef int charset[2]; const charset x; +/* SunOS 4.1.1 cc rejects this. */ +char const *const *ccp; +char **p; +/* NEC SVR4.0.2 mips cc rejects this. */ +struct point {int x, y;}; +static struct point const zero = {0,0}; +/* AIX XL C 1.02.0.0 rejects this. + It does not let you subtract one const X* pointer from another in an arm + of an if-expression whose if-part is not a constant expression */ +const char *g = "string"; +ccp = &g + (g ? g-g : 0); +/* HPUX 7.0 cc rejects these. */ +++ccp; +p = (char**) ccp; +ccp = (char const *const *) p; +{ /* SCO 3.2v4 cc rejects this. */ + char *t; + char const *s = 0 ? (char *) 0 : (char const *) 0; + + *t++ = 0; +} +{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ + int x[] = {25, 17}; + const int *foo = &x[0]; + ++foo; +} +{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ + typedef const int *iptr; + iptr p = 0; + ++p; +} +{ /* AIX XL C 1.02.0.0 rejects this saying + "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ + struct s { int j; const int *ap[3]; }; + struct s *b; b->j = 5; +} +{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ + const int foo = 10; +} ; return 0; } EOF -if { (eval echo configure:1397: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1481: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_func_$ac_func=yes" + ac_cv_c_const=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_func_$ac_func=no" + ac_cv_c_const=no fi rm -f conftest* fi -if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` - cat >> confdefs.h <&6 +if test $ac_cv_c_const = no; then + cat >> confdefs.h <<\EOF +#define const EOF - -else - echo "$ac_t""no" 1>&6 + fi -done -echo $ac_n "checking for connect""... $ac_c" 1>&6 -echo "configure:1422: checking for connect" >&5 -if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then +echo $ac_n "checking for inline""... $ac_c" 1>&6 +echo "configure:1502: checking for inline" >&5 +if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else + ac_cv_c_inline=no +for ac_kw in inline __inline__ __inline; do cat > conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char connect(); int main() { - -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_connect) || defined (__stub___connect) -choke me -#else -connect(); -#endif - +} $ac_kw foo() { ; return 0; } EOF -if { (eval echo configure:1450: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1516: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_func_connect=yes" + ac_cv_c_inline=$ac_kw; break else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_func_connect=no" fi rm -f conftest* +done + fi -if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then - echo "$ac_t""yes" 1>&6 - : -else - echo "$ac_t""no" 1>&6 +echo "$ac_t""$ac_cv_c_inline" 1>&6 +case "$ac_cv_c_inline" in + inline | yes) ;; + no) cat >> confdefs.h <<\EOF +#define inline +EOF + ;; + *) cat >> confdefs.h <&6 -echo "configure:1469: checking for connect in -lsocket" >&5 -ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +echo $ac_n "checking for off_t""... $ac_c" 1>&6 +echo "configure:1542: checking for off_t" >&5 +if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lsocket $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext < +#if STDC_HEADERS +#include +#include +#endif EOF -if { (eval echo configure:1488: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + ac_cv_type_off_t=yes else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + ac_cv_type_off_t=no fi rm -f conftest* -LIBS="$ac_save_LIBS" fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - LIB="${LIB} -lsocket" +echo "$ac_t""$ac_cv_type_off_t" 1>&6 +if test $ac_cv_type_off_t = no; then + cat >> confdefs.h <<\EOF +#define off_t long +EOF + +fi + +echo $ac_n "checking for size_t""... $ac_c" 1>&6 +echo "configure:1575: checking for size_t" >&5 +if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 else - echo "$ac_t""no" 1>&6 + cat > conftest.$ac_ext < +#if STDC_HEADERS +#include +#include +#endif +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then + rm -rf conftest* + ac_cv_type_size_t=yes +else + rm -rf conftest* + ac_cv_type_size_t=no fi +rm -f conftest* +fi +echo "$ac_t""$ac_cv_type_size_t" 1>&6 +if test $ac_cv_type_size_t = no; then + cat >> confdefs.h <<\EOF +#define size_t unsigned +EOF fi -echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 -echo "configure:1512: checking for gethostbyname" >&5 -if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then +# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works +# for constant arguments. Useless! +echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 +echo "configure:1610: checking for working alloca.h" >&5 +if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char gethostbyname(); - +#include int main() { - -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) -choke me -#else -gethostbyname(); -#endif - +char *p = alloca(2 * sizeof(int)); ; return 0; } EOF -if { (eval echo configure:1540: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1622: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - eval "ac_cv_func_gethostbyname=yes" + ac_cv_header_alloca_h=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_func_gethostbyname=no" + ac_cv_header_alloca_h=no fi rm -f conftest* fi -if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then - echo "$ac_t""yes" 1>&6 - : -else - echo "$ac_t""no" 1>&6 +echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 +if test $ac_cv_header_alloca_h = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_ALLOCA_H 1 +EOF - echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 -echo "configure:1559: checking for gethostbyname in -lnsl" >&5 -ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +fi + +echo $ac_n "checking for alloca""... $ac_c" 1>&6 +echo "configure:1643: checking for alloca" >&5 +if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lnsl $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext < +# define alloca _alloca +# else +# if HAVE_ALLOCA_H +# include +# else +# ifdef _AIX + #pragma alloca +# else +# ifndef alloca /* predefined by HP cc +Olibcalls */ +char *alloca (); +# endif +# endif +# endif +# endif +#endif int main() { -gethostbyname() +char *p = (char *) alloca(1); ; return 0; } EOF -if { (eval echo configure:1578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1676: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + ac_cv_func_alloca_works=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + ac_cv_func_alloca_works=no fi rm -f conftest* -LIBS="$ac_save_LIBS" +fi + +echo "$ac_t""$ac_cv_func_alloca_works" 1>&6 +if test $ac_cv_func_alloca_works = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_ALLOCA 1 +EOF fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - LIB="${LIB} -lnsl" + +if test $ac_cv_func_alloca_works = no; then + # The SVR3 libPW and SVR4 libucb both contain incompatible functions + # that cause trouble. Some versions do not even contain alloca or + # contain a buggy version. If you still want to use their alloca, + # use ar to extract alloca.o from them instead of compiling alloca.c. + ALLOCA=alloca.${ac_objext} + cat >> confdefs.h <<\EOF +#define C_ALLOCA 1 +EOF + + +echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 +echo "configure:1708: checking whether alloca needs Cray hooks" >&5 +if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 else - echo "$ac_t""no" 1>&6 -fi + cat > conftest.$ac_ext <&5 | + egrep "webecray" >/dev/null 2>&1; then + rm -rf conftest* + ac_cv_os_cray=yes +else + rm -rf conftest* + ac_cv_os_cray=no +fi +rm -f conftest* fi -echo $ac_n "checking for nanosleep""... $ac_c" 1>&6 -echo "configure:1602: checking for nanosleep" >&5 -if eval "test \"`echo '$''{'ac_cv_func_nanosleep'+set}'`\" = set"; then +echo "$ac_t""$ac_cv_os_cray" 1>&6 +if test $ac_cv_os_cray = yes; then +for ac_func in _getb67 GETB67 getb67; do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:1738: checking for $ac_func" >&5 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < /* Override any gcc2 internal prototype to avoid an error. */ /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ -char nanosleep(); +char $ac_func(); int main() { /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ -#if defined (__stub_nanosleep) || defined (__stub___nanosleep) +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -nanosleep(); +$ac_func(); #endif ; return 0; } EOF -if { (eval echo configure:1630: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1766: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - eval "ac_cv_func_nanosleep=yes" + eval "ac_cv_func_$ac_func=yes" else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_func_nanosleep=no" + eval "ac_cv_func_$ac_func=no" fi rm -f conftest* fi -if eval "test \"`echo '$ac_cv_func_'nanosleep`\" = yes"; then +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then echo "$ac_t""yes" 1>&6 - : + cat >> confdefs.h <&6 +fi - echo $ac_n "checking for nanosleep in -lrt""... $ac_c" 1>&6 -echo "configure:1649: checking for nanosleep in -lrt" >&5 -ac_lib_var=`echo rt'_'nanosleep | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +done +fi + +echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 +echo "configure:1793: checking stack direction for C alloca" >&5 +if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lrt $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext < addr) ? 1 : -1; +} +main () +{ + exit (find_stack_direction() < 0); +} EOF -if { (eval echo configure:1668: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" +if { (eval echo configure:1820: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +then + ac_cv_c_stack_direction=1 else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + rm -fr conftest* + ac_cv_c_stack_direction=-1 +fi +rm -fr conftest* fi -rm -f conftest* -LIBS="$ac_save_LIBS" fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - LIB="${LIB} -lrt" -else - echo "$ac_t""no" 1>&6 - echo $ac_n "checking for nanosleep in -lposix4""... $ac_c" 1>&6 -echo "configure:1688: checking for nanosleep in -lposix4" >&5 -ac_lib_var=`echo posix4'_'nanosleep | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 +cat >> confdefs.h <&6 +echo "configure:1845: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lposix4 $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext < EOF -if { (eval echo configure:1707: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:1855: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + eval "ac_cv_header_$ac_safe=yes" else + echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* -LIBS="$ac_save_LIBS" - fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 - LIB="${LIB} -lposix4" + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 fi +done - -fi - - -fi - -for ac_func in usleep +for ac_func in getpagesize do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:1736: checking for $ac_func" >&5 +echo "configure:1884: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1912: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -1784,144 +1932,249 @@ else fi done -echo $ac_n "checking for inet_aton""... $ac_c" 1>&6 -echo "configure:1789: checking for inet_aton" >&5 -if eval "test \"`echo '$''{'ac_cv_func_inet_aton'+set}'`\" = set"; then +echo $ac_n "checking for working mmap""... $ac_c" 1>&6 +echo "configure:1937: checking for working mmap" >&5 +if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 +else + if test "$cross_compiling" = yes; then + ac_cv_func_mmap_fixed_mapped=no else cat > conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char inet_aton(); -int main() { +/* Thanks to Mike Haertel and Jim Avera for this test. + Here is a matrix of mmap possibilities: + mmap private not fixed + mmap private fixed at somewhere currently unmapped + mmap private fixed at somewhere already mapped + mmap shared not fixed + mmap shared fixed at somewhere currently unmapped + mmap shared fixed at somewhere already mapped + For private mappings, we should verify that changes cannot be read() + back from the file, nor mmap's back from the file at a different + address. (There have been systems where private was not correctly + implemented like the infamous i386 svr4.0, and systems where the + VM page cache was not coherent with the filesystem buffer cache + like early versions of FreeBSD and possibly contemporary NetBSD.) + For shared mappings, we should conversely verify that changes get + propogated back to all the places they're supposed to be. -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_inet_aton) || defined (__stub___inet_aton) -choke me + Grep wants private fixed already mapped. + The main things grep needs to know about mmap are: + * does it exist and is it safe to write into the mmap'd area + * how to use it (BSD variants) */ +#include +#include +#include + +/* This mess was copied from the GNU getpagesize.h. */ +#ifndef HAVE_GETPAGESIZE +# ifdef HAVE_UNISTD_H +# include +# endif + +/* Assume that all systems that can run configure have sys/param.h. */ +# ifndef HAVE_SYS_PARAM_H +# define HAVE_SYS_PARAM_H 1 +# endif + +# ifdef _SC_PAGESIZE +# define getpagesize() sysconf(_SC_PAGESIZE) +# else /* no _SC_PAGESIZE */ +# ifdef HAVE_SYS_PARAM_H +# include +# ifdef EXEC_PAGESIZE +# define getpagesize() EXEC_PAGESIZE +# else /* no EXEC_PAGESIZE */ +# ifdef NBPG +# define getpagesize() NBPG * CLSIZE +# ifndef CLSIZE +# define CLSIZE 1 +# endif /* no CLSIZE */ +# else /* no NBPG */ +# ifdef NBPC +# define getpagesize() NBPC +# else /* no NBPC */ +# ifdef PAGESIZE +# define getpagesize() PAGESIZE +# endif /* PAGESIZE */ +# endif /* no NBPC */ +# endif /* no NBPG */ +# endif /* no EXEC_PAGESIZE */ +# else /* no HAVE_SYS_PARAM_H */ +# define getpagesize() 8192 /* punt totally */ +# endif /* no HAVE_SYS_PARAM_H */ +# endif /* no _SC_PAGESIZE */ + +#endif /* no HAVE_GETPAGESIZE */ + +#ifdef __cplusplus +extern "C" { void *malloc(unsigned); } #else -inet_aton(); +char *malloc(); #endif -; return 0; } +int +main() +{ + char *data, *data2, *data3; + int i, pagesize; + int fd; + + pagesize = getpagesize(); + + /* + * First, make a file with some known garbage in it. + */ + data = malloc(pagesize); + if (!data) + exit(1); + for (i = 0; i < pagesize; ++i) + *(data + i) = rand(); + umask(0); + fd = creat("conftestmmap", 0600); + if (fd < 0) + exit(1); + if (write(fd, data, pagesize) != pagesize) + exit(1); + close(fd); + + /* + * Next, try to mmap the file at a fixed address which + * already has something else allocated at it. If we can, + * also make sure that we see the same garbage. + */ + fd = open("conftestmmap", O_RDWR); + if (fd < 0) + exit(1); + data2 = malloc(2 * pagesize); + if (!data2) + exit(1); + data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); + if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, + MAP_PRIVATE | MAP_FIXED, fd, 0L)) + exit(1); + for (i = 0; i < pagesize; ++i) + if (*(data + i) != *(data2 + i)) + exit(1); + + /* + * Finally, make sure that changes to the mapped area + * do not percolate back to the file as seen by read(). + * (This is a bug on some variants of i386 svr4.0.) + */ + for (i = 0; i < pagesize; ++i) + *(data2 + i) = *(data2 + i) + 1; + data3 = malloc(pagesize); + if (!data3) + exit(1); + if (read(fd, data3, pagesize) != pagesize) + exit(1); + for (i = 0; i < pagesize; ++i) + if (*(data + i) != *(data3 + i)) + exit(1); + close(fd); + unlink("conftestmmap"); + exit(0); +} + EOF -if { (eval echo configure:1817: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_func_inet_aton=yes" +if { (eval echo configure:2085: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +then + ac_cv_func_mmap_fixed_mapped=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_func_inet_aton=no" + rm -fr conftest* + ac_cv_func_mmap_fixed_mapped=no fi -rm -f conftest* +rm -fr conftest* fi -if eval "test \"`echo '$ac_cv_func_'inet_aton`\" = yes"; then - echo "$ac_t""yes" 1>&6 - : -else - echo "$ac_t""no" 1>&6 +fi - echo $ac_n "checking for inet_aton in -lresolv""... $ac_c" 1>&6 -echo "configure:1836: checking for inet_aton in -lresolv" >&5 -ac_lib_var=`echo resolv'_'inet_aton | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 +if test $ac_cv_func_mmap_fixed_mapped = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_MMAP 1 +EOF + +fi + + + echo $ac_n "checking whether we are using the GNU C Library 2.1 or newer""... $ac_c" 1>&6 +echo "configure:2109: checking whether we are using the GNU C Library 2.1 or newer" >&5 +if eval "test \"`echo '$''{'ac_cv_gnu_library_2_1'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lresolv $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext < +#ifdef __GNU_LIBRARY__ + #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2) + Lucky GNU user + #endif +#endif + EOF -if { (eval echo configure:1855: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "Lucky GNU user" >/dev/null 2>&1; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + ac_cv_gnu_library_2_1=yes else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + ac_cv_gnu_library_2_1=no fi rm -f conftest* -LIBS="$ac_save_LIBS" + + fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - LIB="${LIB} -lresolv" -else - echo "$ac_t""no" 1>&6 -fi - -fi +echo "$ac_t""$ac_cv_gnu_library_2_1" 1>&6 + + GLIBC21="$ac_cv_gnu_library_2_1" + -for ac_func in vasprintf + + for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h stddef.h \ +stdlib.h string.h unistd.h sys/param.h do -echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:1881: checking for $ac_func" >&5 -if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:2150: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char $ac_func(); - -int main() { - -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_$ac_func) || defined (__stub___$ac_func) -choke me -#else -$ac_func(); -#endif - -; return 0; } +#include <$ac_hdr> EOF -if { (eval echo configure:1909: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:2160: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then rm -rf conftest* - eval "ac_cv_func_$ac_func=yes" + eval "ac_cv_header_$ac_safe=yes" else + echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_func_$ac_func=no" + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* fi - -if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 - ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` cat >> confdefs.h <&6 -echo "configure:1936: checking for $ac_func" >&5 +echo "configure:2191: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2219: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -1984,231 +2239,258 @@ else fi done -for ac_func in memalign valloc -do -echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:1991: checking for $ac_func" >&5 -if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + + + + # Check whether --with-libiconv-prefix or --without-libiconv-prefix was given. +if test "${with_libiconv_prefix+set}" = set; then + withval="$with_libiconv_prefix" + + for dir in `echo "$withval" | tr : ' '`; do + if test -d $dir/include; then CPPFLAGS="$CPPFLAGS -I$dir/include"; fi + if test -d $dir/lib; then LDFLAGS="$LDFLAGS -L$dir/lib"; fi + done + +fi + + + echo $ac_n "checking for iconv""... $ac_c" 1>&6 +echo "configure:2259: checking for iconv" >&5 +if eval "test \"`echo '$''{'am_cv_func_iconv'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char $ac_func(); - +#include +#include int main() { - -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_$ac_func) || defined (__stub___$ac_func) -choke me -#else -$ac_func(); -#endif - +iconv_t cd = iconv_open("",""); + iconv(cd,NULL,NULL,NULL,NULL); + iconv_close(cd); ; return 0; } EOF -if { (eval echo configure:2019: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2277: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - eval "ac_cv_func_$ac_func=yes" + am_cv_func_iconv=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_func_$ac_func=no" fi rm -f conftest* -fi - -if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` - cat >> confdefs.h < conftest.$ac_ext < +#include +int main() { +iconv_t cd = iconv_open("",""); + iconv(cd,NULL,NULL,NULL,NULL); + iconv_close(cd); +; return 0; } EOF - +if { (eval echo configure:2299: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + am_cv_lib_iconv=yes + am_cv_func_iconv=yes else - echo "$ac_t""no" 1>&6 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 +fi +rm -f conftest* + LIBS="$am_save_LIBS" + fi + fi -done +echo "$ac_t""$am_cv_func_iconv" 1>&6 + if test "$am_cv_func_iconv" = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_ICONV 1 +EOF -for ac_func in sigrelse -do -echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:2047: checking for $ac_func" >&5 -if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "checking for iconv declaration""... $ac_c" 1>&6 +echo "configure:2320: checking for iconv declaration" >&5 + if eval "test \"`echo '$''{'am_cv_proto_iconv'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char $ac_func(); - -int main() { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_$ac_func) || defined (__stub___$ac_func) -choke me +#include +#include +extern +#ifdef __cplusplus +"C" +#endif +#if defined(__STDC__) || defined(__cplusplus) +size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft); #else -$ac_func(); +size_t iconv(); #endif +int main() { + ; return 0; } EOF -if { (eval echo configure:2075: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2345: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_func_$ac_func=yes" + am_cv_proto_iconv_arg1="" else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_func_$ac_func=no" + am_cv_proto_iconv_arg1="const" fi rm -f conftest* + am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);" fi -if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` - cat >> confdefs.h <&6 + cat >> confdefs.h <&6 -fi -done + fi + LIBICONV= + if test "$am_cv_lib_iconv" = yes; then + LIBICONV="-liconv" + fi + -NEED_GETOPT=0 -echo $ac_n "checking for getopt_long""... $ac_c" 1>&6 -echo "configure:2102: checking for getopt_long" >&5 -if eval "test \"`echo '$''{'ac_cv_func_getopt_long'+set}'`\" = set"; then + + echo $ac_n "checking for nl_langinfo and CODESET""... $ac_c" 1>&6 +echo "configure:2374: checking for nl_langinfo and CODESET" >&5 +if eval "test \"`echo '$''{'am_cv_langinfo_codeset'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char getopt_long(); - +#include int main() { - -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_getopt_long) || defined (__stub___getopt_long) -choke me -#else -getopt_long(); -#endif - +char* cs = nl_langinfo(CODESET); ; return 0; } EOF -if { (eval echo configure:2130: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2386: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - eval "ac_cv_func_getopt_long=yes" + am_cv_langinfo_codeset=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_func_getopt_long=no" + am_cv_langinfo_codeset=no fi rm -f conftest* + fi -if eval "test \"`echo '$ac_cv_func_'getopt_long`\" = yes"; then - echo "$ac_t""yes" 1>&6 - cat >> confdefs.h <<\EOF -#define HAVE_GETOPT_LONG 1 +echo "$ac_t""$am_cv_langinfo_codeset" 1>&6 + if test $am_cv_langinfo_codeset = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_LANGINFO_CODESET 1 EOF -else - echo "$ac_t""no" 1>&6 - # FreeBSD has a gnugetopt library for this: - echo $ac_n "checking for getopt_long in -lgnugetopt""... $ac_c" 1>&6 -echo "configure:2152: checking for getopt_long in -lgnugetopt" >&5 -ac_lib_var=`echo gnugetopt'_'getopt_long | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + fi + + if test $ac_cv_header_locale_h = yes; then + echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6 +echo "configure:2409: checking for LC_MESSAGES" >&5 +if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lgnugetopt $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext < int main() { -getopt_long() +return LC_MESSAGES ; return 0; } EOF -if { (eval echo configure:2171: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2421: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + am_cv_val_LC_MESSAGES=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + am_cv_val_LC_MESSAGES=no fi rm -f conftest* -LIBS="$ac_save_LIBS" - fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - cat >> confdefs.h <<\EOF -#define HAVE_GETOPT_LONG 1 + +echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6 + if test $am_cv_val_LC_MESSAGES = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_LC_MESSAGES 1 EOF - LIB="${LIB} -lgnugetopt" + + fi + fi + echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6 +echo "configure:2442: checking whether NLS is requested" >&5 + # Check whether --enable-nls or --disable-nls was given. +if test "${enable_nls+set}" = set; then + enableval="$enable_nls" + USE_NLS=$enableval else - echo "$ac_t""no" 1>&6 -NEED_GETOPT=1 + USE_NLS=yes fi + echo "$ac_t""$USE_NLS" 1>&6 + + + BUILD_INCLUDED_LIBINTL=no + USE_INCLUDED_LIBINTL=no + INTLLIBS= + + if test "$USE_NLS" = "yes"; then + cat >> confdefs.h <<\EOF +#define ENABLE_NLS 1 +EOF + + echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6 +echo "configure:2464: checking whether included gettext is requested" >&5 + # Check whether --with-included-gettext or --without-included-gettext was given. +if test "${with_included_gettext+set}" = set; then + withval="$with_included_gettext" + nls_cv_force_use_gnu_gettext=$withval +else + nls_cv_force_use_gnu_gettext=no fi + echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6 -for ac_hdr in unistd.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:2202: checking for $ac_hdr" >&5 + nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" + if test "$nls_cv_force_use_gnu_gettext" != "yes"; then + CATOBJEXT=NONE + + + + + ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for libintl.h""... $ac_c" 1>&6 +echo "configure:2484: checking for libintl.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < +#include EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2212: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:2494: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -2224,25 +2506,92 @@ rm -f conftest* fi if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 +echo "configure:2511: checking for GNU gettext in libc" >&5 +if eval "test \"`echo '$''{'gt_cv_func_gnugettext1_libc'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +extern int _nl_msg_cat_cntr; +int main() { +bindtextdomain ("", ""); +return (int) gettext ("") + _nl_msg_cat_cntr +; return 0; } EOF - +if { (eval echo configure:2525: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + gt_cv_func_gnugettext1_libc=yes else - echo "$ac_t""no" 1>&6 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + gt_cv_func_gnugettext1_libc=no +fi +rm -f conftest* fi -done -for ac_func in getpagesize +echo "$ac_t""$gt_cv_func_gnugettext1_libc" 1>&6 + + if test "$gt_cv_func_gnugettext1_libc" != "yes"; then + echo $ac_n "checking for GNU gettext in libintl""... $ac_c" 1>&6 +echo "configure:2541: checking for GNU gettext in libintl" >&5 +if eval "test \"`echo '$''{'gt_cv_func_gnugettext1_libintl'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + gt_save_LIBS="$LIBS" + LIBS="$LIBS -lintl $LIBICONV" + cat > conftest.$ac_ext < +extern int _nl_msg_cat_cntr; +int main() { +bindtextdomain ("", ""); +return (int) gettext ("") + _nl_msg_cat_cntr +; return 0; } +EOF +if { (eval echo configure:2557: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + gt_cv_func_gnugettext1_libintl=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + gt_cv_func_gnugettext1_libintl=no +fi +rm -f conftest* + LIBS="$gt_save_LIBS" +fi + +echo "$ac_t""$gt_cv_func_gnugettext1_libintl" 1>&6 + fi + + if test "$gt_cv_func_gnugettext1_libc" = "yes" \ + || { test "$gt_cv_func_gnugettext1_libintl" = "yes" \ + && test "$PACKAGE" != gettext; }; then + cat >> confdefs.h <<\EOF +#define HAVE_GETTEXT 1 +EOF + + + if test "$gt_cv_func_gnugettext1_libintl" = "yes"; then + INTLLIBS="-lintl $LIBICONV" + fi + + gt_save_LIBS="$LIBS" + LIBS="$LIBS $INTLLIBS" + for ac_func in dcgettext do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:2241: checking for $ac_func" >&5 +echo "configure:2590: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -2289,1797 +2638,4114 @@ else fi done -echo $ac_n "checking for working mmap""... $ac_c" 1>&6 -echo "configure:2294: checking for working mmap" >&5 -if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then + LIBS="$gt_save_LIBS" + + # Extract the first word of "msgfmt", so it can be a program name with args. +set dummy msgfmt; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:2647: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - if test "$cross_compiling" = yes; then - ac_cv_func_mmap_fixed_mapped=no + case "$MSGFMT" in + /*) + ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1; then + ac_cv_path_MSGFMT="$ac_dir/$ac_word" + break + fi + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":" + ;; +esac +fi +MSGFMT="$ac_cv_path_MSGFMT" +if test "$MSGFMT" != ":"; then + echo "$ac_t""$MSGFMT" 1>&6 else - cat > conftest.$ac_ext <&6 +fi -/* Thanks to Mike Haertel and Jim Avera for this test. - Here is a matrix of mmap possibilities: - mmap private not fixed - mmap private fixed at somewhere currently unmapped - mmap private fixed at somewhere already mapped - mmap shared not fixed - mmap shared fixed at somewhere currently unmapped - mmap shared fixed at somewhere already mapped - For private mappings, we should verify that changes cannot be read() - back from the file, nor mmap's back from the file at a different - address. (There have been systems where private was not correctly - implemented like the infamous i386 svr4.0, and systems where the - VM page cache was not coherent with the filesystem buffer cache - like early versions of FreeBSD and possibly contemporary NetBSD.) - For shared mappings, we should conversely verify that changes get - propogated back to all the places they're supposed to be. + # Extract the first word of "gmsgfmt", so it can be a program name with args. +set dummy gmsgfmt; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:2681: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + case "$GMSGFMT" in + /*) + ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. + ;; + ?:/*) + ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_path_GMSGFMT="$ac_dir/$ac_word" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" + ;; +esac +fi +GMSGFMT="$ac_cv_path_GMSGFMT" +if test -n "$GMSGFMT"; then + echo "$ac_t""$GMSGFMT" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi - Grep wants private fixed already mapped. - The main things grep needs to know about mmap are: - * does it exist and is it safe to write into the mmap'd area - * how to use it (BSD variants) */ -#include -#include -#include -/* This mess was copied from the GNU getpagesize.h. */ -#ifndef HAVE_GETPAGESIZE -# ifdef HAVE_UNISTD_H -# include -# endif + # Extract the first word of "xgettext", so it can be a program name with args. +set dummy xgettext; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:2718: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + case "$XGETTEXT" in + /*) + ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + if $ac_dir/$ac_word --omit-header /dev/null >/dev/null 2>&1; then + ac_cv_path_XGETTEXT="$ac_dir/$ac_word" + break + fi + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" + ;; +esac +fi +XGETTEXT="$ac_cv_path_XGETTEXT" +if test "$XGETTEXT" != ":"; then + echo "$ac_t""$XGETTEXT" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi -/* Assume that all systems that can run configure have sys/param.h. */ -# ifndef HAVE_SYS_PARAM_H -# define HAVE_SYS_PARAM_H 1 -# endif -# ifdef _SC_PAGESIZE -# define getpagesize() sysconf(_SC_PAGESIZE) -# else /* no _SC_PAGESIZE */ -# ifdef HAVE_SYS_PARAM_H -# include -# ifdef EXEC_PAGESIZE -# define getpagesize() EXEC_PAGESIZE -# else /* no EXEC_PAGESIZE */ -# ifdef NBPG -# define getpagesize() NBPG * CLSIZE -# ifndef CLSIZE -# define CLSIZE 1 -# endif /* no CLSIZE */ -# else /* no NBPG */ -# ifdef NBPC -# define getpagesize() NBPC -# else /* no NBPC */ -# ifdef PAGESIZE -# define getpagesize() PAGESIZE -# endif /* PAGESIZE */ -# endif /* no NBPC */ -# endif /* no NBPG */ -# endif /* no EXEC_PAGESIZE */ -# else /* no HAVE_SYS_PARAM_H */ -# define getpagesize() 8192 /* punt totally */ -# endif /* no HAVE_SYS_PARAM_H */ -# endif /* no _SC_PAGESIZE */ + CATOBJEXT=.gmo + fi + +else + echo "$ac_t""no" 1>&6 +fi -#endif /* no HAVE_GETPAGESIZE */ -#ifdef __cplusplus -extern "C" { void *malloc(unsigned); } -#else -char *malloc(); -#endif + if test "$CATOBJEXT" = "NONE"; then + nls_cv_use_gnu_gettext=yes + fi + fi -int -main() -{ - char *data, *data2, *data3; - int i, pagesize; - int fd; + if test "$nls_cv_use_gnu_gettext" = "yes"; then + INTLOBJS="\$(GETTOBJS)" + # Extract the first word of "msgfmt", so it can be a program name with args. +set dummy msgfmt; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:2768: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + case "$MSGFMT" in + /*) + ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1; then + ac_cv_path_MSGFMT="$ac_dir/$ac_word" + break + fi + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":" + ;; +esac +fi +MSGFMT="$ac_cv_path_MSGFMT" +if test "$MSGFMT" != ":"; then + echo "$ac_t""$MSGFMT" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi - pagesize = getpagesize(); + # Extract the first word of "gmsgfmt", so it can be a program name with args. +set dummy gmsgfmt; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:2802: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + case "$GMSGFMT" in + /*) + ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. + ;; + ?:/*) + ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_path_GMSGFMT="$ac_dir/$ac_word" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" + ;; +esac +fi +GMSGFMT="$ac_cv_path_GMSGFMT" +if test -n "$GMSGFMT"; then + echo "$ac_t""$GMSGFMT" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi - /* - * First, make a file with some known garbage in it. - */ - data = malloc(pagesize); - if (!data) - exit(1); - for (i = 0; i < pagesize; ++i) - *(data + i) = rand(); - umask(0); - fd = creat("conftestmmap", 0600); - if (fd < 0) - exit(1); - if (write(fd, data, pagesize) != pagesize) - exit(1); - close(fd); + # Extract the first word of "xgettext", so it can be a program name with args. +set dummy xgettext; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:2838: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + case "$XGETTEXT" in + /*) + ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + if $ac_dir/$ac_word --omit-header /dev/null >/dev/null 2>&1; then + ac_cv_path_XGETTEXT="$ac_dir/$ac_word" + break + fi + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" + ;; +esac +fi +XGETTEXT="$ac_cv_path_XGETTEXT" +if test "$XGETTEXT" != ":"; then + echo "$ac_t""$XGETTEXT" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi - /* - * Next, try to mmap the file at a fixed address which - * already has something else allocated at it. If we can, - * also make sure that we see the same garbage. - */ - fd = open("conftestmmap", O_RDWR); - if (fd < 0) - exit(1); - data2 = malloc(2 * pagesize); - if (!data2) - exit(1); - data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); - if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, - MAP_PRIVATE | MAP_FIXED, fd, 0L)) - exit(1); - for (i = 0; i < pagesize; ++i) - if (*(data + i) != *(data2 + i)) - exit(1); + + BUILD_INCLUDED_LIBINTL=yes + USE_INCLUDED_LIBINTL=yes + CATOBJEXT=.gmo + INTLLIBS="\$(top_builddir)/intl/libintl.a $LIBICONV" + LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'` + fi - /* - * Finally, make sure that changes to the mapped area - * do not percolate back to the file as seen by read(). - * (This is a bug on some variants of i386 svr4.0.) - */ - for (i = 0; i < pagesize; ++i) - *(data2 + i) = *(data2 + i) + 1; - data3 = malloc(pagesize); - if (!data3) - exit(1); - if (read(fd, data3, pagesize) != pagesize) - exit(1); - for (i = 0; i < pagesize; ++i) - if (*(data + i) != *(data3 + i)) - exit(1); - close(fd); - unlink("conftestmmap"); - exit(0); -} + if test "$GMSGFMT" != ":"; then + if $GMSGFMT --statistics /dev/null >/dev/null 2>&1; then + : ; + else + echo "$ac_t""found msgfmt program is not GNU msgfmt; ignore it" 1>&6 + GMSGFMT=":" + fi + fi + + if test "$XGETTEXT" != ":"; then + if $XGETTEXT --omit-header /dev/null >/dev/null 2>&1; then + : ; + else + echo "$ac_t""found xgettext program is not GNU xgettext; ignore it" 1>&6 + XGETTEXT=":" + fi + fi + + POSUB=po + fi + + + + if test "$PACKAGE" = gettext; then + BUILD_INCLUDED_LIBINTL=yes + fi + + for ac_prog in bison +do +# Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:2909: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_prog_INTLBISON'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$INTLBISON"; then + ac_cv_prog_INTLBISON="$INTLBISON" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_INTLBISON="$ac_prog" + break + fi + done + IFS="$ac_save_ifs" +fi +fi +INTLBISON="$ac_cv_prog_INTLBISON" +if test -n "$INTLBISON"; then + echo "$ac_t""$INTLBISON" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +test -n "$INTLBISON" && break +done + + if test -z "$INTLBISON"; then + ac_verc_fail=yes + else + echo $ac_n "checking version of bison""... $ac_c" 1>&6 +echo "configure:2942: checking version of bison" >&5 + ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'` + case $ac_prog_version in + '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;; + 1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*) + ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;; + *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;; + esac + echo "$ac_t""$ac_prog_version" 1>&6 + fi + if test $ac_verc_fail = yes; then + INTLBISON=: + fi + + for lang in $ALL_LINGUAS; do + GMOFILES="$GMOFILES $lang.gmo" + POFILES="$POFILES $lang.po" + done + + + + + + + + + + + + nls_cv_header_intl= + nls_cv_header_libgt= + + DATADIRNAME=share + + + INSTOBJEXT=.mo + + + GENCAT=gencat + + + + if test "x$CATOBJEXT" != "x"; then + if test "x$ALL_LINGUAS" = "x"; then + LINGUAS= + else + echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6 +echo "configure:2989: checking for catalogs to be installed" >&5 + NEW_LINGUAS= + for presentlang in $ALL_LINGUAS; do + useit=no + for desiredlang in ${LINGUAS-$ALL_LINGUAS}; do + # Use the presentlang catalog if desiredlang is + # a. equal to presentlang, or + # b. a variant of presentlang (because in this case, + # presentlang can be used as a fallback for messages + # which are not translated in the desiredlang catalog). + case "$desiredlang" in + "$presentlang"*) useit=yes;; + esac + done + if test $useit = yes; then + NEW_LINGUAS="$NEW_LINGUAS $presentlang" + fi + done + LINGUAS=$NEW_LINGUAS + echo "$ac_t""$LINGUAS" 1>&6 + fi + + if test -n "$LINGUAS"; then + for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done + fi + fi + + MKINSTALLDIRS= + if test -n "$ac_aux_dir"; then + MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" + fi + if test -z "$MKINSTALLDIRS"; then + MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" + fi + + + INTL_LIBTOOL_SUFFIX_PREFIX= + + + +# Find a good install program. We prefer a C program (faster), +# so one script is as good as another. But avoid the broken or +# incompatible versions: +# SysV /etc/install, /usr/sbin/install +# SunOS /usr/etc/install +# IRIX /sbin/install +# AIX /bin/install +# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag +# AFS /usr/afsws/bin/install, which mishandles nonexistent args +# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" +# ./install, which can be erroneously created by make from ./install.sh. +echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 +echo "configure:3041: checking for a BSD compatible install" >&5 +if test -z "$INSTALL"; then +if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" + for ac_dir in $PATH; do + # Account for people who put trailing slashes in PATH elements. + case "$ac_dir/" in + /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; + *) + # OSF1 and SCO ODT 3.0 have their own names for install. + # Don't use installbsd from OSF since it installs stuff as root + # by default. + for ac_prog in ginstall scoinst install; do + if test -f $ac_dir/$ac_prog; then + if test $ac_prog = install && + grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then + # AIX install. It has an incompatible calling convention. + : + else + ac_cv_path_install="$ac_dir/$ac_prog -c" + break 2 + fi + fi + done + ;; + esac + done + IFS="$ac_save_IFS" + +fi + if test "${ac_cv_path_install+set}" = set; then + INSTALL="$ac_cv_path_install" + else + # As a last resort, use the slow shell script. We don't cache a + # path for INSTALL within a source directory, because that will + # break other packages using the cache if that directory is + # removed, or if the path is relative. + INSTALL="$ac_install_sh" + fi +fi +echo "$ac_t""$INSTALL" 1>&6 + +# Use test -z because SunOS4 sh mishandles braces in ${var-val}. +# It thinks the first close brace ends the variable substitution. +test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' + +test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' + +test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' + + +case x"${target_os}" in + x) + SYS=unknown + ;; + xlinux*) + SYS=linux + ;; + xbsdi*) + SYS=bsdi + ;; + xdarwin*) + SYS=darwin + ;; + x*mingw32*) + SYS=mingw32 + # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args. +set dummy ${ac_tool_prefix}windres; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:3112: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$WINDRES"; then + ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_WINDRES="${ac_tool_prefix}windres" + break + fi + done + IFS="$ac_save_ifs" +fi +fi +WINDRES="$ac_cv_prog_WINDRES" +if test -n "$WINDRES"; then + echo "$ac_t""$WINDRES" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + + +if test -z "$ac_cv_prog_WINDRES"; then +if test -n "$ac_tool_prefix"; then + # Extract the first word of "windres", so it can be a program name with args. +set dummy windres; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:3144: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$WINDRES"; then + ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_WINDRES="windres" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_prog_WINDRES" && ac_cv_prog_WINDRES=":" +fi +fi +WINDRES="$ac_cv_prog_WINDRES" +if test -n "$WINDRES"; then + echo "$ac_t""$WINDRES" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +else + WINDRES=":" +fi +fi + + LIB_IPV4="${LIB_IPV4} -lws2_32" + LIB_RC="${LIB_RC} -lws2_32" + ;; + x*nto*) + SYS=nto + LIB_X11="${LIB_X11} -lsocket" + LIB_XVIDEO="${LIB_XVIDEO} -lsocket" + ;; + xbeos) + SYS=beos + LIB_IPV4="${LIB_IPV4} -lbind" + LIB_BEOS="${LIB_BEOS} -lbe -lgame -lroot -ltracker" + PLDFLAGS="${PLDFLAGS} -nostart" + ;; + x*) + SYS=${target_os} + ;; +esac + +for ac_func in gettimeofday select strerror strtod strtol isatty +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:3198: checking for $ac_func" >&5 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +choke me +#else +$ac_func(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3226: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` + cat >> confdefs.h <&6 +fi +done + +echo $ac_n "checking for connect""... $ac_c" 1>&6 +echo "configure:3251: checking for connect" >&5 +if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char connect(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_connect) || defined (__stub___connect) +choke me +#else +connect(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3279: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_connect=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_connect=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 + + echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6 +echo "configure:3298: checking for connect in -lsocket" >&5 +ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lsocket $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIB_IPV4="${LIB_IPV4} -lsocket" + LIB_VLC="${LIB_VLC} -lsocket" + +else + echo "$ac_t""no" 1>&6 +fi + +fi + +echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 +echo "configure:3342: checking for gethostbyname" >&5 +if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char gethostbyname(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) +choke me +#else +gethostbyname(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3370: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_gethostbyname=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_gethostbyname=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 + + echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 +echo "configure:3389: checking for gethostbyname in -lnsl" >&5 +ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lnsl $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIB_IPV4="${LIB_IPV4} -lnsl" +else + echo "$ac_t""no" 1>&6 +fi + + +fi + +echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 +echo "configure:3432: checking for gethostbyname" >&5 +if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char gethostbyname(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) +choke me +#else +gethostbyname(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3460: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_gethostbyname=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_gethostbyname=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 + + echo $ac_n "checking for gethostbyname in -lbind""... $ac_c" 1>&6 +echo "configure:3479: checking for gethostbyname in -lbind" >&5 +ac_lib_var=`echo bind'_'gethostbyname | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lbind $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIB_IPV4="${LIB_IPV4} -lbind" +else + echo "$ac_t""no" 1>&6 +fi + + +fi + +echo $ac_n "checking for nanosleep""... $ac_c" 1>&6 +echo "configure:3522: checking for nanosleep" >&5 +if eval "test \"`echo '$''{'ac_cv_func_nanosleep'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char nanosleep(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_nanosleep) || defined (__stub___nanosleep) +choke me +#else +nanosleep(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3550: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_nanosleep=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_nanosleep=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'nanosleep`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 + + echo $ac_n "checking for nanosleep in -lrt""... $ac_c" 1>&6 +echo "configure:3569: checking for nanosleep in -lrt" >&5 +ac_lib_var=`echo rt'_'nanosleep | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lrt $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIB_VLC="${LIB_VLC} -lrt" +else + echo "$ac_t""no" 1>&6 + + echo $ac_n "checking for nanosleep in -lposix4""... $ac_c" 1>&6 +echo "configure:3608: checking for nanosleep in -lposix4" >&5 +ac_lib_var=`echo posix4'_'nanosleep | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lposix4 $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIB_VLC="${LIB_VLC} -lposix4" +else + echo "$ac_t""no" 1>&6 +fi + + +fi + + +fi + +for ac_func in usleep +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:3656: checking for $ac_func" >&5 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +choke me +#else +$ac_func(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3684: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` + cat >> confdefs.h <&6 +fi +done + +echo $ac_n "checking for inet_aton""... $ac_c" 1>&6 +echo "configure:3709: checking for inet_aton" >&5 +if eval "test \"`echo '$''{'ac_cv_func_inet_aton'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char inet_aton(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_inet_aton) || defined (__stub___inet_aton) +choke me +#else +inet_aton(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3737: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_inet_aton=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_inet_aton=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'inet_aton`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 + + echo $ac_n "checking for inet_aton in -lresolv""... $ac_c" 1>&6 +echo "configure:3756: checking for inet_aton in -lresolv" >&5 +ac_lib_var=`echo resolv'_'inet_aton | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lresolv $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIB_VLC="${LIB_IPV4} -lresolv" +else + echo "$ac_t""no" 1>&6 +fi + + +fi + +echo $ac_n "checking for textdomain""... $ac_c" 1>&6 +echo "configure:3799: checking for textdomain" >&5 +if eval "test \"`echo '$''{'ac_cv_func_textdomain'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char textdomain(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_textdomain) || defined (__stub___textdomain) +choke me +#else +textdomain(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_textdomain=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_textdomain=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'textdomain`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 + + echo $ac_n "checking for textdomain in -lintl""... $ac_c" 1>&6 +echo "configure:3846: checking for textdomain in -lintl" >&5 +ac_lib_var=`echo intl'_'textdomain | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lintl $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIB_VLC="${LIB_VLC} -lintl" +else + echo "$ac_t""no" 1>&6 +fi + + +fi + +for ac_func in vasprintf +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:3891: checking for $ac_func" >&5 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +choke me +#else +$ac_func(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3919: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` + cat >> confdefs.h <&6 +fi +done + +for ac_func in swab +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:3946: checking for $ac_func" >&5 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +choke me +#else +$ac_func(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3974: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` + cat >> confdefs.h <&6 +fi +done + +for ac_func in memalign valloc +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:4001: checking for $ac_func" >&5 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +choke me +#else +$ac_func(); +#endif + +; return 0; } +EOF +if { (eval echo configure:4029: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` + cat >> confdefs.h <&6 +fi +done + + +for ac_func in sigrelse +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:4057: checking for $ac_func" >&5 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +choke me +#else +$ac_func(); +#endif + +; return 0; } +EOF +if { (eval echo configure:4085: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` + cat >> confdefs.h <&6 +fi +done + +for ac_func in getpwuid +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:4112: checking for $ac_func" >&5 +if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +choke me +#else +$ac_func(); +#endif + +; return 0; } +EOF +if { (eval echo configure:4140: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` + cat >> confdefs.h <&6 +fi +done + + +NEED_GETOPT=0 +echo $ac_n "checking for getopt_long""... $ac_c" 1>&6 +echo "configure:4167: checking for getopt_long" >&5 +if eval "test \"`echo '$''{'ac_cv_func_getopt_long'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char getopt_long(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_getopt_long) || defined (__stub___getopt_long) +choke me +#else +getopt_long(); +#endif + +; return 0; } +EOF +if { (eval echo configure:4195: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_getopt_long=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_getopt_long=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'getopt_long`\" = yes"; then + echo "$ac_t""yes" 1>&6 + cat >> confdefs.h <<\EOF +#define HAVE_GETOPT_LONG 1 +EOF + +else + echo "$ac_t""no" 1>&6 + # FreeBSD has a gnugetopt library for this: + echo $ac_n "checking for getopt_long in -lgnugetopt""... $ac_c" 1>&6 +echo "configure:4217: checking for getopt_long in -lgnugetopt" >&5 +ac_lib_var=`echo gnugetopt'_'getopt_long | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lgnugetopt $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + cat >> confdefs.h <<\EOF +#define HAVE_GETOPT_LONG 1 +EOF + LIB_VLC="${LIB_VLC} -lgnugetopt" +else + echo "$ac_t""no" 1>&6 +NEED_GETOPT=1 +fi + +fi + + +echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 +echo "configure:4264: checking return type of signal handlers" >&5 +if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +#include +#ifdef signal +#undef signal +#endif +#ifdef __cplusplus +extern "C" void (*signal (int, void (*)(int)))(int); +#else +void (*signal ()) (); +#endif + +int main() { +int i; +; return 0; } +EOF +if { (eval echo configure:4286: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_type_signal=void +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_type_signal=int +fi +rm -f conftest* +fi + +echo "$ac_t""$ac_cv_type_signal" 1>&6 +cat >> confdefs.h <&6 +echo "configure:4305: checking for dlopen in -ldl" >&5 +ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-ldl $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIB_VLC="${LIB_VLC} -ldl" +else + echo "$ac_t""no" 1>&6 +fi + +echo $ac_n "checking for cos in -lm""... $ac_c" 1>&6 +echo "configure:4345: checking for cos in -lm" >&5 +ac_lib_var=`echo m'_'cos | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lm $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIB_IMDCT="${LIB_IMDCT} -lm" + LIB_FILTER_DISTORT="${LIB_FILTER_DISTORT} -lm" +else + echo "$ac_t""no" 1>&6 +fi + +echo $ac_n "checking for pow in -lm""... $ac_c" 1>&6 +echo "configure:4386: checking for pow in -lm" >&5 +ac_lib_var=`echo m'_'pow | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lm $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIB_IMDCT="${LIB_IMDCT} -lm" + LIB_IMDCT3DN="${LIB_IMDCT3DN} -lm" + LIB_IMDCTSSE="${LIB_IMDCTSSE} -lm" + +else + echo "$ac_t""no" 1>&6 +fi + + +THREAD_LIB=error +if test "x${THREAD_LIB}" = xerror; then + echo $ac_n "checking for pthread_attr_init in -lpthread""... $ac_c" 1>&6 +echo "configure:4432: checking for pthread_attr_init in -lpthread" >&5 +ac_lib_var=`echo pthread'_'pthread_attr_init | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lpthread $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + THREAD_LIB="-lpthread" +else + echo "$ac_t""no" 1>&6 +fi + +fi +if test "x${THREAD_LIB}" = xerror; then + echo $ac_n "checking for pthread_attr_init in -lpthreads""... $ac_c" 1>&6 +echo "configure:4474: checking for pthread_attr_init in -lpthreads" >&5 +ac_lib_var=`echo pthreads'_'pthread_attr_init | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lpthreads $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + THREAD_LIB="-lpthreads" +else + echo "$ac_t""no" 1>&6 +fi + +fi +if test "x${THREAD_LIB}" = xerror; then + echo $ac_n "checking for pthread_attr_init in -lc_r""... $ac_c" 1>&6 +echo "configure:4516: checking for pthread_attr_init in -lc_r" >&5 +ac_lib_var=`echo c_r'_'pthread_attr_init | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lc_r $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + THREAD_LIB="-lc_r" +else + echo "$ac_t""no" 1>&6 +fi + +fi +if test "x${THREAD_LIB}" = xerror; then + echo $ac_n "checking for pthread_attr_init""... $ac_c" 1>&6 +echo "configure:4558: checking for pthread_attr_init" >&5 +if eval "test \"`echo '$''{'ac_cv_func_pthread_attr_init'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char pthread_attr_init(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_pthread_attr_init) || defined (__stub___pthread_attr_init) +choke me +#else +pthread_attr_init(); +#endif + +; return 0; } +EOF +if { (eval echo configure:4586: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_pthread_attr_init=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_pthread_attr_init=no" +fi +rm -f conftest* +fi + +if eval "test \"`echo '$ac_cv_func_'pthread_attr_init`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +fi + + THREAD_LIB="" +fi + +echo $ac_n "checking for cthread_fork in -lthreads""... $ac_c" 1>&6 +echo "configure:4609: checking for cthread_fork in -lthreads" >&5 +ac_lib_var=`echo threads'_'cthread_fork | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lthreads $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + THREAD_LIB="-lthreads" +else + echo "$ac_t""no" 1>&6 +fi + + +cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "pthread_cond_t" >/dev/null 2>&1; then + rm -rf conftest* + + cat >> confdefs.h <<\EOF +#define PTHREAD_COND_T_IN_PTHREAD_H 1 +EOF + +fi +rm -f conftest* + +cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "strncasecmp" >/dev/null 2>&1; then + rm -rf conftest* + + cat >> confdefs.h <<\EOF +#define STRNCASECMP_IN_STRINGS_H 1 +EOF + +fi +rm -f conftest* + + +for ac_hdr in getopt.h strings.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:4686: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4696: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 +fi +done + +for ac_hdr in sys/sockio.h fcntl.h sys/time.h sys/times.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:4726: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4736: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 +fi +done + +for ac_hdr in dlfcn.h image.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:4766: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4776: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 +fi +done + +for ac_hdr in arpa/inet.h net/if.h netinet/in.h sys/socket.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:4806: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4816: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 +fi +done + +for ac_hdr in machine/param.h sys/shm.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:4846: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4856: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 +fi +done + + +echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 +echo "configure:4884: checking whether time.h and sys/time.h may both be included" >&5 +if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +#include +#include +int main() { +struct tm *tp; +; return 0; } +EOF +if { (eval echo configure:4898: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_header_time=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_header_time=no +fi +rm -f conftest* +fi + +echo "$ac_t""$ac_cv_header_time" 1>&6 +if test $ac_cv_header_time = yes; then + cat >> confdefs.h <<\EOF +#define TIME_WITH_SYS_TIME 1 +EOF +fi + + +for ac_hdr in cthreads.h pthread.h kernel/scheduler.h kernel/OS.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:4923: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4933: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null + +else + echo "$ac_t""no" 1>&6 +fi +done + + +if test x$SYS != xmingw32 then - ac_cv_func_mmap_fixed_mapped=yes + if test x$x_includes = xNONE; then + x_includes=/usr/X11R6/include + fi + if test x$x_libraries = xNONE; then + x_libraries=/usr/X11R6/lib + fi + saved_CPPFLAGS=$CPPFLAGS + CPPFLAGS="$CPPFLAGS -I$x_includes" + for ac_hdr in X11/extensions/dpms.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:4974: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4984: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" else + echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 - rm -fr conftest* - ac_cv_func_mmap_fixed_mapped=no + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" fi -rm -fr conftest* +rm -f conftest* fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h < conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "DPMSInfo" >/dev/null 2>&1; then + rm -rf conftest* + + cat >> confdefs.h <<\EOF +#define DPMSINFO_IN_DPMS_H 1 +EOF + fi +rm -f conftest* -echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 -if test $ac_cv_func_mmap_fixed_mapped = yes; then - cat >> confdefs.h <<\EOF -#define HAVE_MMAP 1 -EOF + +else + echo "$ac_t""no" 1>&6 +fi +done + CPPFLAGS=$saved_CPPFLAGS fi -echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 -echo "configure:2465: checking return type of signal handlers" >&5 -if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then +echo $ac_n "checking for ntohl in sys/param.h""... $ac_c" 1>&6 +echo "configure:5032: checking for ntohl in sys/param.h" >&5 +if eval "test \"`echo '$''{'ac_cv_c_ntohl_sys_param_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < conftest.$ac_ext < -#include -#ifdef signal -#undef signal -#endif -#ifdef __cplusplus -extern "C" void (*signal (int, void (*)(int)))(int); -#else -void (*signal ()) (); -#endif - +#include int main() { -int i; +void foo() { int meuh; ntohl(meuh); } ; return 0; } EOF -if { (eval echo configure:2487: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5045: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - ac_cv_type_signal=void + ac_cv_c_ntohl_sys_param_h=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_type_signal=int + ac_cv_c_ntohl_sys_param_h=no fi rm -f conftest* fi -echo "$ac_t""$ac_cv_type_signal" 1>&6 -cat >> confdefs.h <&6 +if test x"$ac_cv_c_ntohl_sys_param_h" != x"no"; then + cat >> confdefs.h <<\EOF +#define NTOHL_IN_SYS_PARAM_H 1 EOF +fi -echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 -echo "configure:2506: checking for dlopen in -ldl" >&5 -ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +echo $ac_n "checking if \$CC accepts -finline-limit""... $ac_c" 1>&6 +echo "configure:5066: checking if \$CC accepts -finline-limit" >&5 +if eval "test \"`echo '$''{'ac_cv_c_inline_limit'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-ldl $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5079: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + ac_cv_c_inline_limit=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + ac_cv_c_inline_limit=no fi rm -f conftest* -LIBS="$ac_save_LIBS" +fi +echo "$ac_t""$ac_cv_c_inline_limit" 1>&6 +if test x"$ac_cv_c_inline_limit" != x"no"; then + save_CFLAGS="${save_CFLAGS} -finline-limit-30000" fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - LIB="${LIB} -ldl" + +echo $ac_n "checking if \$CC accepts -Wall -Winline""... $ac_c" 1>&6 +echo "configure:5097: checking if \$CC accepts -Wall -Winline" >&5 +if eval "test \"`echo '$''{'ac_cv_c_Wall_Winline'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 else - echo "$ac_t""no" 1>&6 + CFLAGS="${save_CFLAGS} -Wall -Winline" + cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_c_Wall_Winline=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_c_Wall_Winline=no +fi +rm -f conftest* fi -echo $ac_n "checking for pow in -lm""... $ac_c" 1>&6 -echo "configure:2546: checking for pow in -lm" >&5 -ac_lib_var=`echo m'_'pow | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +echo "$ac_t""$ac_cv_c_Wall_Winline" 1>&6 +if test x"$ac_cv_c_Wall_Winline" != x"no"; then + save_CFLAGS="${save_CFLAGS} -Wall -Winline" +else + echo $ac_n "checking if \$CC accepts -wall -winline""... $ac_c" 1>&6 +echo "configure:5127: checking if \$CC accepts -wall -winline" >&5 +if eval "test \"`echo '$''{'ac_cv_c_wall_winline'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lm $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5140: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + ac_cv_c_wall_winline=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + ac_cv_c_wall_winline=no fi rm -f conftest* -LIBS="$ac_save_LIBS" +fi +echo "$ac_t""$ac_cv_c_wall_winline" 1>&6 + if test x"$ac_cv_c_wall_winline" != x"no"; then + save_CFLAGS="${save_CFLAGS} -wall -winline" + fi fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - LIB_YUV="${LIB_YUV} -lm" + +echo $ac_n "checking if \$CC accepts -pipe""... $ac_c" 1>&6 +echo "configure:5159: checking if \$CC accepts -pipe" >&5 +if eval "test \"`echo '$''{'ac_cv_c_pipe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 else - echo "$ac_t""no" 1>&6 + CFLAGS="${save_CFLAGS} -pipe" + cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_c_pipe=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_c_pipe=no +fi +rm -f conftest* fi +echo "$ac_t""$ac_cv_c_pipe" 1>&6 +if test x"$ac_cv_c_pipe" != x"no"; then + save_CFLAGS="${save_CFLAGS} -pipe" +fi -THREAD_LIB=error -if test "x${THREAD_LIB}" = xerror; then - echo $ac_n "checking for pthread_attr_init in -lpthread""... $ac_c" 1>&6 -echo "configure:2589: checking for pthread_attr_init in -lpthread" >&5 -ac_lib_var=`echo pthread'_'pthread_attr_init | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +echo $ac_n "checking if \$CC accepts -O3""... $ac_c" 1>&6 +echo "configure:5190: checking if \$CC accepts -O3" >&5 +if eval "test \"`echo '$''{'ac_cv_c_o3'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lpthread $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_c_o3=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_c_o3=no +fi +rm -f conftest* +fi + +echo "$ac_t""$ac_cv_c_o3" 1>&6 +if test x"$ac_cv_c_o3" != x"no"; then + CFLAGS_OPTIM="${CFLAGS_OPTIM} -O3" +else + echo $ac_n "checking if \$CC accepts -O2""... $ac_c" 1>&6 +echo "configure:5220: checking if \$CC accepts -O2" >&5 +if eval "test \"`echo '$''{'ac_cv_c_o2'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + CFLAGS="${save_CFLAGS} -O2" + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5233: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + ac_cv_c_o2=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + ac_cv_c_o2=no fi rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - THREAD_LIB="-lpthread" -else - echo "$ac_t""no" 1>&6 fi -fi -if test "x${THREAD_LIB}" = xerror; then - echo $ac_n "checking for pthread_attr_init in -lpthreads""... $ac_c" 1>&6 -echo "configure:2631: checking for pthread_attr_init in -lpthreads" >&5 -ac_lib_var=`echo pthreads'_'pthread_attr_init | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +echo "$ac_t""$ac_cv_c_o2" 1>&6 + if test x"$ac_cv_c_o2" != x"no"; then + CFLAGS_OPTIM="${CFLAGS_OPTIM} -O2" + else + echo $ac_n "checking if \$CC accepts -O""... $ac_c" 1>&6 +echo "configure:5250: checking if \$CC accepts -O" >&5 +if eval "test \"`echo '$''{'ac_cv_c_o'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lpthreads $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5263: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + ac_cv_c_o=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + ac_cv_c_o=no fi rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - THREAD_LIB="-lpthreads" -else - echo "$ac_t""no" 1>&6 fi +echo "$ac_t""$ac_cv_c_o" 1>&6 + if test x"$ac_cv_c_o" != x"no"; then + CFLAGS_OPTIM="${CFLAGS_OPTIM} -O" + fi + fi fi -if test "x${THREAD_LIB}" = xerror; then - echo $ac_n "checking for pthread_attr_init in -lc_r""... $ac_c" 1>&6 -echo "configure:2673: checking for pthread_attr_init in -lc_r" >&5 -ac_lib_var=`echo c_r'_'pthread_attr_init | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + +echo $ac_n "checking if \$CC accepts -ffast-math""... $ac_c" 1>&6 +echo "configure:5283: checking if \$CC accepts -ffast-math" >&5 +if eval "test \"`echo '$''{'ac_cv_c_fast_math'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lc_r $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5296: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + ac_cv_c_fast_math=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + ac_cv_c_fast_math=no fi rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - THREAD_LIB="-lc_r" -else - echo "$ac_t""no" 1>&6 fi +echo "$ac_t""$ac_cv_c_fast_math" 1>&6 +if test x"$ac_cv_c_fast_math" != x"no"; then + CFLAGS_OPTIM="${CFLAGS_OPTIM} -ffast-math" fi -if test "x${THREAD_LIB}" = xerror; then - echo $ac_n "checking for pthread_attr_init""... $ac_c" 1>&6 -echo "configure:2715: checking for pthread_attr_init" >&5 -if eval "test \"`echo '$''{'ac_cv_func_pthread_attr_init'+set}'`\" = set"; then + +echo $ac_n "checking if \$CC accepts -funroll-loops""... $ac_c" 1>&6 +echo "configure:5314: checking if \$CC accepts -funroll-loops" >&5 +if eval "test \"`echo '$''{'ac_cv_c_unroll_loops'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < conftest.$ac_ext < -/* Override any gcc2 internal prototype to avoid an error. */ -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char pthread_attr_init(); int main() { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_pthread_attr_init) || defined (__stub___pthread_attr_init) -choke me -#else -pthread_attr_init(); -#endif - ; return 0; } EOF -if { (eval echo configure:2743: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5327: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_func_pthread_attr_init=yes" + ac_cv_c_unroll_loops=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_func_pthread_attr_init=no" + ac_cv_c_unroll_loops=no fi rm -f conftest* fi -if eval "test \"`echo '$ac_cv_func_'pthread_attr_init`\" = yes"; then - echo "$ac_t""yes" 1>&6 - : -else - echo "$ac_t""no" 1>&6 -fi - - THREAD_LIB="" +echo "$ac_t""$ac_cv_c_unroll_loops" 1>&6 +if test x"$ac_cv_c_unroll_loops" != x"no"; then + CFLAGS_OPTIM="${CFLAGS_OPTIM} -funroll-loops" fi -echo $ac_n "checking for cthread_fork in -lthreads""... $ac_c" 1>&6 -echo "configure:2766: checking for cthread_fork in -lthreads" >&5 -ac_lib_var=`echo threads'_'cthread_fork | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +echo $ac_n "checking if \$CC accepts -fomit-frame-pointer""... $ac_c" 1>&6 +echo "configure:5345: checking if \$CC accepts -fomit-frame-pointer" >&5 +if eval "test \"`echo '$''{'ac_cv_c_omit_frame_pointer'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lthreads $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5358: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + ac_cv_c_omit_frame_pointer=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + ac_cv_c_omit_frame_pointer=no fi rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - THREAD_LIB="-lthreads" -else - echo "$ac_t""no" 1>&6 fi +echo "$ac_t""$ac_cv_c_omit_frame_pointer" 1>&6 +if test x"$ac_cv_c_omit_frame_pointer" != x"no"; then + CFLAGS_OPTIM_NODEBUG="${CFLAGS_OPTIM_NODEBUG} -fomit-frame-pointer" +fi -cat > conftest.$ac_ext <&6 +echo "configure:5376: checking if \$CC accepts -bundle -undefined error -lcc_dynamic" >&5 +if eval "test \"`echo '$''{'ac_cv_ld_darwin'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + CFLAGS="${save_CFLAGS} -bundle -undefined error -lcc_dynamic" + cat > conftest.$ac_ext < -EOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "pthread_cond_t" >/dev/null 2>&1; then - rm -rf conftest* - - cat >> confdefs.h <<\EOF -#define PTHREAD_COND_T_IN_PTHREAD_H 1 -EOF -fi -rm -f conftest* +int main() { -cat > conftest.$ac_ext < +; return 0; } EOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "strncasecmp" >/dev/null 2>&1; then +if { (eval echo configure:5389: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - - cat >> confdefs.h <<\EOF -#define STRNCASECMP_IN_STRINGS_H 1 -EOF - + ac_cv_ld_darwin=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_ld_darwin=no fi rm -f conftest* +fi +echo "$ac_t""$ac_cv_ld_darwin" 1>&6 +if test x"$ac_cv_ld_darwin" != x"no"; then + PLDFLAGS="${PLDFLAGS} -bundle -undefined error -lcc_dynamic" +fi -for ac_hdr in stddef.h getopt.h strings.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:2843: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then +echo $ac_n "checking if \$CC accepts -shared""... $ac_c" 1>&6 +echo "configure:5407: checking if \$CC accepts -shared" >&5 +if eval "test \"`echo '$''{'ac_cv_ld_plugins'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < conftest.$ac_ext < + +int main() { + +; return 0; } EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2853: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then +if { (eval echo configure:5420: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" + ac_cv_ld_plugins=yes else - echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" + ac_cv_ld_plugins=no fi rm -f conftest* fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 -fi -done -for ac_hdr in sys/sockio.h fcntl.h sys/time.h sys/times.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:2883: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then +echo "$ac_t""$ac_cv_ld_plugins" 1>&6 +if test x"$ac_cv_ld_plugins" != x"no"; then + PLDFLAGS="${PLDFLAGS} -shared" +fi + +if test x"${SOFLAGS}" = x; then + echo $ac_n "checking for soname setting""... $ac_c" 1>&6 +echo "configure:5439: checking for soname setting" >&5 +if eval "test \"`echo '$''{'ac_cv_ld_soname'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < conftest.$ac_ext < + +int main() { + +; return 0; } EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2893: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then +if { (eval echo configure:5455: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" + ac_cv_ld_soname="${try_SOFLAGS}" else - echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" -fi -rm -f conftest* -fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 -fi -done - -for ac_hdr in sys/soundcard.h machine/soundcard.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:2923: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - cat > conftest.$ac_ext < conftest.$ac_ext < + +int main() { + +; return 0; } EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2933: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then +if { (eval echo configure:5474: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" + ac_cv_ld_soname="${try_SOFLAGS}" else - echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" + ac_cv_ld_soname=none fi rm -f conftest* + fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 +rm -f conftest* fi -done -for ac_hdr in dlfcn.h image.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:2963: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then +echo "$ac_t""$ac_cv_ld_soname" 1>&6 + if test x"$ac_cv_ld_soname" != x"none"; then + SOFLAGS=$ac_cv_ld_soname + else + echo " +------------ +Your system doesn't seem to have support for dynamic linking. You may +have problems using libdvdcss. +------------ +" + fi +fi + +echo $ac_n "checking __attribute__ ((aligned ())) support""... $ac_c" 1>&6 +echo "configure:5503: checking __attribute__ ((aligned ())) support" >&5 +if eval "test \"`echo '$''{'ac_cv_c_attribute_aligned'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < conftest.$ac_ext < + +int main() { +static char c __attribute__ ((aligned($ac_cv_c_attr_align_try))) = 0; return c; +; return 0; } EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2973: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then +if { (eval echo configure:5518: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" + ac_cv_c_attribute_aligned=$ac_cv_c_attr_align_try else - echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* + done fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 +if test x"$ac_cv_c_attribute_aligned" != x"0"; then + cat >> confdefs.h <&6 + fi -done -for ac_hdr in arpa/inet.h net/if.h netinet/in.h sys/socket.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3003: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then +CFLAGS="${save_CFLAGS}" +LDFLAGS="${save_LDFLAGS}" + +echo $ac_n "checking for boolean_t in sys/types.h""... $ac_c" 1>&6 +echo "configure:5541: checking for boolean_t in sys/types.h" >&5 +if eval "test \"`echo '$''{'ac_cv_c_boolean_t_sys_types_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < +#include +int main() { +boolean_t foo; +; return 0; } EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3013: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then +if { (eval echo configure:5553: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" + ac_cv_c_boolean_t_sys_types_h=yes else - echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" + ac_cv_c_boolean_t_sys_types_h=no fi rm -f conftest* fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 +if test x"$ac_cv_c_boolean_t_sys_types_h" != x"no"; then + cat >> confdefs.h <<\EOF +#define BOOLEAN_T_IN_SYS_TYPES_H 1 EOF - -else - echo "$ac_t""no" 1>&6 + fi -done -for ac_hdr in machine/param.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3043: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then +echo $ac_n "checking for boolean_t in pthread.h""... $ac_c" 1>&6 +echo "configure:5574: checking for boolean_t in pthread.h" >&5 +if eval "test \"`echo '$''{'ac_cv_c_boolean_t_pthread_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < +#include +int main() { +boolean_t foo; +; return 0; } EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3053: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then +if { (eval echo configure:5586: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" + ac_cv_c_boolean_t_pthread_h=yes else - echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" + ac_cv_c_boolean_t_pthread_h=no fi rm -f conftest* fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 +if test x"$ac_cv_c_boolean_t_pthread_h" != x"no"; then + cat >> confdefs.h <<\EOF +#define BOOLEAN_T_IN_PTHREAD_H 1 EOF - -else - echo "$ac_t""no" 1>&6 -fi -done +fi -for ac_hdr in cthreads.h pthread.h kernel/scheduler.h kernel/OS.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3084: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then +echo $ac_n "checking for boolean_t in cthreads.h""... $ac_c" 1>&6 +echo "configure:5607: checking for boolean_t in cthreads.h" >&5 +if eval "test \"`echo '$''{'ac_cv_c_boolean_t_cthreads_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < +#include +int main() { +boolean_t foo; +; return 0; } EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3094: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then +if { (eval echo configure:5619: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" + ac_cv_c_boolean_t_cthreads_h=yes else - echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" + ac_cv_c_boolean_t_cthreads_h=no fi rm -f conftest* fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 +if test x"$ac_cv_c_boolean_t_cthreads_h" != x"no"; then + cat >> confdefs.h <<\EOF +#define BOOLEAN_T_IN_CTHREADS_H 1 EOF - -else - echo "$ac_t""no" 1>&6 + fi -done +case x"${target_cpu}" in + x) + ARCH=unknown + ;; + *) + ARCH=${target_cpu} + ;; +esac + +BUILTINS="${BUILTINS} idct idctclassic motion imdct downmix chroma_i420_rgb chroma_i420_yuy2 chroma_i422_yuy2 chroma_i420_ymga mpeg_adec ac3_adec mpeg_vdec" +PLUGINS="${PLUGINS} dummy null rc logger mpeg_es mpeg_ps mpeg_ts file udp http ipv4 memcpy lpcm_adec ac3_spdif spudec filter_deinterlace filter_invert filter_wall filter_transform filter_distort fx_scope" -echo $ac_n "checking for ntohl in sys/param.h""... $ac_c" 1>&6 -echo "configure:3122: checking for ntohl in sys/param.h" >&5 -if eval "test \"`echo '$''{'ac_cv_c_ntohl_sys_param_h'+set}'`\" = set"; then +MMX_MODULES="memcpymmx idctmmx motionmmx chroma_i420_rgb_mmx chroma_i420_yuy2_mmx chroma_i422_yuy2_mmx chroma_i420_ymga_mmx" +MMXEXT_MODULES="memcpymmxext idctmmxext motionmmxext" +THREEDNOW_MODULES="memcpy3dn imdct3dn downmix3dn" +SSE_MODULES="imdctsse downmixsse" +ALTIVEC_MODULES="idctaltivec motionaltivec" + +echo $ac_n "checking if \$CC groks MMX inline assembly""... $ac_c" 1>&6 +echo "configure:5658: checking if \$CC groks MMX inline assembly" >&5 +if eval "test \"`echo '$''{'ac_cv_mmx_inline'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - CFLAGS="${save_CFLAGS} -Wall -Werror" - cat > conftest.$ac_ext < conftest.$ac_ext < + int main() { -void foo() { int meuh; ntohl(meuh); } +void *p;asm volatile("packuswb %%mm1,%%mm2"::"r"(p)); ; return 0; } EOF -if { (eval echo configure:3135: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5670: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - ac_cv_c_ntohl_sys_param_h=yes + ac_cv_mmx_inline=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_c_ntohl_sys_param_h=no + ac_cv_mmx_inline=no fi rm -f conftest* fi -echo "$ac_t""$ac_cv_c_ntohl_sys_param_h" 1>&6 -if test x"$ac_cv_c_ntohl_sys_param_h" != x"no"; then - cat >> confdefs.h <<\EOF -#define NTOHL_IN_SYS_PARAM_H 1 -EOF - +echo "$ac_t""$ac_cv_mmx_inline" 1>&6 +if test x"$ac_cv_mmx_inline" != x"no"; then + ACCEL_MODULES="${ACCEL_MODULES} ${MMX_MODULES}" fi -echo $ac_n "checking if \$CC accepts -finline-limit""... $ac_c" 1>&6 -echo "configure:3156: checking if \$CC accepts -finline-limit" >&5 -if eval "test \"`echo '$''{'ac_cv_c_inline_limit'+set}'`\" = set"; then +echo $ac_n "checking if \$CC groks MMX EXT inline assembly""... $ac_c" 1>&6 +echo "configure:5688: checking if \$CC groks MMX EXT inline assembly" >&5 +if eval "test \"`echo '$''{'ac_cv_mmxext_inline'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - CFLAGS="${save_CFLAGS} -finline-limit-30000" - cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5700: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - ac_cv_c_inline_limit=yes + ac_cv_mmxext_inline=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_c_inline_limit=no + ac_cv_mmxext_inline=no fi rm -f conftest* fi -echo "$ac_t""$ac_cv_c_inline_limit" 1>&6 -if test x"$ac_cv_c_inline_limit" != x"no"; then - save_CFLAGS="${save_CFLAGS} -finline-limit-30000" +echo "$ac_t""$ac_cv_mmxext_inline" 1>&6 +if test x"$ac_cv_mmxext_inline" != x"no"; then + ACCEL_MODULES="${ACCEL_MODULES} ${MMXEXT_MODULES}" fi -echo $ac_n "checking if \$CC accepts -bundle -undefined error""... $ac_c" 1>&6 -echo "configure:3187: checking if \$CC accepts -bundle -undefined error" >&5 -if eval "test \"`echo '$''{'ac_cv_ld_darwin'+set}'`\" = set"; then +echo $ac_n "checking if \$CC groks 3D Now! inline assembly""... $ac_c" 1>&6 +echo "configure:5718: checking if \$CC groks 3D Now! inline assembly" >&5 +if eval "test \"`echo '$''{'ac_cv_3dnow_inline'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - CFLAGS="${save_CFLAGS} -bundle -undefined error" - cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5730: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - ac_cv_ld_darwin=yes + ac_cv_3dnow_inline=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_ld_darwin=no + ac_cv_3dnow_inline=no fi rm -f conftest* fi -echo "$ac_t""$ac_cv_ld_darwin" 1>&6 -if test x"$ac_cv_ld_darwin" != x"no"; then - PLCFLAGS="${PLCFLAGS} -bundle -undefined error" +echo "$ac_t""$ac_cv_3dnow_inline" 1>&6 +if test x"$ac_cv_3dnow_inline" != x"no"; then + cat >> confdefs.h <<\EOF +#define CAN_COMPILE_3DNOW 1 +EOF + + ACCEL_MODULES="${ACCEL_MODULES} ${THREEDNOW_MODULES}" fi -echo $ac_n "checking if \$CC accepts -shared""... $ac_c" 1>&6 -echo "configure:3218: checking if \$CC accepts -shared" >&5 -if eval "test \"`echo '$''{'ac_cv_ld_plugins'+set}'`\" = set"; then +echo $ac_n "checking if \$CC groks SSE inline assembly""... $ac_c" 1>&6 +echo "configure:5752: checking if \$CC groks SSE inline assembly" >&5 +if eval "test \"`echo '$''{'ac_cv_sse_inline'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - CFLAGS="${save_CFLAGS} -shared" - cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5764: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - ac_cv_ld_plugins=yes + ac_cv_sse_inline=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_ld_plugins=no + ac_cv_sse_inline=no fi rm -f conftest* fi -echo "$ac_t""$ac_cv_ld_plugins" 1>&6 -if test x"$ac_cv_ld_plugins" != x"no"; then - PLCFLAGS="${PLCFLAGS} -shared" +echo "$ac_t""$ac_cv_sse_inline" 1>&6 +if test x"$ac_cv_sse_inline" != x"no"; then + cat >> confdefs.h <<\EOF +#define CAN_COMPILE_SSE 1 +EOF + + ACCEL_MODULES="${ACCEL_MODULES} ${SSE_MODULES}" fi - -if test x"${SOFLAGS}" = x; then - echo $ac_n "checking for soname setting""... $ac_c" 1>&6 -echo "configure:3250: checking for soname setting" >&5 -if eval "test \"`echo '$''{'ac_cv_ld_soname'+set}'`\" = set"; then + +# don't try to grok altivec with native mingw32 it doesn't work right now +# we should be able to remove this test with future versions of mingw32 +if test x$SYS != xmingw32; then +echo $ac_n "checking if \$CC groks Altivec inline assembly""... $ac_c" 1>&6 +echo "configure:5789: checking if \$CC groks Altivec inline assembly" >&5 +if eval "test \"`echo '$''{'ac_cv_altivec_inline'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - - # Standard - try_SOFLAGS="-Wl,-soname -Wl," - LDFLAGS="${save_LDFLAGS} ${try_SOFLAGS}foo.so.0" - cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5801: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - ac_cv_ld_soname="${try_SOFLAGS}" + ac_cv_altivec_inline=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - - # SunOS - try_SOFLAGS="-Wl,-h -Wl," - LDFLAGS="${save_LDFLAGS} ${try_SOFLAGS}foo.so.0" - cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5818: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - ac_cv_ld_soname="${try_SOFLAGS}" + ac_cv_altivec_inline="-Wa,-m7400" else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_ld_soname=none + ac_cv_altivec_inline=no fi rm -f conftest* - + CFLAGS=$save_CFLAGS + fi rm -f conftest* fi -echo "$ac_t""$ac_cv_ld_soname" 1>&6 - if test x"$ac_cv_ld_soname" != x"none"; then - SOFLAGS=$ac_cv_ld_soname - else - echo " ------------- -Your system doesn't seem to have support for dynamic linking. You may -have problems using libdvdcss. ------------- -" - fi +echo "$ac_t""$ac_cv_altivec_inline" 1>&6 +if test x"$ac_cv_altivec_inline" != x"no"; then + cat >> confdefs.h <<\EOF +#define CAN_COMPILE_ALTIVEC 1 +EOF + + if test x"$ac_cv_altivec_inline" != x"yes"; then + CFLAGS_IDCTALTIVEC="$CFLAGS_IDCTALTIVEC $ac_cv_altivec_inline" + CFLAGS_MOTIONALTIVEC="$CFLAGS_MOTIONALTIVEC $ac_cv_altivec_inline" + CFLAGS_VLC="$CFLAGS_VLC $ac_cv_altivec_inline" + fi + ACCEL_MODULES="${ACCEL_MODULES} ${ALTIVEC_MODULES}" fi -echo $ac_n "checking __attribute__ ((aligned ())) support""... $ac_c" 1>&6 -echo "configure:3314: checking __attribute__ ((aligned ())) support" >&5 -if eval "test \"`echo '$''{'ac_cv_c_attribute_aligned'+set}'`\" = set"; then +echo $ac_n "checking if \$CC groks Altivec C extensions""... $ac_c" 1>&6 +echo "configure:5849: checking if \$CC groks Altivec C extensions" >&5 +if eval "test \"`echo '$''{'ac_cv_c_altivec'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_cv_c_attribute_aligned=0 - CFLAGS="${save_CFLAGS} -Werror" - for ac_cv_c_attr_align_try in 2 4 8 16 32 64; do - cat > conftest.$ac_ext < conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5864: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - ac_cv_c_attribute_aligned=$ac_cv_c_attr_align_try + ac_cv_c_altivec=-faltivec else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 -fi -rm -f conftest* - done -fi - -echo "$ac_t""$ac_cv_c_attribute_aligned" 1>&6 -if test x"$ac_cv_c_attribute_aligned" != x"0"; then - cat >> confdefs.h <&6 -echo "configure:3352: checking for boolean_t in sys/types.h" >&5 -if eval "test \"`echo '$''{'ac_cv_c_boolean_t_sys_types_h'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - cat > conftest.$ac_ext < conftest.$ac_ext < + int main() { -void quux() { boolean_t foo; } +vec_mtvscr((vector unsigned int)(0)); ; return 0; } EOF -if { (eval echo configure:3364: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5882: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* - ac_cv_c_boolean_t_sys_types_h=yes + ac_cv_c_altivec="-fvec" else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_c_boolean_t_sys_types_h=no + ac_cv_c_altivec=no +fi +rm -f conftest* + fi rm -f conftest* + CFLAGS=$save_CFLAGS + fi -echo "$ac_t""$ac_cv_c_boolean_t_sys_types_h" 1>&6 -if test x"$ac_cv_c_boolean_t_sys_types_h" != x"no"; then - cat >> confdefs.h <<\EOF -#define BOOLEAN_T_IN_SYS_TYPES_H 1 +echo "$ac_t""$ac_cv_c_altivec" 1>&6 +if test x"$ac_cv_c_altivec" != x"no"; then + cat >> confdefs.h <<\EOF +#define CAN_COMPILE_C_ALTIVEC 1 EOF + CFLAGS_IDCTALTIVEC="$CFLAGS_IDCTALTIVEC $ac_cv_c_altivec" + CFLAGS_MOTIONALTIVEC="$CFLAGS_MOTIONALTIVEC $ac_cv_c_altivec" + CFLAGS_VLC="$CFLAGS_VLC $ac_cv_c_altivec" + ACCEL_MODULES="${ACCEL_MODULES} ${ALTIVEC_MODULES}" fi -echo $ac_n "checking for boolean_t in pthread.h""... $ac_c" 1>&6 -echo "configure:3385: checking for boolean_t in pthread.h" >&5 -if eval "test \"`echo '$''{'ac_cv_c_boolean_t_pthread_h'+set}'`\" = set"; then +echo $ac_n "checking if linker needs -framework vecLib""... $ac_c" 1>&6 +echo "configure:5912: checking if linker needs -framework vecLib" >&5 +if eval "test \"`echo '$''{'ac_cv_ld_altivec'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < conftest.$ac_ext < + int main() { -void quux() { boolean_t foo; } + ; return 0; } EOF -if { (eval echo configure:3397: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:5926: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - ac_cv_c_boolean_t_pthread_h=yes + ac_cv_ld_altivec=yes else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_c_boolean_t_pthread_h=no + ac_cv_ld_altivec=no fi rm -f conftest* + LDFLAGS=$save_LDFLAGS + fi -echo "$ac_t""$ac_cv_c_boolean_t_pthread_h" 1>&6 -if test x"$ac_cv_c_boolean_t_pthread_h" != x"no"; then - cat >> confdefs.h <<\EOF -#define BOOLEAN_T_IN_PTHREAD_H 1 +echo "$ac_t""$ac_cv_ld_altivec" 1>&6 +if test x"$ac_cv_ld_altivec" != x"no"; then + LIB_IDCTALTIVEC="${LIB_IDCTALTIVEC} -framework vecLib" + LIB_MOTIONALTIVEC="${LIB_MOTIONALTIVEC} -framework vecLib" + LIB_VLC="${LIB_VLC} -framework vecLib" +fi +fi # end if mingw32 + +case x$SYS in + xmingw32) + DVD_DEVICE="E:" + VCD_DEVICE="E:" + ;; + *) + DVD_DEVICE="/dev/dvd" + VCD_DEVICE="/dev/cdrom" + ;; +esac + +cat >> confdefs.h <> confdefs.h <&6 -echo "configure:3418: checking for boolean_t in cthreads.h" >&5 -if eval "test \"`echo '$''{'ac_cv_c_boolean_t_cthreads_h'+set}'`\" = set"; then + + + +CAN_BUILD_LIBDVDCSS=0 + +for ac_hdr in winioctl.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:5976: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < -int main() { -void quux() { boolean_t foo; } -; return 0; } +#include <$ac_hdr> EOF -if { (eval echo configure:3430: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:5986: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then rm -rf conftest* - ac_cv_c_boolean_t_cthreads_h=yes + eval "ac_cv_header_$ac_safe=yes" else + echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_c_boolean_t_cthreads_h=no + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* fi - -echo "$ac_t""$ac_cv_c_boolean_t_cthreads_h" 1>&6 -if test x"$ac_cv_c_boolean_t_cthreads_h" != x"no"; then - cat >> confdefs.h <<\EOF -#define BOOLEAN_T_IN_CTHREADS_H 1 +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 fi +done -echo $ac_n "checking for working const""... $ac_c" 1>&6 -echo "configure:3451: checking for working const" >&5 -if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then + +for ac_hdr in sys/ioctl.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:6019: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <j = 5; -} -{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ - const int foo = 10; -} - -; return 0; } +#include <$ac_hdr> EOF -if { (eval echo configure:3505: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:6029: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then rm -rf conftest* - ac_cv_c_const=yes + eval "ac_cv_header_$ac_safe=yes" else + echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_c_const=no + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* fi - -echo "$ac_t""$ac_cv_c_const" 1>&6 -if test $ac_cv_c_const = no; then - cat >> confdefs.h <<\EOF -#define const +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 -echo "configure:3526: checking for ANSI C header files" >&5 -if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then + + CAN_BUILD_LIBDVDCSS="${HAVE_LIBDVDCSS}" + for ac_hdr in sys/cdio.h sys/dvdio.h linux/cdrom.h dvd.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:6055: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < -#include -#include -#include +#include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3539: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6065: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* - ac_cv_header_stdc=yes + eval "ac_cv_header_$ac_safe=yes" else echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_header_stdc=no + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 +fi +done -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. -cat > conftest.$ac_ext < conftest.$ac_ext < +#include EOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "memchr" >/dev/null 2>&1; then - : -else + egrep "dvd_struct" >/dev/null 2>&1; then rm -rf conftest* - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi + + cat >> confdefs.h <<\EOF +#define DVD_STRUCT_IN_SYS_CDIO_H 1 +EOF -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. -cat > conftest.$ac_ext < conftest.$ac_ext < +#include EOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "free" >/dev/null 2>&1; then - : + egrep "struct dvd_struct" >/dev/null 2>&1; then + rm -rf conftest* + + BSD_DVD_STRUCT=1 else rm -rf conftest* - ac_cv_header_stdc=no + LINUX_DVD_STRUCT=1; OPENBSD_DVD_STRUCT=1 fi rm -f conftest* + fi +rm -f conftest* -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. -if test "$cross_compiling" = yes; then - : -else - cat > conftest.$ac_ext < conftest.$ac_ext < -#define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int main () { int i; for (i = 0; i < 256; i++) -if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); -exit (0); } +#include +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "dvd_struct" >/dev/null 2>&1; then + rm -rf conftest* + + cat >> confdefs.h <<\EOF +#define DVD_STRUCT_IN_SYS_DVDIO_H 1 +EOF + cat > conftest.$ac_ext < EOF -if { (eval echo configure:3606: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null -then - : +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "struct dvd_struct" >/dev/null 2>&1; then + rm -rf conftest* + + BSD_DVD_STRUCT=1 else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -fr conftest* - ac_cv_header_stdc=no -fi -rm -fr conftest* + rm -rf conftest* + LINUX_DVD_STRUCT=1 fi +rm -f conftest* + fi -fi +rm -f conftest* -echo "$ac_t""$ac_cv_header_stdc" 1>&6 -if test $ac_cv_header_stdc = yes; then - cat >> confdefs.h <<\EOF -#define STDC_HEADERS 1 + cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "dvd_struct" >/dev/null 2>&1; then + rm -rf conftest* + + cat >> confdefs.h <<\EOF +#define DVD_STRUCT_IN_LINUX_CDROM_H 1 EOF + LINUX_DVD_STRUCT=1 + fi +rm -f conftest* -echo $ac_n "checking for size_t""... $ac_c" 1>&6 -echo "configure:3630: checking for size_t" >&5 -if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else + NEED_BSDI_LIBDVD=0 cat > conftest.$ac_ext < -#if STDC_HEADERS -#include -#include -#endif +#include EOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then - rm -rf conftest* - ac_cv_type_size_t=yes -else + egrep "dvd_struct" >/dev/null 2>&1; then rm -rf conftest* - ac_cv_type_size_t=no -fi -rm -f conftest* - -fi -echo "$ac_t""$ac_cv_type_size_t" 1>&6 -if test $ac_cv_type_size_t = no; then - cat >> confdefs.h <<\EOF -#define size_t unsigned + + cat >> confdefs.h <<\EOF +#define DVD_STRUCT_IN_DVD_H 1 EOF -fi - -echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 -echo "configure:3663: checking whether time.h and sys/time.h may both be included" >&5 -if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then + LIB_LIBDVDCSS="${LIB_LIBDVDCSS} -ldvd" + LINUX_DVD_STRUCT=1 + +else + rm -rf conftest* + + for ac_hdr in /sys/dev/scsi/scsi_ioctl.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:6202: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < -#include -#include -int main() { -struct tm *tp; -; return 0; } +#include <$ac_hdr> EOF -if { (eval echo configure:3677: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:6212: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then rm -rf conftest* - ac_cv_header_time=yes + eval "ac_cv_header_$ac_safe=yes" else + echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_header_time=no + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* fi - -echo "$ac_t""$ac_cv_header_time" 1>&6 -if test $ac_cv_header_time = yes; then - cat >> confdefs.h <<\EOF -#define TIME_WITH_SYS_TIME 1 +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <> confdefs.h <<\EOF +#define DVD_STRUCT_IN_BSDI_DVDIOCTL_DVD_H 1 EOF + SRC_DVDCSS_EXTRA="${SRC_DVDCSS_EXTRA} bsdi_dvdioctl.c" + LINUX_DVD_STRUCT=1 + +else + echo "$ac_t""no" 1>&6 fi +done + +fi +rm -f conftest* - -ARCH=${target_cpu} - -BUILTINS="${BUILTINS} es ps ts yuv idct idctclassic motion imdct downmix" -PLUGINS="${PLUGINS}" - -MMX_MODULES="yuvmmx idctmmx motionmmx" -MMXEXT_MODULES="idctmmxext motionmmxext" -THREEDNOW_MODULES="imdct3dn downmix3dn" -SSE_MODULES="imdctsse downmixsse" -ALTIVEC_MODULES="idctaltivec motionaltivec" - -echo $ac_n "checking if \$CC groks MMX inline assembly""... $ac_c" 1>&6 -echo "configure:3711: checking if \$CC groks MMX inline assembly" >&5 -if eval "test \"`echo '$''{'ac_cv_mmx_inline'+set}'`\" = set"; then + ac_safe=`echo "sys/scsi/scsi_types.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for sys/scsi/scsi_types.h""... $ac_c" 1>&6 +echo "configure:6252: checking for sys/scsi/scsi_types.h" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF -if { (eval echo configure:3723: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:6262: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then rm -rf conftest* - ac_cv_mmx_inline=yes + eval "ac_cv_header_$ac_safe=yes" else + echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_mmx_inline=no + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* fi - -echo "$ac_t""$ac_cv_mmx_inline" 1>&6 -if test x"$ac_cv_mmx_inline" != x"no"; then - ACCEL_MODULES="${ACCEL_MODULES} ${MMX_MODULES}" -fi - -echo $ac_n "checking if \$CC groks MMX EXT inline assembly""... $ac_c" 1>&6 -echo "configure:3741: checking if \$CC groks MMX EXT inline assembly" >&5 -if eval "test \"`echo '$''{'ac_cv_mmxext_inline'+set}'`\" = set"; then +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + + ac_safe=`echo "sys/scsi/impl/uscsi.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for sys/scsi/impl/uscsi.h""... $ac_c" 1>&6 +echo "configure:6281: checking for sys/scsi/impl/uscsi.h" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF -if { (eval echo configure:3753: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:6291: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then rm -rf conftest* - ac_cv_mmxext_inline=yes + eval "ac_cv_header_$ac_safe=yes" else + echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_mmxext_inline=no + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + + cat >> confdefs.h <<\EOF +#define SOLARIS_USCSI 1 +EOF -echo "$ac_t""$ac_cv_mmxext_inline" 1>&6 -if test x"$ac_cv_mmxext_inline" != x"no"; then - ACCEL_MODULES="${ACCEL_MODULES} ${MMXEXT_MODULES}" + +else + echo "$ac_t""no" 1>&6 fi -echo $ac_n "checking if \$CC groks 3D Now! inline assembly""... $ac_c" 1>&6 -echo "configure:3771: checking if \$CC groks 3D Now! inline assembly" >&5 -if eval "test \"`echo '$''{'ac_cv_3dnow_inline'+set}'`\" = set"; then + +else + echo "$ac_t""no" 1>&6 +fi + + ac_safe=`echo "sys/scsi.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for sys/scsi.h""... $ac_c" 1>&6 +echo "configure:6324: checking for sys/scsi.h" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF -if { (eval echo configure:3783: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:6334: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then rm -rf conftest* - ac_cv_3dnow_inline=yes + eval "ac_cv_header_$ac_safe=yes" else + echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_3dnow_inline=no + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* fi - -echo "$ac_t""$ac_cv_3dnow_inline" 1>&6 -if test x"$ac_cv_3dnow_inline" != x"no"; then - cat >> confdefs.h <<\EOF -#define HAVE_3DNOW 1 +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + + cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "sctl_io" >/dev/null 2>&1; then + rm -rf conftest* + + cat >> confdefs.h <<\EOF +#define HPUX_SCTL_IO 1 EOF - ACCEL_MODULES="${ACCEL_MODULES} ${THREEDNOW_MODULES}" + fi +rm -f conftest* -echo $ac_n "checking if \$CC groks SSE inline assembly""... $ac_c" 1>&6 -echo "configure:3805: checking if \$CC groks SSE inline assembly" >&5 -if eval "test \"`echo '$''{'ac_cv_sse_inline'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 + else - cat > conftest.$ac_ext <&6 +fi -int main() { -void quux(){void *p;asm volatile("xorps %%xmm1,%%xmm2"::"r"(p));} -; return 0; } + if test x$LINUX_DVD_STRUCT = x1; then + cat >> confdefs.h <<\EOF +#define HAVE_LINUX_DVD_STRUCT 1 EOF -if { (eval echo configure:3817: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then - rm -rf conftest* - ac_cv_sse_inline=yes + + if test x$OPENBSD_DVD_STRUCT = x1; then + cat >> confdefs.h <<\EOF +#define HAVE_OPENBSD_DVD_STRUCT 1 +EOF + + fi + else + if test x$BSD_DVD_STRUCT = x1; then + cat >> confdefs.h <<\EOF +#define HAVE_BSD_DVD_STRUCT 1 +EOF + + fi + fi + else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - ac_cv_sse_inline=no + echo "$ac_t""no" 1>&6 fi -rm -f conftest* +done + + +# Check whether --with- or --without- was given. +if test "${with_+set}" = set; then + withval="$with_" + : fi -echo "$ac_t""$ac_cv_sse_inline" 1>&6 -if test x"$ac_cv_sse_inline" != x"no"; then - cat >> confdefs.h <<\EOF -#define HAVE_SSE 1 -EOF +# Check whether --with- or --without- was given. +if test "${with_+set}" = set; then + withval="$with_" + : +fi - ACCEL_MODULES="${ACCEL_MODULES} ${SSE_MODULES}" + +# Check whether --with-tuning or --without-tuning was given. +if test "${with_tuning+set}" = set; then + withval="$with_tuning" + : fi -echo $ac_n "checking if \$CC groks Altivec inline assembly""... $ac_c" 1>&6 -echo "configure:3839: checking if \$CC groks Altivec inline assembly" >&5 -if eval "test \"`echo '$''{'ac_cv_altivec_inline'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 +if test "x$withval" != "x"; then + TUNING=$withval else - cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then - rm -rf conftest* - ac_cv_altivec_inline=yes +if test x${target_cpu} = xi686 -o x${target_cpu} = xi586 -o x${target_cpu} = xx86 -o x${target_cpu} = xi386 +then + ARCH="${ARCH} mmx" + BUILTINS="${BUILTINS} ${ACCEL_MODULES}" +fi + +# Check whether --enable-optimizations or --disable-optimizations was given. +if test "${enable_optimizations+set}" = set; then + enableval="$enable_optimizations" + if test x$enableval = xno; then OPTIMS=0; fi else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - save_CFLAGS=$CFLAGS - CFLAGS="$CFLAGS -Wa,-m7400" - cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then - rm -rf conftest* - ac_cv_altivec_inline=yes; CFLAGS_ALTIVEC="-Wa,-m7400" + +# Check whether --enable-altivec or --disable-altivec was given. +if test "${enable_altivec+set}" = set; then + enableval="$enable_altivec" + if test x$enableval = xyes; then ARCH="${ARCH} altivec"; + BUILTINS="${BUILTINS} ${ACCEL_MODULES}"; fi else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - ac_cv_altivec_inline=no + if test x${target_cpu} = xpowerpc; then ARCH="${ARCH} altivec"; + BUILTINS="${BUILTINS} ${ACCEL_MODULES}"; fi fi -rm -f conftest* - CFLAGS=$save_CFLAGS - + + +DEBUG=0 +# Check whether --enable-debug or --disable-debug was given. +if test "${enable_debug+set}" = set; then + enableval="$enable_debug" + if test x$enableval = xyes; then DEBUG=1; fi fi -rm -f conftest* + + +# Check whether --enable-release or --disable-release was given. +if test "${enable_release+set}" = set; then + enableval="$enable_release" + if test x$enableval = xyes; then RELEASE=1; fi +else + VLC_VERSION="${VLC_VERSION}_`date +%Y-%m-%d`"; + LIBDVDCSS_VERSION="${LIBDVDCSS_VERSION}_`date +%Y-%m-%d`"; +fi + + + +# Check whether --with- or --without- was given. +if test "${with_+set}" = set; then + withval="$with_" + : +fi + + +NEED_LIBDVDCSS=0 +STATIC_LIBDVDCSS=0 +DUMMY_LIBDVDCSS=0 +# Check whether --with-dvdcss or --without-dvdcss was given. +if test "${with_dvdcss+set}" = set; then + withval="$with_dvdcss" + case "x${withval}" in + xlocal-static|xyes) + # local libdvdcss, statically linked + BUILTINS="${BUILTINS} dvd" + if test x${CAN_BUILD_LIBDVDCSS} = x1 + then + NEED_LIBDVDCSS=1 + STATIC_LIBDVDCSS=1 + CFLAGS_DVD="${CFLAGS_DVD} -I../../extras/libdvdcss" + LIB_DVD="${LIB_DVD} lib/libdvdcss.a ${LIB_LIBDVDCSS}" + fi + ;; + xlocal-shared) + # local libdvdcss, dynamically linked + PLUGINS="${PLUGINS} dvd" + if test x${CAN_BUILD_LIBDVDCSS} = x1 + then + NEED_LIBDVDCSS=1 + CFLAGS_DVD="${CFLAGS_DVD} -I../../extras/libdvdcss" + LIB_DVD="${LIB_DVD} -L../../lib -ldvdcss" + fi + ;; + xno) + # don't use libdvdcss at all, build a DVD module that can dlopen() it + PLUGINS="${PLUGINS} dvd" + DUMMY_LIBDVDCSS=1 + SRC_DVD_EXTRA="${SRC_DVD_EXTRA} dummy_dvdcss.c" + CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA" + CFLAGS_DVD="${CFLAGS_DVD} -DLIBDVDCSS_VERSION=\"${LIBDVDCSS_VERSION}\"" + LIB_DVD="${LIB_DVD} -ldl" + ;; + *) + # existing libdvdcss + PLUGINS="${PLUGINS} dvd" + if test "x$withval" != "xyes" + then + LIB_DVD="${LIB_DVD} -L"$withval"/lib" + CFLAGS_DVD="${CFLAGS_DVD} -I"$withval"/include" + fi + LIB_DVD="${LIB_DVD} -ldvdcss" + esac +else + # user didn't decide, we choose to use local libdvdcss and link statically + # if libdvdcss is in the archive, or to use the dummy replacement otherwise. + if test x${CAN_BUILD_LIBDVDCSS} = x1 + then + BUILTINS="${BUILTINS} dvd" + NEED_LIBDVDCSS=1 + STATIC_LIBDVDCSS=1 + CFLAGS_DVD="${CFLAGS_DVD} -I../../extras/libdvdcss" + LIB_DVD="${LIB_DVD} lib/libdvdcss.a ${LIB_LIBDVDCSS}" + else + # XXX: no check for libdl is done, don't try this at home ! + PLUGINS="${PLUGINS} dvd" + DUMMY_LIBDVDCSS=1 + SRC_DVD_EXTRA="${SRC_DVD_EXTRA} dummy_dvdcss.c" + CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA" + LIB_DVD="${LIB_DVD} -ldl" + fi +fi + + +if test x${DUMMY_LIBDVDCSS} = x1; then STATIC_LIBDVDREAD=1; fi +if test x${STATIC_LIBDVDCSS} = x1; then STATIC_LIBDVDREAD=1; fi +# Check whether --with-dvdread or --without-dvdread was given. +if test "${with_dvdread+set}" = set; then + withval="$with_dvdread" + case "x${withval}" in + xlocal-static|xyes) + if test x${STATIC_LIBDVDREAD} = x1 + then + BUILTINS="${BUILTINS} dvdread" + CFLAGS_DVDREAD="${CFLAGS_DVDREAD} ${CFLAGS_DVD} -I../../extras/libdvdread" + LIB_DVDREAD="${LIB_DVDREAD} lib/libdvdread.a ${LIB_DVD}" + else + { echo "configure: error: Can't link static dvdread with shared dvdcss" 1>&2; exit 1; } + fi + ;; + xno) + ;; + x) + if test x${STATIC_LIBDVDREAD} = x1 + then + #BUILTINS="${BUILTINS} dvdread" + CFLAGS_DVDREAD="${CFLAGS_DVDREAD} ${CFLAGS_DVD} -I../../extras/libdvdread" + LIB_DVDREAD="${LIB_DVDREAD} lib/libdvdread.a ${LIB_DVD}" + else + #PLUGINS="${PLUGINS} dvdread" + CFLAGS_DVDREAD="${CFLAGS_DVDREAD} -I../../extras/libdvdread ${CFLAGS_DVD}" + LIB_DVDREAD="${LIB_DVDREAD} -Llib -ldvdread ${LIB_DVD}" + fi + ;; + *) + if test "x$withval" != "xlocal-shared" + then + LIB_DVDREAD="${LIB_DVDREAD} -L"$withval"/lib" + CFLAGS_DVDREAD="${CFLAGS_DVDREAD} -I"$withval"/include" + else + LIB_DVDREAD="${LIB_DVDREAD} -L../../lib" + CFLAGS_DVDREAD="${CFLAGS_DVDREAD} -I../../extras/libdvdread" + fi + if test x${STATIC_LIBDVDCSS} = x1 + then + { echo "configure: error: Can't link shared dvdread with static dvdcss" 1>&2; exit 1; } + else + #PLUGINS="${PLUGINS} dvdread" + CFLAGS_DVDREAD="${CFLAGS_DVDREAD} ${CFLAGS_DVD}" + LIB_DVDREAD="${LIB_DVDREAD} -ldvdread ${LIB_DVD}" + fi + esac + if test x${DUMMY_LIBDVDCSS} = x1 + then + LIB_LIBDVDREAD="${LIB_LIBDVDREAD} -ldl" + else + LIB_LIBDVDREAD="${LIB_LIBDVDREAD} -L../../lib -ldvdcss" + fi fi -echo "$ac_t""$ac_cv_altivec_inline" 1>&6 -if test x"$ac_cv_altivec_inline" != x"no"; then - cat >> confdefs.h <<\EOF -#define HAVE_ALTIVEC 1 -EOF - ACCEL_MODULES="${ACCEL_MODULES} ${ALTIVEC_MODULES}" +# Check whether --enable-vcd or --disable-vcd was given. +if test "${enable_vcd+set}" = set; then + enableval="$enable_vcd" + : fi -echo $ac_n "checking if \$CC groks Altivec C extensions""... $ac_c" 1>&6 -echo "configure:3894: checking if \$CC groks Altivec C extensions" >&5 -if eval "test \"`echo '$''{'ac_cv_c_altivec'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - save_CFLAGS=$CFLAGS - CFLAGS="$CFLAGS -faltivec" - # Darwin test - cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then - rm -rf conftest* - ac_cv_c_altivec=-faltivec -else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - - # Linux/PPC test - CFLAGS="$save_CFLAGS $CFLAGS_ALTIVEC -fvec" - cat > conftest.$ac_ext < conftest.$ac_ext < EOF -if { (eval echo configure:3927: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then - rm -rf conftest* - ac_cv_c_altivec="-fvec" -else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "cdrom_msf0" >/dev/null 2>&1; then rm -rf conftest* - ac_cv_c_altivec=no -fi -rm -f conftest* - + + PLUGINS="${PLUGINS} vcd" + fi rm -f conftest* - CFLAGS=$save_CFLAGS - + + + if test "x${SYS}" = "xbsdi" + then + PLUGINS="${PLUGINS} vcd" + fi + + if test "x${SYS}" = "xdarwin" + then + PLUGINS="${PLUGINS} vcd" + LIB_VCD="${LIB_VCD} -framework IOKit -framework CoreFoundation" + fi fi -echo "$ac_t""$ac_cv_c_altivec" 1>&6 -if test x"$ac_cv_c_altivec" != x"no"; then - cat >> confdefs.h <<\EOF -#define HAVE_C_ALTIVEC 1 +# Check whether --enable-satellite or --disable-satellite was given. +if test "${enable_satellite+set}" = set; then + enableval="$enable_satellite" + if test x$enable_satellite = xyes + then + BUILTINS="${BUILTINS} satellite" + cat >> confdefs.h <<\EOF +#define HAVE_SATELLITE 1 EOF - CFLAGS_ALTIVEC="$CFLAGS_ALTIVEC $ac_cv_c_altivec" + fi fi -echo $ac_n "checking if linker needs -framework vecLib""... $ac_c" 1>&6 -echo "configure:3954: checking if linker needs -framework vecLib" >&5 -if eval "test \"`echo '$''{'ac_cv_ld_altivec'+set}'`\" = set"; then + +echo $ac_n "checking for inet_pton""... $ac_c" 1>&6 +echo "configure:6655: checking for inet_pton" >&5 +if eval "test \"`echo '$''{'ac_cv_func_inet_pton'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - save_LDFLAGS=$LDFLAGS - LDFLAGS="$LDFLAGS -framework vecLib" - cat > conftest.$ac_ext < conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char inet_pton(); int main() { +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_inet_pton) || defined (__stub___inet_pton) +choke me +#else +inet_pton(); +#endif + ; return 0; } EOF -if { (eval echo configure:3968: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6683: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - ac_cv_ld_altivec=yes + eval "ac_cv_func_inet_pton=yes" else echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - ac_cv_ld_altivec=no + eval "ac_cv_func_inet_pton=no" fi rm -f conftest* - LDFLAGS=$save_LDFLAGS - fi -echo "$ac_t""$ac_cv_ld_altivec" 1>&6 -if test x"$ac_cv_ld_altivec" != x"no"; then - LIB_ALTIVEC="-framework vecLib" +if eval "test \"`echo '$ac_cv_func_'inet_pton`\" = yes"; then + echo "$ac_t""yes" 1>&6 + PLUGINS="${PLUGINS} ipv6" +else + echo "$ac_t""no" 1>&6 fi -CAN_BUILD_LIBDVDCSS=0 - -for ac_hdr in winioctl.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3994: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - cat > conftest.$ac_ext < -EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4004: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then - rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" -else - echo "$ac_err" >&5 - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" -fi -rm -f conftest* -fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 +# Check whether --with- or --without- was given. +if test "${with_+set}" = set; then + withval="$with_" + : fi -done -for ac_hdr in sys/ioctl.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4037: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - cat > conftest.$ac_ext < -EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4047: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then - rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" -else - echo "$ac_err" >&5 - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" +# Check whether --enable-mad or --disable-mad was given. +if test "${enable_mad+set}" = set; then + enableval="$enable_mad" + : fi -rm -f conftest* + +if test x$enable_mad = xyes +then + PLUGINS="${PLUGINS} mad" + LIB_MAD="${LIB_MAD} -lmad" + # Check whether --with-mad or --without-mad was given. +if test "${with_mad+set}" = set; then + withval="$with_mad" + if test "x$with_val" != "xno" -a "x$with_val" != "x" + then + CFLAGS_MAD="${CFLAGS_MAD} -I$with_val/include" + LIB_MAD="${LIB_MAD} -L$with_val/lib" + fi fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 -echo "configure:4073: checking for $ac_hdr" >&5 +echo "configure:6739: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4083: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6749: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -4102,130 +6768,95 @@ EOF else echo "$ac_t""no" 1>&6 +echo "Cannot find development headers for libmad..." + exit 1 + fi done - BSD_DVD_STRUCT=0 - LINUX_DVD_STRUCT=0 - cat > conftest.$ac_ext < -EOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "dvd_struct" >/dev/null 2>&1; then - rm -rf conftest* - - cat >> confdefs.h <<\EOF -#define DVD_STRUCT_IN_SYS_CDIO_H 1 -EOF - - cat > conftest.$ac_ext < -EOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "struct dvd_struct" >/dev/null 2>&1; then - rm -rf conftest* - - BSD_DVD_STRUCT=1 + echo $ac_n "checking for mad_bit_init in -lmad""... $ac_c" 1>&6 +echo "configure:6779: checking for mad_bit_init in -lmad" >&5 +ac_lib_var=`echo mad'_'mad_bit_init | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 else - rm -rf conftest* - LINUX_DVD_STRUCT=1 -fi -rm -f conftest* - - -fi -rm -f conftest* - - cat > conftest.$ac_ext < conftest.$ac_ext < -EOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "dvd_struct" >/dev/null 2>&1; then - rm -rf conftest* - - cat >> confdefs.h <<\EOF -#define DVD_STRUCT_IN_SYS_DVDIO_H 1 -EOF +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char mad_bit_init(); - cat > conftest.$ac_ext < +int main() { +mad_bit_init() +; return 0; } EOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "struct dvd_struct" >/dev/null 2>&1; then +if { (eval echo configure:6798: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - - BSD_DVD_STRUCT=1 + eval "ac_cv_lib_$ac_lib_var=yes" else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 rm -rf conftest* - LINUX_DVD_STRUCT=1 + eval "ac_cv_lib_$ac_lib_var=no" fi rm -f conftest* +LIBS="$ac_save_LIBS" - fi -rm -f conftest* - - cat > conftest.$ac_ext < -EOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "dvd_struct" >/dev/null 2>&1; then - rm -rf conftest* - - cat >> confdefs.h <<\EOF -#define DVD_STRUCT_IN_LINUX_CDROM_H 1 +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_lib=HAVE_LIB`echo mad | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + cat >> confdefs.h <&6 + echo "Cannot find libmad library..." + exit 1 fi -rm -f conftest* - NEED_BSDI_LIBDVD=0 - cat > conftest.$ac_ext < -EOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "dvd_struct" >/dev/null 2>&1; then - rm -rf conftest* - - cat >> confdefs.h <<\EOF -#define DVD_STRUCT_IN_DVD_H 1 -EOF + CFLAGS=$save_CFLAGS + LDFLAGS=$save_LDFLAGS +fi + +if test x$SYS = xbeos +then + PLUGINS="${PLUGINS} beos" - LIB_LIBDVDCSS="${LIB_LIBDVDCSS} -ldvd" - LINUX_DVD_STRUCT=1 - else - rm -rf conftest* - - for ac_hdr in /sys/dev/scsi/scsi_ioctl.h + +# Check whether --enable-a52 or --disable-a52 was given. +if test "${enable_a52+set}" = set; then + enableval="$enable_a52" + : +fi + +if test "x$enableval" != "xno" -a x$SYS != xmingw32 + then + for ac_hdr in a52dec/a52.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4219: checking for $ac_hdr" >&5 +echo "configure:6850: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4229: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6860: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -4246,36 +6877,55 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then #define $ac_tr_hdr 1 EOF - NEED_BSDI_LIBDVD=1 - cat >> confdefs.h <<\EOF -#define DVD_STRUCT_IN_BSDI_DVDIOCTL_DVD_H 1 -EOF - - OBJ_LIBDVDCSS="${OBJ_LIBDVDCSS} bsdi_dvdioctl.o" - LINUX_DVD_STRUCT=1 - + BUILTINS="${BUILTINS} a52" + LIB_A52="${LIB_A52} -la52" + else echo "$ac_t""no" 1>&6 fi done - fi -rm -f conftest* - ac_safe=`echo "sys/scsi/scsi_types.h" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for sys/scsi/scsi_types.h""... $ac_c" 1>&6 -echo "configure:4269: checking for sys/scsi/scsi_types.h" >&5 + +# Check whether --with- or --without- was given. +if test "${with_+set}" = set; then + withval="$with_" + : +fi + + +# Check whether --enable-x11 or --disable-x11 was given. +if test "${enable_x11+set}" = set; then + enableval="$enable_x11" + : +fi + +if test x$enable_x11 != xno && + (test x$SYS != xmingw32 || test x$enable_x11 = xyes); then + if test x$x_includes = xNONE; then + x_includes=/usr/X11R6/include + fi + if test x$x_libraries = xNONE; then + x_libraries=/usr/X11R6/lib + fi + saved_CPPFLAGS=$CPPFLAGS + CPPFLAGS="$CPPFLAGS -I$x_includes" + for ac_hdr in X11/Xlib.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:6919: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < +#include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4279: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6929: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -4291,20 +6941,54 @@ rm -f conftest* fi if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 -echo "configure:4298: checking for sys/scsi/impl/uscsi.h" >&5 +else + echo "$ac_t""no" 1>&6 +fi +done + + CPPFLAGS=$saved_CPPFLAGS +fi + +# Check whether --enable-xvideo or --disable-xvideo was given. +if test "${enable_xvideo+set}" = set; then + enableval="$enable_xvideo" + : +fi + +if test x$enable_xvideo != xno && + (test x$SYS != xmingw32 || test x$enable_xvideo = xyes); then + if test x$x_includes = xNONE; then + x_includes=/usr/X11R6/include + fi + if test x$x_libraries = xNONE; then + x_libraries=/usr/X11R6/lib + fi + saved_CPPFLAGS=$CPPFLAGS + CPPFLAGS="$CPPFLAGS -I$x_includes" + for ac_hdr in X11/extensions/Xv.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:6982: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < +#include <$ac_hdr> EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4308: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6992: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -4320,342 +7004,515 @@ rm -f conftest* fi if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 - - cat >> confdefs.h <<\EOF -#define SOLARIS_USCSI 1 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 +echo "configure:7016: checking for XvSetPortAttribute in -lXv_pic" >&5 +ac_lib_var=`echo Xv_pic'_'XvSetPortAttribute | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lXv_pic $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" else - echo "$ac_t""no" 1>&6 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" fi +rm -f conftest* +LIBS="$ac_save_LIBS" - +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + # We have Xv_pic, that's good, we can build an xvideo.so plugin ! + PLUGINS="${PLUGINS} xvideo" + LIB_XVIDEO="${LIB_XVIDEO} -L$x_libraries -lX11 -lXext -lXv_pic" + CFLAGS_XVIDEO="${CFLAGS_XVIDEO} -I$x_includes" else echo "$ac_t""no" 1>&6 +# We don't have Xv_pic, let's make xvideo.a as builtin + BUILTINS="${BUILTINS} xvideo" + LIB_XVIDEO="${LIB_XVIDEO} -L$x_libraries -lX11 -lXext -lXv" + CFLAGS_XVIDEO="${CFLAGS_XVIDEO} -I$x_includes" fi - if test x$LINUX_DVD_STRUCT = x1; then - cat >> confdefs.h <<\EOF -#define HAVE_LINUX_DVD_STRUCT 1 -EOF - - else - if test x$BSD_DVD_STRUCT = x1; then - cat >> confdefs.h <<\EOF -#define HAVE_BSD_DVD_STRUCT 1 -EOF - - fi - fi - + CFLAGS=$saved_CFLAGS + + CPPFLAGS=$saved_CPPFLAGS else echo "$ac_t""no" 1>&6 fi done +fi - -case ${target_os} in - bsdi*) - SYS=bsdi - ;; - darwin*) - SYS=darwin - ;; - *) - SYS=${target_os} - ;; -esac - -# Check whether --with-tuning or --without-tuning was given. -if test "${with_tuning+set}" = set; then - withval="$with_tuning" +# Check whether --enable-sdl or --disable-sdl was given. +if test "${enable_sdl+set}" = set; then + enableval="$enable_sdl" : fi -if test "x$withval" != "x"; then - TUNING=$withval -else - if test x${target_cpu} = xi686 -o x${target_cpu} = xi586 -o x${target_cpu} = xi486 -o x${target_cpu} = xi386; then TUNING="pentiumpro" - else - if test x${target_cpu} = xpowerpc; then TUNING="750"; fi - fi +if test "x$enable_sdl" != "xno" +then + SDL_PATH=$PATH + # Check whether --with-sdl-config-path or --without-sdl-config-path was given. +if test "${with_sdl_config_path+set}" = set; then + withval="$with_sdl_config_path" + if test "x$withval" != "xno" + then + SDL_PATH=$withval:$PATH + fi fi -# Check whether --enable-mmx or --disable-mmx was given. -if test "${enable_mmx+set}" = set; then - enableval="$enable_mmx" - if test x$enableval = xyes; then ARCH="${ARCH} mmx"; - BUILTINS="${BUILTINS} ${ACCEL_MODULES}"; fi + # Extract the first word of "sdl12-config", so it can be a program name with args. +set dummy sdl12-config; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:7093: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_SDL12_CONFIG'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 else - if test x${target_cpu} = xi686 -o x${target_cpu} = xi586 -o x${target_cpu} = xx86 -o x${target_cpu} = xi386; then ARCH="${ARCH} mmx"; - BUILTINS="${BUILTINS} ${ACCEL_MODULES}"; fi + case "$SDL12_CONFIG" in + /*) + ac_cv_path_SDL12_CONFIG="$SDL12_CONFIG" # Let the user override the test with a path. + ;; + ?:/*) + ac_cv_path_SDL12_CONFIG="$SDL12_CONFIG" # Let the user override the test with a dos path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$SDL_PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_path_SDL12_CONFIG="$ac_dir/$ac_word" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_path_SDL12_CONFIG" && ac_cv_path_SDL12_CONFIG="no" + ;; +esac fi - - -# Check whether --enable-altivec or --disable-altivec was given. -if test "${enable_altivec+set}" = set; then - enableval="$enable_altivec" - if test x$enableval = xyes; then ARCH="${ARCH} altivec"; - BUILTINS="${BUILTINS} ${ACCEL_MODULES}"; fi +SDL12_CONFIG="$ac_cv_path_SDL12_CONFIG" +if test -n "$SDL12_CONFIG"; then + echo "$ac_t""$SDL12_CONFIG" 1>&6 else - if test x${target_cpu} = xpowerpc; then ARCH="${ARCH} altivec"; - BUILTINS="${BUILTINS} ${ACCEL_MODULES}"; fi -fi - - -DEBUG=0 -# Check whether --enable-debug or --disable-debug was given. -if test "${enable_debug+set}" = set; then - enableval="$enable_debug" - if test x$enableval = xyes; then DEBUG=1; fi + echo "$ac_t""no" 1>&6 fi - -TRACE=0 -# Check whether --enable-trace or --disable-trace was given. -if test "${enable_trace+set}" = set; then - enableval="$enable_trace" - if test x$enableval = xyes; then TRACE=1; fi + SDL_CONFIG=${SDL12_CONFIG} + SDL_HEADER="SDL12/SDL.h" + if test x${SDL_CONFIG} = xno + then + # Extract the first word of "sdl11-config", so it can be a program name with args. +set dummy sdl11-config; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:7133: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_SDL11_CONFIG'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + case "$SDL11_CONFIG" in + /*) + ac_cv_path_SDL11_CONFIG="$SDL11_CONFIG" # Let the user override the test with a path. + ;; + ?:/*) + ac_cv_path_SDL11_CONFIG="$SDL11_CONFIG" # Let the user override the test with a dos path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$SDL_PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_path_SDL11_CONFIG="$ac_dir/$ac_word" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_path_SDL11_CONFIG" && ac_cv_path_SDL11_CONFIG="no" + ;; +esac fi - - -GPROF=0 -# Check whether --enable-gprof or --disable-gprof was given. -if test "${enable_gprof+set}" = set; then - enableval="$enable_gprof" - if test x$enableval = xyes; then GPROF=1; fi +SDL11_CONFIG="$ac_cv_path_SDL11_CONFIG" +if test -n "$SDL11_CONFIG"; then + echo "$ac_t""$SDL11_CONFIG" 1>&6 +else + echo "$ac_t""no" 1>&6 fi - -CPROF=0 -# Check whether --enable-cprof or --disable-cprof was given. -if test "${enable_cprof+set}" = set; then - enableval="$enable_cprof" - if test x$enableval = xyes; - then - LIB="${LIB} -lcprof" - CPROF=1 + SDL_CONFIG=${SDL11_CONFIG} + SDL_HEADER="SDL11/SDL.h" fi - + if test x${SDL_CONFIG} = xno + then + # Extract the first word of "sdl-config", so it can be a program name with args. +set dummy sdl-config; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:7174: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_SDL_CONFIG'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + case "$SDL_CONFIG" in + /*) + ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a path. + ;; + ?:/*) + ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a dos path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$SDL_PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_path_SDL_CONFIG="$ac_dir/$ac_word" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_path_SDL_CONFIG" && ac_cv_path_SDL_CONFIG="no" + ;; +esac fi - - -# Check whether --enable-optimizations or --disable-optimizations was given. -if test "${enable_optimizations+set}" = set; then - enableval="$enable_optimizations" - if test x$enableval = xno; then OPTIMS=0; fi +SDL_CONFIG="$ac_cv_path_SDL_CONFIG" +if test -n "$SDL_CONFIG"; then + echo "$ac_t""$SDL_CONFIG" 1>&6 else - OPTIMS=1 + echo "$ac_t""no" 1>&6 fi - -# Check whether --enable-pth or --disable-pth was given. -if test "${enable_pth+set}" = set; then - enableval="$enable_pth" - if test x$enableval = xyes; then - echo $ac_n "checking for pth_init in -lpth""... $ac_c" 1>&6 -echo "configure:4460: checking for pth_init in -lpth" >&5 -ac_lib_var=`echo pth'_'pth_init | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + SDL_HEADER="SDL/SDL.h" + fi + if test x${SDL_CONFIG} != xno + then + PLUGINS="${PLUGINS} sdl" + CFLAGS_SDL="${CFLAGS_SDL} `${SDL_CONFIG} --cflags`" + LIB_SDL="${LIB_SDL} `${SDL_CONFIG} --libs | sed 's,-rdynamic,,'`" + save_CPPFLAGS=$CPPFLAGS + CPPFLAGS="$CPPFLAGS $CFLAGS_SDL" + for ac_hdr in ${SDL_HEADER} +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:7220: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lpth $LIBS" -cat > conftest.$ac_ext < conftest.$ac_ext < EOF -if { (eval echo configure:4479: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7230: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + eval "ac_cv_header_$ac_safe=yes" else + echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + eval "ac_cv_header_$ac_safe=no" fi rm -f conftest* -LIBS="$ac_save_LIBS" - fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 - ac_tr_lib=HAVE_LIB`echo pth | sed -e 's/[^a-zA-Z0-9_]/_/g' \ - -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` cat >> confdefs.h <> confdefs.h < EOF - - LIBS="-lpth $LIBS" else echo "$ac_t""no" 1>&6 +{ echo "configure: error: The development package for SDL is not installed. +Please install it and try again. Alternatively you can also configure with +--disable-sdl." 1>&2; exit 1; } + fi +done - cat > conftest.$ac_ext < -EOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "pth_init" >/dev/null 2>&1; then - rm -rf conftest* - - cat >> confdefs.h <<\EOF -#define PTH_INIT_IN_PTH_H 1 -EOF - - THREAD_LIB="-lpth" + CPPFLAGS=$save_CPPFLAGS + if expr 1.1.5 \> `$SDL_CONFIG --version` >/dev/null + then + { echo "configure: error: The development package for SDL is not installed. +Please install it and try again. Alternatively you can also configure with +--disable-sdl." 1>&2; exit 1; } fi + elif test "x$enable_sdl" = "xyes" + then + { echo "configure: error: I couldn't find the SDL package. You can download libSDL +from http://www.libsdl.org/, or configure with --disable-sdl. Have a nice day. + " 1>&2; exit 1; } + fi fi -rm -f conftest* - +# Check whether --enable-directx or --disable-directx was given. +if test "${enable_directx+set}" = set; then + enableval="$enable_directx" + : fi +if test "x$enableval" != "xno" +then + if test x$SYS = xmingw32 + then + # Check whether --with-directx or --without-directx was given. +if test "${with_directx+set}" = set; then + withval="$with_directx" + : +fi -LIB="${LIB} ${THREAD_LIB}" - -NEED_LIBDVDCSS=0 -STATIC_LIBDVDCSS=0 -DUMMY_LIBDVDCSS=0 -# Check whether --with-dvdcss or --without-dvdcss was given. -if test "${with_dvdcss+set}" = set; then - withval="$with_dvdcss" - case "x${withval}" in - xlocal-static|xyes) - # local libdvdcss, statically linked - if test x${CAN_BUILD_LIBDVDCSS} = x1 - then - NEED_LIBDVDCSS=1 - STATIC_LIBDVDCSS=1 - BUILTINS="${BUILTINS} dvd" - CFLAGS_DVD="${CFLAGS_DVD} -I../../extras/libdvdcss" - LIB_DVD="${LIB_DVD} lib/libdvdcss.a ${LIB_LIBDVDCSS}" - LIB_DVD_PLUGIN="${LIB_DVD_PLUGIN} ../../lib/libdvdcss.a ${LIB_LIBDVDCSS}" - fi - ;; - xlocal-shared) - # local libdvdcss, dynamically linked - if test x${CAN_BUILD_LIBDVDCSS} = x1 - then - NEED_LIBDVDCSS=1 - BUILTINS="${BUILTINS} dvd" - CFLAGS_DVD="${CFLAGS_DVD} -I../../extras/libdvdcss" - LIB_DVD="${LIB_DVD} -Llib -ldvdcss" - LIB_DVD_PLUGIN="${LIB_DVD_PLUGIN} -L../../lib -ldvdcss" - fi - ;; - xno) - # don't use libdvdcss at all, build a DVD module that can dlopen() it - DUMMY_LIBDVDCSS=1 - BUILTINS="${BUILTINS} dvd" - OBJ_DVD="${OBJ_DVD} dummy_dvdcss.o" - CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA" - CFLAGS_DVD="${CFLAGS_DVD} -DLIBDVDCSS_VERSION=\"${LIBDVDCSS_VERSION}\"" - LIB_DVD="${LIB_DVD} -ldl" - LIB_DVD_PLUGIN="${LIB_DVD_PLUGIN} -ldl" - ;; - *) - # existing libdvdcss - BUILTINS="${BUILTINS} dvd" - if test "x$withval" != "xyes" - then - LIB_DVD_PLUGIN="${LIB_DVD_PLUGIN} -L"$withval"/lib" - CFLAGS_DVD="${CFLAGS_DVD} -I"$withval"/include" - fi - LIB_DVD="${LIB_DVD} -ldvdcss" - LIB_DVD_PLUGIN="${LIB_DVD_PLUGIN} -ldvdcss" - esac -else - # user didn't decide, we choose to use local libdvdcss and link statically - # if libdvdcss is in the archive, or to use the dummy replacement otherwise. - if test x${CAN_BUILD_LIBDVDCSS} = x1 + if test "x$with_directx" = "x" then - NEED_LIBDVDCSS=1 - STATIC_LIBDVDCSS=1 - BUILTINS="${BUILTINS} dvd" - CFLAGS_DVD="${CFLAGS_DVD} -I../../extras/libdvdcss" - LIB_DVD="${LIB_DVD} lib/libdvdcss.a ${LIB_LIBDVDCSS}" - LIB_DVD_PLUGIN="${LIB_DVD_PLUGIN} ../../lib/libdvdcss.a ${LIB_LIBDVDCSS}" - else - # XXX: no check for libdl is done, don't try this at home ! - DUMMY_LIBDVDCSS=1 - BUILTINS="${BUILTINS} dvd" - OBJ_DVD="${OBJ_DVD} dummy_dvdcss.o" - CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA" - LIB_DVD="${LIB_DVD} -ldl" - LIB_DVD_PLUGIN="${LIB_DVD_PLUGIN} -ldl" - fi + for ac_hdr in ddraw.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:7300: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7310: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 fi +done + else + echo $ac_n "checking for directX headers in ${withval}""... $ac_c" 1>&6 +echo "configure:7339: checking for directX headers in ${withval}" >&5 + if test -f ${withval}/ddraw.h + then + PLUGINS="${PLUGINS} directx" + LIB_DIRECTX="${LIB_DIRECTX} -L${withval}/lib -lgdi32" + INCLUDE="${INCLUDE} -I${withval}" + echo "$ac_t""yes" 1>&6 + else + echo "$ac_t""no" 1>&6 + { echo "configure: error: Cannot find ${withval}/ddraw.h!" 1>&2; exit 1; } + fi + fi + fi +fi +# Check whether --enable-fb or --disable-fb was given. +if test "${enable_fb+set}" = set; then + enableval="$enable_fb" + : +fi + if test x$enable_fb != xno + then + for ac_hdr in linux/fb.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:7366: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7376: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 +fi +done + fi -# Check whether --enable-vcd or --disable-vcd was given. -if test "${enable_vcd+set}" = set; then - enableval="$enable_vcd" - if test x$enable_vcd = xyes; then - PLUGINS="${PLUGINS} vcd" - fi +# Check whether --enable-mga or --disable-mga was given. +if test "${enable_mga+set}" = set; then + enableval="$enable_mga" + if test x$enable_mga = xyes + then + PLUGINS="${PLUGINS} mga xmga" + fi fi - -# Check whether --enable-dummy or --disable-dummy was given. -if test "${enable_dummy+set}" = set; then - enableval="$enable_dummy" +# Check whether --enable-ggi or --disable-ggi was given. +if test "${enable_ggi+set}" = set; then + enableval="$enable_ggi" : fi - -if test x$enable_dummy != xno +if test x$enable_ggi = xyes then - BUILTINS="${BUILTINS} dummy" + PLUGINS="${PLUGINS} ggi" + LIB_GGI="${LIB_GGI} -lggi" + # Check whether --with-ggi or --without-ggi was given. +if test "${with_ggi+set}" = set; then + withval="$with_ggi" + if test "x$with_val" != "xno" -a "x$with_val" != "x" + then + CFLAGS_GGI="${CFLAGS_GGI} -I$with_val/include" + LIB_GGI="${LIB_GGI} -L$with_val/lib" + fi fi -# Check whether --enable-null or --disable-null was given. -if test "${enable_null+set}" = set; then - enableval="$enable_null" - : fi +# Check whether --enable-glide or --disable-glide was given. +if test "${enable_glide+set}" = set; then + enableval="$enable_glide" + : +fi -if test x$enable_null != xno +if test x$enable_glide = xyes then - BUILTINS="${BUILTINS} null" + PLUGINS="${PLUGINS} glide" + LIB_GLIDE="${LIB_GLIDE} -lglide2x -lm" + CFLAGS_GLIDE="${CFLAGS_GLIDE} -I/usr/include/glide" + # Check whether --with-glide or --without-glide was given. +if test "${with_glide+set}" = set; then + withval="$with_glide" + if test "x$with_val" != "xno" -a "x$with_val" != "x" + then + CFLAGS_GLIDE="${CFLAGS_GLIDE} -I$with_val/include" + LIB_GLIDE="${LIB_GLIDE} -L$with_val/lib" + fi fi -# Check whether --enable-rc or --disable-rc was given. -if test "${enable_rc+set}" = set; then - enableval="$enable_rc" - : fi +# Check whether --enable-aa or --disable-aa was given. +if test "${enable_aa+set}" = set; then + enableval="$enable_aa" + : +fi -if test x$enable_rc != xno +if test x$enable_aa = xyes then - BUILTINS="${BUILTINS} rc" + ac_safe=`echo "aalib.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for aalib.h""... $ac_c" 1>&6 +echo "configure:7471: checking for aalib.h" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7481: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + have_aa="true" +else + echo "$ac_t""no" 1>&6 +have_aa="false" fi -if test x$SYS = xbeos -then - BUILTINS="${BUILTINS} beos" - LIB_BEOS="-lbe -lgame -lroot -ltracker" - PLCFLAGS="${PLCFLAGS} -nostart" + if test x$have_aa = xtrue + then + PLUGINS="${PLUGINS} aa" + LIB_AA="${LIB_AA} -laa" + fi +fi + + +# Check whether --with- or --without- was given. +if test "${with_+set}" = set; then + withval="$with_" + : +fi -else # Check whether --enable-dsp or --disable-dsp was given. if test "${enable_dsp+set}" = set; then @@ -4664,12 +7521,87 @@ if test "${enable_dsp+set}" = set; then fi -if test x$enable_dsp != xno +if test x$enable_dsp != xno && + (test x$SYS != xmingw32 || test x$enable_dsp = xyes) then - if test -c /dev/dsp - then + for ac_hdr in soundcard.h sys/soundcard.h machine/soundcard.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:7532: checking for $ac_hdr" >&5 +if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7542: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +fi +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + cat >> confdefs.h <&6 +echo "configure:7565: checking for main in -lossaudio" >&5 +ac_lib_var=`echo ossaudio'_'main | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-lossaudio $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + LIB_DSP="${LIB_DSP} -lossaudio" +else + echo "$ac_t""no" 1>&6 +fi + + +else + echo "$ac_t""no" 1>&6 +fi +done + fi # Check whether --enable-esd or --disable-esd was given. @@ -4680,7 +7612,7 @@ if test "${enable_esd+set}" = set; then # Extract the first word of "esd-config", so it can be a program name with args. set dummy esd-config; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:4684: checking for $ac_word" >&5 +echo "configure:7616: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_path_ESD_CONFIG'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -4716,48 +7648,82 @@ fi if test x${ESD_CONFIG} != xno then PLUGINS="${PLUGINS} esd" - LIB_ESD="`${ESD_CONFIG} --libs`" + CFLAGS_ESD="${CFLAGS_ESD} `${ESD_CONFIG} --cflags`" + LIB_ESD="${LIB_ESD} `${ESD_CONFIG} --libs`" fi fi fi -# Check whether --enable-darwin or --disable-darwin was given. -if test "${enable_darwin+set}" = set; then - enableval="$enable_darwin" - if test x$enable_darwin = xyes; then - PLUGINS="${PLUGINS} darwin" - LIB_DARWIN="-framework CoreAudio" +# Check whether --enable-arts or --disable-arts was given. +if test "${enable_arts+set}" = set; then + enableval="$enable_arts" + if test x$enable_arts = xyes + then + # Extract the first word of "artsc-config", so it can be a program name with args. +set dummy artsc-config; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:7667: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_ARTS_CONFIG'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + case "$ARTS_CONFIG" in + /*) + ac_cv_path_ARTS_CONFIG="$ARTS_CONFIG" # Let the user override the test with a path. + ;; + ?:/*) + ac_cv_path_ARTS_CONFIG="$ARTS_CONFIG" # Let the user override the test with a dos path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_path_ARTS_CONFIG="$ac_dir/$ac_word" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_path_ARTS_CONFIG" && ac_cv_path_ARTS_CONFIG="no" + ;; +esac +fi +ARTS_CONFIG="$ac_cv_path_ARTS_CONFIG" +if test -n "$ARTS_CONFIG"; then + echo "$ac_t""$ARTS_CONFIG" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + + if test x${ARTS_CONFIG} != xno + then + PLUGINS="${PLUGINS} arts" + CFLAGS_ARTS="${CFLAGS_ARTS} `${ARTS_CONFIG} --cflags`" + LIB_ARTS="${LIB_ARTS} `${ARTS_CONFIG} --libs `" + fi fi fi -# Check whether --enable-macosx or --disable-macosx was given. -if test "${enable_macosx+set}" = set; then - enableval="$enable_macosx" - if test x$enable_macosx = xyes +# Check whether --enable-alsa or --disable-alsa was given. +if test "${enable_alsa+set}" = set; then + enableval="$enable_alsa" + if test x$enable_alsa = xyes then - BUILTINS="${BUILTINS} macosx macosx_qt" - LIB_MACOSX="-framework CoreAudio -framework Carbon -framework AGL -framework QuickTime" - LIB_TS="${LIB_TS} -framework AGL -framework Carbon" - LIB_SDL="${LIB_SDL} -framework AGL -framework Carbon" - fi -else - for ac_hdr in Carbon/Carbon.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4751: checking for $ac_hdr" >&5 + ac_safe=`echo "alsa/asoundlib.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for alsa/asoundlib.h""... $ac_c" 1>&6 +echo "configure:7717: checking for alsa/asoundlib.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < +#include EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4761: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7727: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -4773,261 +7739,199 @@ rm -f conftest* fi if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 -fi -done - -fi - - -# Check whether --enable-qnx or --disable-qnx was given. -if test "${enable_qnx+set}" = set; then - enableval="$enable_qnx" - : -fi - - if test x$enable_qnx != xno - then - for ac_hdr in Ph.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:4806: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "checking for main in -lasound""... $ac_c" 1>&6 +echo "configure:7744: checking for main in -lasound" >&5 +ac_lib_var=`echo asound'_'main | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < conftest.$ac_ext < + +int main() { +main() +; return 0; } EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4816: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then +if { (eval echo configure:7759: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" + eval "ac_cv_lib_$ac_lib_var=yes" else - echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" + eval "ac_cv_lib_$ac_lib_var=no" fi rm -f conftest* +LIBS="$ac_save_LIBS" + fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 +have_alsa="false" fi -done - fi +else + echo "$ac_t""no" 1>&6 +have_alsa="false" +fi -# Check whether --enable-fb or --disable-fb was given. -if test "${enable_fb+set}" = set; then - enableval="$enable_fb" - if test x$enable_fb = xyes - then - PLUGINS="${PLUGINS} fb" - fi + if test x$have_alsa = xtrue + then + PLUGINS="${PLUGINS} alsa" + LIB_ALSA="${LIB_ALSA} -lasound -lm -ldl" + fi + fi fi -# Check whether --with-ggi or --without-ggi was given. -if test "${with_ggi+set}" = set; then - withval="$with_ggi" - if test "x$withval" != "xno" - then - PLUGINS="${PLUGINS} ggi" - if test "x$withval" != "xyes" - then - LIB_GGI="-l"$withval - else - LIB_GGI="-lggi" - fi - fi +# Check whether --enable-waveout or --disable-waveout was given. +if test "${enable_waveout+set}" = set; then + enableval="$enable_waveout" + : fi +if test "x$enableval" != "xno" -a x$SYS = xmingw32 + then + PLUGINS="${PLUGINS} waveout" + LIB_WAVEOUT="-lwinmm" +fi -# Check whether --enable-sdl or --disable-sdl was given. -if test "${enable_sdl+set}" = set; then - enableval="$enable_sdl" + +# Check whether --with- or --without- was given. +if test "${with_+set}" = set; then + withval="$with_" : fi -if test "x$enable_sdl" != "xno" + +# Check whether --enable-gtk or --disable-gtk was given. +if test "${enable_gtk+set}" = set; then + enableval="$enable_gtk" + : +fi + +if test x$enable_gtk != xno then - SDL_PATH=$PATH - # Check whether --with-sdl-config-path or --without-sdl-config-path was given. -if test "${with_sdl_config_path+set}" = set; then - withval="$with_sdl_config_path" + GTK_PATH=$PATH + # Check whether --with-gtk-config-path or --without-gtk-config-path was given. +if test "${with_gtk_config_path+set}" = set; then + withval="$with_gtk_config_path" if test "x$withval" != "xno" then - SDL_PATH=$withval:$PATH + GTK_PATH=$withval:$PATH fi fi - # Extract the first word of "sdl12-config", so it can be a program name with args. -set dummy sdl12-config; ac_word=$2 + # look for gtk-config + # Extract the first word of "gtk12-config", so it can be a program name with args. +set dummy gtk12-config; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:4894: checking for $ac_word" >&5 -if eval "test \"`echo '$''{'ac_cv_path_SDL12_CONFIG'+set}'`\" = set"; then +echo "configure:7836: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_GTK12_CONFIG'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - case "$SDL12_CONFIG" in + case "$GTK12_CONFIG" in /*) - ac_cv_path_SDL12_CONFIG="$SDL12_CONFIG" # Let the user override the test with a path. + ac_cv_path_GTK12_CONFIG="$GTK12_CONFIG" # Let the user override the test with a path. ;; ?:/*) - ac_cv_path_SDL12_CONFIG="$SDL12_CONFIG" # Let the user override the test with a dos path. + ac_cv_path_GTK12_CONFIG="$GTK12_CONFIG" # Let the user override the test with a dos path. ;; *) IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="$SDL_PATH" + ac_dummy="$GTK_PATH" for ac_dir in $ac_dummy; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then - ac_cv_path_SDL12_CONFIG="$ac_dir/$ac_word" + ac_cv_path_GTK12_CONFIG="$ac_dir/$ac_word" break fi done IFS="$ac_save_ifs" - test -z "$ac_cv_path_SDL12_CONFIG" && ac_cv_path_SDL12_CONFIG="no" + test -z "$ac_cv_path_GTK12_CONFIG" && ac_cv_path_GTK12_CONFIG="no" ;; esac fi -SDL12_CONFIG="$ac_cv_path_SDL12_CONFIG" -if test -n "$SDL12_CONFIG"; then - echo "$ac_t""$SDL12_CONFIG" 1>&6 +GTK12_CONFIG="$ac_cv_path_GTK12_CONFIG" +if test -n "$GTK12_CONFIG"; then + echo "$ac_t""$GTK12_CONFIG" 1>&6 else echo "$ac_t""no" 1>&6 fi - SDL_CONFIG=${SDL12_CONFIG} - SDL_HEADER="SDL12/SDL.h" - if test x${SDL_CONFIG} = xno + GTK_CONFIG=${GTK12_CONFIG} + if test x${GTK_CONFIG} = xno then - # Extract the first word of "sdl11-config", so it can be a program name with args. -set dummy sdl11-config; ac_word=$2 + # Extract the first word of "gtk-config", so it can be a program name with args. +set dummy gtk-config; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:4934: checking for $ac_word" >&5 -if eval "test \"`echo '$''{'ac_cv_path_SDL11_CONFIG'+set}'`\" = set"; then +echo "configure:7875: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_GTK_CONFIG'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - case "$SDL11_CONFIG" in + case "$GTK_CONFIG" in /*) - ac_cv_path_SDL11_CONFIG="$SDL11_CONFIG" # Let the user override the test with a path. + ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a path. ;; ?:/*) - ac_cv_path_SDL11_CONFIG="$SDL11_CONFIG" # Let the user override the test with a dos path. + ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a dos path. ;; *) IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="$SDL_PATH" + ac_dummy="$GTK_PATH" for ac_dir in $ac_dummy; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then - ac_cv_path_SDL11_CONFIG="$ac_dir/$ac_word" + ac_cv_path_GTK_CONFIG="$ac_dir/$ac_word" break fi done IFS="$ac_save_ifs" - test -z "$ac_cv_path_SDL11_CONFIG" && ac_cv_path_SDL11_CONFIG="no" + test -z "$ac_cv_path_GTK_CONFIG" && ac_cv_path_GTK_CONFIG="no" ;; esac fi -SDL11_CONFIG="$ac_cv_path_SDL11_CONFIG" -if test -n "$SDL11_CONFIG"; then - echo "$ac_t""$SDL11_CONFIG" 1>&6 +GTK_CONFIG="$ac_cv_path_GTK_CONFIG" +if test -n "$GTK_CONFIG"; then + echo "$ac_t""$GTK_CONFIG" 1>&6 else echo "$ac_t""no" 1>&6 fi - SDL_CONFIG=${SDL11_CONFIG} - SDL_HEADER="SDL11/SDL.h" fi - if test x${SDL_CONFIG} = xno + if test x${GTK_CONFIG} != xno then - # Extract the first word of "sdl-config", so it can be a program name with args. -set dummy sdl-config; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:4975: checking for $ac_word" >&5 -if eval "test \"`echo '$''{'ac_cv_path_SDL_CONFIG'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - case "$SDL_CONFIG" in - /*) - ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a path. - ;; - ?:/*) - ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a dos path. - ;; - *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="$SDL_PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_path_SDL_CONFIG="$ac_dir/$ac_word" - break + if expr 1.2.0 \> `$GTK_CONFIG --version` >/dev/null + then + { echo "configure: error: Your development package for Gtk+ is too old, you need at least version 1.2.0. Please upgrade and try again. Alternatively you can also configure with --disable-gtk." 1>&2; exit 1; } fi - done - IFS="$ac_save_ifs" - test -z "$ac_cv_path_SDL_CONFIG" && ac_cv_path_SDL_CONFIG="no" - ;; -esac -fi -SDL_CONFIG="$ac_cv_path_SDL_CONFIG" -if test -n "$SDL_CONFIG"; then - echo "$ac_t""$SDL_CONFIG" 1>&6 -else - echo "$ac_t""no" 1>&6 -fi - - SDL_HEADER="SDL/SDL.h" - fi - if test x${SDL_CONFIG} != xno - then - PLUGINS="${PLUGINS} sdl" - CFLAGS_SDL="`${SDL_CONFIG} --cflags`" - LIB_SDL="`${SDL_CONFIG} --libs | sed 's,-rdynamic,,'`" - save_CPPFLAGS=$CPPFLAGS - CPPFLAGS="$CPPFLAGS $CFLAGS_SDL" - for ac_hdr in ${SDL_HEADER} + CFLAGS_GTK="${CFLAGS_GTK} `${GTK_CONFIG} --cflags gtk`" + LIB_GTK="${LIB_GTK} `${GTK_CONFIG} --libs gtk | sed 's,-rdynamic,,'`" + # now look for the gtk.h header + saved_CPPFLAGS=$CPPFLAGS + CPPFLAGS="$CPPFLAGS $CFLAGS_GTK" + ac_cv_gtk_headers=yes + for ac_hdr in gtk/gtk.h glib.h gdk/gdk.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:5021: checking for $ac_hdr" >&5 +echo "configure:7925: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5031: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7935: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -5047,109 +7951,88 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then cat >> confdefs.h <> confdefs.h < -EOF - + else echo "$ac_t""no" 1>&6 -{ echo "configure: error: The development package for SDL is not installed. -Please install it and try again. Alternatively you can also configure with ---disable-sdl." 1>&2; exit 1; } - +ac_cv_gtk_headers=no + echo "Cannot find gtk development headers." + fi done - CPPFLAGS=$save_CPPFLAGS - if expr 1.1.5 \> `$SDL_CONFIG --version` >/dev/null + if test "x$ac_cv_gtk_headers" = xyes then - { echo "configure: error: The development package for SDL is not installed. -Please install it and try again. Alternatively you can also configure with ---disable-sdl." 1>&2; exit 1; } + PLUGINS="${PLUGINS} gtk" + ALIASES="${ALIASES} gvlc" fi - elif test "x$enable_sdl" = "xyes" - then - { echo "configure: error: I couldn't find the SDL package. You can download libSDL -from http://www.libsdl.org/, or configure with --disable-sdl. Have a nice day. - " 1>&2; exit 1; } + CPPFLAGS=$saved_CPPFLAGS fi fi -# Check whether --with-directx or --without-directx was given. -if test "${with_directx+set}" = set; then - withval="$with_directx" - if test "x$withval" != "xno" - then - PLUGINS="${PLUGINS} directx" - if test "x$withval" != "xyes" - then - LIB_DIRECTX="${LIB_DIRECTX} -L"$withval"/lib -lgdi32 -ldxguid" - INCLUDE="${INCLUDE} -I"$withval"/include" - else - for ac_hdr in directx.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:5094: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then +# Check whether --enable-gnome or --disable-gnome was given. +if test "${enable_gnome+set}" = set; then + enableval="$enable_gnome" + if test x$enable_gnome = xyes; then + # look for gnome-config + # Extract the first word of "gnome-config", so it can be a program name with args. +set dummy gnome-config; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:7981: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_GNOME_CONFIG'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < -EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5104: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then - rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" -else - echo "$ac_err" >&5 - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" -fi -rm -f conftest* + case "$GNOME_CONFIG" in + /*) + ac_cv_path_GNOME_CONFIG="$GNOME_CONFIG" # Let the user override the test with a path. + ;; + ?:/*) + ac_cv_path_GNOME_CONFIG="$GNOME_CONFIG" # Let the user override the test with a dos path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_path_GNOME_CONFIG="$ac_dir/$ac_word" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_path_GNOME_CONFIG" && ac_cv_path_GNOME_CONFIG="no" + ;; +esac fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 else echo "$ac_t""no" 1>&6 -{ echo "configure: error: Cannot find DirectX headers !" 1>&2; exit 1; } - -fi -done - - LIB_DIRECTX="${LIB_DIRECTX} -L/usr/lib -lgdi32 -ldxguid" - fi - fi fi - if test "x$withval" = "x" + if test -x ${GNOME_CONFIG} then - for ac_hdr in directx.h + CFLAGS_GNOME="${CFLAGS_GNOME} `${GNOME_CONFIG} --cflags gtk gnomeui`" + LIB_GNOME="${LIB_GNOME} `${GNOME_CONFIG} --libs gnomeui | sed 's,-rdynamic,,'`" + fi + # now look for the gnome.h header + saved_CPPFLAGS=$CPPFLAGS + CPPFLAGS="$CPPFLAGS $CFLAGS_GNOME" + for ac_hdr in gnome.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:5143: checking for $ac_hdr" >&5 +echo "configure:8026: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5153: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:8036: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -5169,38 +8052,21 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then cat >> confdefs.h <&6 +{ echo "configure: error: Can't find gnome headers. Please install the gnome +developement librairie or remove the --enable-gnome option" 1>&2; exit 1; } + fi done - fi - -# Check whether --with-glide or --without-glide was given. -if test "${with_glide+set}" = set; then - withval="$with_glide" - if test "x$withval" != "xno" - then - PLUGINS="${PLUGINS} glide" - if test "x$withval" != "xyes" - then - LIB_GLIDE="-l"$withval" -lm" - else - LIB_GLIDE="-lglide2x -lm" - fi - fi -fi - - -# Check whether --enable-ncurses or --disable-ncurses was given. -if test "${enable_ncurses+set}" = set; then - enableval="$enable_ncurses" - if test x$enable_ncurses = xyes; then - PLUGINS="${PLUGINS} ncurses" - LIB_NCURSES="-lncurses" - fi + + CPPFLAGS=$saved_CPPFLAGS + fi fi @@ -5210,7 +8076,8 @@ if test "${enable_qt+set}" = set; then if test x$enable_qt = xyes; then PLUGINS="${PLUGINS} qt" ALIASES="${ALIASES} qvlc" - LIB_QT="-lqt -L${QTDIR}/lib" + LIB_QT="${LIB_QT} -lqt -L${QTDIR}/lib" + CFLAGS_QT="${CFLAGS_QT} -I/usr/include/qt -I${QTDIR}/include" if test -x ${QTDIR}/bin/moc then MOC=${QTDIR}/bin/moc @@ -5227,7 +8094,9 @@ if test "${enable_kde+set}" = set; then if test x$enable_kde = xyes; then PLUGINS="${PLUGINS} kde" ALIASES="${ALIASES} kvlc" - LIB_KDE="-L${KDEDIR}/lib -lkfile" + LIB_KDE="${LIB_KDE} -L${KDEDIR}/lib -lkfile" + CFLAGS_KDE="${CFLAGS_KDE} -I/usr/include/kde -I/usr/include/qt" + CFLAGS_KDE="${CFLAGS_KDE} -I${KDEDIR}/include -I${QTDIR}/include" if test -x ${QTDIR}/bin/moc then MOC=${QTDIR}/bin/moc @@ -5238,70 +8107,32 @@ if test "${enable_kde+set}" = set; then fi -# Check whether --enable-gnome or --disable-gnome was given. -if test "${enable_gnome+set}" = set; then - enableval="$enable_gnome" - if test x$enable_gnome = xyes; then - # look for gnome-config - # Extract the first word of "gnome-config", so it can be a program name with args. -set dummy gnome-config; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:5250: checking for $ac_word" >&5 -if eval "test \"`echo '$''{'ac_cv_path_GNOME_CONFIG'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - case "$GNOME_CONFIG" in - /*) - ac_cv_path_GNOME_CONFIG="$GNOME_CONFIG" # Let the user override the test with a path. - ;; - ?:/*) - ac_cv_path_GNOME_CONFIG="$GNOME_CONFIG" # Let the user override the test with a dos path. - ;; - *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_path_GNOME_CONFIG="$ac_dir/$ac_word" - break - fi - done - IFS="$ac_save_ifs" - test -z "$ac_cv_path_GNOME_CONFIG" && ac_cv_path_GNOME_CONFIG="no" - ;; -esac -fi -GNOME_CONFIG="$ac_cv_path_GNOME_CONFIG" -if test -n "$GNOME_CONFIG"; then - echo "$ac_t""$GNOME_CONFIG" 1>&6 +# Check whether --enable-macosx or --disable-macosx was given. +if test "${enable_macosx+set}" = set; then + enableval="$enable_macosx" + if test x$enable_macosx = xyes + then + BUILTINS="${BUILTINS} macosx" + LIB_MACOSX="${LIB_MACOSX} -framework CoreAudio -framework AudioToolbox -framework Cocoa -framework AGL -framework QuickTime -lobjc" + CFLAGS_MACOSX="${CFLAGS_MACOSX} -ObjC" + LIB_COMMON="${LIB_COMMON} -ObjC" + fi else - echo "$ac_t""no" 1>&6 -fi - - if test -x ${GNOME_CONFIG} - then - CFLAGS_GNOME="`${GNOME_CONFIG} --cflags gnomeui`" - LIB_GNOME="`${GNOME_CONFIG} --libs gnomeui | sed 's,-rdynamic,,'`" - fi - # now look for the gnome.h header - saved_CPPFLAGS=$CPPFLAGS - CPPFLAGS="$CPPFLAGS $CFLAGS_GNOME" - for ac_hdr in gnome.h + for ac_hdr in Cocoa/Cocoa.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:5295: checking for $ac_hdr" >&5 +echo "configure:8126: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5305: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:8136: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -5321,92 +8152,42 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then cat >> confdefs.h <&6 -{ echo "configure: error: Can't find gnome headers. Please install the gnome -developement librairie or remove the --enable-gnome option" 1>&2; exit 1; } - fi done - - CPPFLAGS=$saved_CPPFLAGS - fi fi -# Check whether --enable-gtk or --disable-gtk was given. -if test "${enable_gtk+set}" = set; then - enableval="$enable_gtk" +# Check whether --enable-qnx or --disable-qnx was given. +if test "${enable_qnx+set}" = set; then + enableval="$enable_qnx" : fi -if test x$enable_gtk != xno -then - # look for gtk-config - # Extract the first word of "gtk-config", so it can be a program name with args. -set dummy gtk-config; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:5355: checking for $ac_word" >&5 -if eval "test \"`echo '$''{'ac_cv_path_GTK_CONFIG'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - case "$GTK_CONFIG" in - /*) - ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a path. - ;; - ?:/*) - ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a dos path. - ;; - *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_path_GTK_CONFIG="$ac_dir/$ac_word" - break - fi - done - IFS="$ac_save_ifs" - test -z "$ac_cv_path_GTK_CONFIG" && ac_cv_path_GTK_CONFIG="no" - ;; -esac -fi -GTK_CONFIG="$ac_cv_path_GTK_CONFIG" -if test -n "$GTK_CONFIG"; then - echo "$ac_t""$GTK_CONFIG" 1>&6 -else - echo "$ac_t""no" 1>&6 -fi - - if test -x ${GTK_CONFIG} - then - CFLAGS_GTK="`${GTK_CONFIG} --cflags gtk`" - LIB_GTK="`${GTK_CONFIG} --libs gtk | sed 's,-rdynamic,,'`" - fi - # now look for the gtk.h header - saved_CPPFLAGS=$CPPFLAGS - CPPFLAGS="$CPPFLAGS $CFLAGS_GTK" - for ac_hdr in gtk/gtk.h + if test x$enable_qnx != xno + then + for ac_hdr in Ph.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:5400: checking for $ac_hdr" >&5 +echo "configure:8181: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5410: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:8191: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -5427,47 +8208,57 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then #define $ac_tr_hdr 1 EOF - PLUGINS="${PLUGINS} gtk" - ALIASES="${ALIASES} gvlc" - + PLUGINS="${PLUGINS} qnx" + LIB_QNX="${LIB_QNX} -lasound -lph" + else echo "$ac_t""no" 1>&6 fi done - CPPFLAGS=$saved_CPPFLAGS + fi + +# Check whether --enable-win32 or --disable-win32 was given. +if test "${enable_win32+set}" = set; then + enableval="$enable_win32" + if test "x$enableval" != "xno" + then + PLUGINS="${PLUGINS} win32" + fi fi -# Check whether --enable-x11 or --disable-x11 was given. -if test "${enable_x11+set}" = set; then - enableval="$enable_x11" + +# Check whether --enable-ncurses or --disable-ncurses was given. +if test "${enable_ncurses+set}" = set; then + enableval="$enable_ncurses" + if test x$enable_ncurses = xyes; then + PLUGINS="${PLUGINS} ncurses" + LIB_NCURSES="${LIB_NCURSES} -lncurses" + fi +fi + + +# Check whether --enable-lirc or --disable-lirc was given. +if test "${enable_lirc+set}" = set; then + enableval="$enable_lirc" : fi -if test x$enable_x11 != xno; then - if test x$x_includes = xNONE; then - x_includes=/usr/X11R6/include - fi - if test x$x_libraries = xNONE; then - x_libraries=/usr/X11R6/lib - fi - saved_CPPFLAGS=$CPPFLAGS - CPPFLAGS="$CPPFLAGS -I$x_includes" - for ac_hdr in X11/Xlib.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:5461: checking for $ac_hdr" >&5 +if test x$enable_lirc = xyes +then + ac_safe=`echo "lirc/lirc_client.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for lirc/lirc_client.h""... $ac_c" 1>&6 +echo "configure:8252: checking for lirc/lirc_client.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < +#include EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5471: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:8262: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -5483,135 +8274,261 @@ rm -f conftest* fi if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` - cat >> confdefs.h <&6 +echo "configure:8279: checking for lirc_init in -llirc_client" >&5 +ac_lib_var=`echo lirc_client'_'lirc_init | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LIBS="$LIBS" +LIBS="-llirc_client $LIBS" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +LIBS="$ac_save_LIBS" + +fi +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + echo "$ac_t""yes" 1>&6 + have_lirc="true" +else + echo "$ac_t""no" 1>&6 +have_lirc="false" +fi + +else + echo "$ac_t""no" 1>&6 +have_lirc="false" +fi + + if test x$have_lirc = xtrue + then + PLUGINS="${PLUGINS} lirc" + LIB_LIRC="${LIB_LIRC} -llirc_client" + fi +fi + +fi + +# Check whether --with- or --without- was given. +if test "${with_+set}" = set; then + withval="$with_" + : +fi + + +# Check whether --with-words or --without-words was given. +if test "${with_words+set}" = set; then + withval="$with_words" + : +fi + + case "x$withval" in + xbig) + ac_cv_c_bigendian=yes + ;; + xlittle) + ac_cv_c_bigendian=no + ;; + *) + echo $ac_n "checking whether the byte order is big-endian""... $ac_c" 1>&6 +echo "configure:8355: checking whether the byte order is big-endian" >&5 +if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_cv_c_bigendian=unknown + cat >conftest.c <config.log 2>&1 \ + && test -f conftest.o + then + if test "`strings conftest.o | grep BIGenDianSyS`" + then + ac_cv_c_bigendian=yes + fi + if test "`strings conftest.o | grep LiTTleEnDian`" + then + ac_cv_c_bigendian=no + fi + fi + fi + +fi + +echo "$ac_t""$ac_cv_c_bigendian" 1>&6 + if test x$ac_cv_c_bigendian = xunknown + then + { echo "configure: error: Could not guess endianness, please use --with-words" 1>&2; exit 1; } + fi + ;; + esac +if test $ac_cv_c_bigendian = yes +then + cat >> confdefs.h <<\EOF +#define WORDS_BIGENDIAN 1 EOF - - PLUGINS="${PLUGINS} x11" - LIB_X11="-L$x_libraries -lX11 -lXext" - CFLAGS_X11="-I$x_includes" - - CPPFLAGS=$saved_CPPFLAGS -else - echo "$ac_t""no" 1>&6 + fi -done +DLL_PATH=. +# Check whether --with-dll-path or --without-dll-path was given. +if test "${with_dll_path+set}" = set; then + withval="$with_dll_path" + if test "x$withval" != "xno" + then + DLL_PATH=$withval + fi fi -# Check whether --enable-xvideo or --disable-xvideo was given. -if test "${enable_xvideo+set}" = set; then - enableval="$enable_xvideo" - : + +GPROF=0 +# Check whether --enable-gprof or --disable-gprof was given. +if test "${enable_gprof+set}" = set; then + enableval="$enable_gprof" + if test x$enableval = xyes; then GPROF=1; fi fi -if test x$enable_xvideo != xno; then - if test x$x_includes = xNONE; then - x_includes=/usr/X11R6/include - fi - if test x$x_libraries = xNONE; then - x_libraries=/usr/X11R6/lib + +CPROF=0 +# Check whether --enable-cprof or --disable-cprof was given. +if test "${enable_cprof+set}" = set; then + enableval="$enable_cprof" + if test x$enableval = xyes; + then + LIB_COMMON="${LIB_COMMON} -lcprof" + CPROF=1 fi - saved_CPPFLAGS=$CPPFLAGS - CPPFLAGS="$CPPFLAGS -I$x_includes" - for ac_hdr in X11/extensions/Xv.h -do -ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:5523: checking for $ac_hdr" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + +fi + + +# Check whether --enable-pth or --disable-pth was given. +if test "${enable_pth+set}" = set; then + enableval="$enable_pth" + if test x$enableval = xyes; then + echo $ac_n "checking for pth_init in -lpth""... $ac_c" 1>&6 +echo "configure:8440: checking for pth_init in -lpth" >&5 +ac_lib_var=`echo pth'_'pth_init | sed 'y%./+-%__p_%'` +if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < conftest.$ac_ext < +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char pth_init(); + +int main() { +pth_init() +; return 0; } EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5533: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then +if { (eval echo configure:8459: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" + eval "ac_cv_lib_$ac_lib_var=yes" else - echo "$ac_err" >&5 echo "configure: failed program was:" >&5 cat conftest.$ac_ext >&5 rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" + eval "ac_cv_lib_$ac_lib_var=no" fi rm -f conftest* +LIBS="$ac_save_LIBS" + fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then echo "$ac_t""yes" 1>&6 - ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + ac_tr_lib=HAVE_LIB`echo pth | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` cat >> confdefs.h <&6 fi -done - -fi -# Check whether --enable-alsa or --disable-alsa was given. -if test "${enable_alsa+set}" = set; then - enableval="$enable_alsa" - if test x$enable_alsa = xyes - then - ac_safe=`echo "sys/asoundlib.h" | sed 'y%./+-%__p_%'` -echo $ac_n "checking for sys/asoundlib.h""... $ac_c" 1>&6 -echo "configure:5573: checking for sys/asoundlib.h" >&5 -if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - cat > conftest.$ac_ext < conftest.$ac_ext < +#include EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5583: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then - rm -rf conftest* - eval "ac_cv_header_$ac_safe=yes" -else - echo "$ac_err" >&5 - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "pth_init" >/dev/null 2>&1; then rm -rf conftest* - eval "ac_cv_header_$ac_safe=no" + + cat >> confdefs.h <<\EOF +#define PTH_INIT_IN_PTH_H 1 +EOF + + THREAD_LIB="-lpth" + fi fi rm -f conftest* + + fi -if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then - echo "$ac_t""yes" 1>&6 - echo $ac_n "checking for main in -lasound""... $ac_c" 1>&6 -echo "configure:5600: checking for main in -lasound" >&5 -ac_lib_var=`echo asound'_'main | sed 'y%./+-%__p_%'` + + +# Check whether --enable-st or --disable-st was given. +if test "${enable_st+set}" = set; then + enableval="$enable_st" + if test x$enableval = xyes; then + echo $ac_n "checking for st_init in -lst""... $ac_c" 1>&6 +echo "configure:8513: checking for st_init in -lst" >&5 +ac_lib_var=`echo st'_'st_init | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else ac_save_LIBS="$LIBS" -LIBS="-lasound $LIBS" +LIBS="-lst $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8532: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5626,28 +8543,42 @@ LIBS="$ac_save_LIBS" fi if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then echo "$ac_t""yes" 1>&6 - have_alsa="true" -else - echo "$ac_t""no" 1>&6 -have_alsa="false" -fi + ac_tr_lib=HAVE_LIB`echo st | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + cat >> confdefs.h <&6 -have_alsa="false" fi - if test x$have_alsa = xtrue - then - PLUGINS="${PLUGINS} alsa" - LIB_ALSA="-lasound" - fi - fi + cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "st_init" >/dev/null 2>&1; then + rm -rf conftest* + + cat >> confdefs.h <<\EOF +#define ST_INIT_IN_ST_H 1 +EOF + + THREAD_LIB="-lst" + fi fi +rm -f conftest* fi + +LIB_COMMON="${LIB_COMMON} ${THREAD_LIB}" + # Check whether --enable-plugins or --disable-plugins was given. if test "${enable_plugins+set}" = set; then enableval="$enable_plugins" @@ -5659,6 +8590,76 @@ if test "${enable_plugins+set}" = set; then fi +if test x$ac_cv_header_dlfcn_h = xno -a x$ac_cv_header_image_h = xno -a x$SYS != xmingw32 +then + echo "*** Your system doesn't have plug-in support. All plug-ins will be compiled" + echo "as built-in" + BUILTINS="${BUILTINS} ${PLUGINS}" + PLUGINS= +fi + +cat >> confdefs.h <> confdefs.h <> confdefs.h <> confdefs.h <> $CONFIG_STATUS <> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then @@ -6148,8 +9210,38 @@ fi; done EOF cat >> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF +for ac_file in $CONFIG_FILES; do + # Support "outfile[:infile[:infile...]]" + case "$ac_file" in + *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; + esac + # PO directories have a Makefile.in generated from Makefile.in.in. + case "$ac_file" in */Makefile.in) + # Adjust a relative srcdir. + ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` + ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" + ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` + # In autoconf-2.13 it is called $ac_given_srcdir. + # In autoconf-2.50 it is called $srcdir. + test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" + case "$ac_given_srcdir" in + .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; + /*) top_srcdir="$ac_given_srcdir" ;; + *) top_srcdir="$ac_dots$ac_given_srcdir" ;; + esac + if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then + rm -f "$ac_dir/POTFILES" + test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" + sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," -e "\$s/\(.*\) \\\\/\1/" < "$ac_given_srcdir/$ac_dir/POTFILES.in" > "$ac_dir/POTFILES" + test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" + sed -e "/POTFILES =/r $ac_dir/POTFILES" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" + fi + ;; + esac + done exit 0 EOF @@ -6164,7 +9256,8 @@ global configuration system : ${SYS} architecture : ${ARCH} optimizations : ${OPTIMS} -tuning: : ${TUNING}" +tuning: : ${TUNING} +release: : ${RELEASE}" if test x${HAVE_VLC} = x1 then @@ -6173,7 +9266,6 @@ vlc configuration ----------------- vlc version : ${VLC_VERSION} debug mode : ${DEBUG} -trace mode : ${TRACE} cprof/gprof support : ${CPROF}/${GPROF} need builtin getopt : ${NEED_GETOPT} built-in modules :${BUILTINS} @@ -6200,11 +9292,11 @@ which modules get compiled as plugins. " if test x${HAVE_VLC} = x1 then - echo "To build vlc and its plugins, type \`make vlc'." + echo "To build vlc and its plugins, type \`$VLC_MAKE'." fi -if test x${HAVE_LIBDVDCSS} = x1 +if test x${NEED_LIBDVDCSS} = x1 then - echo "To build libdvdcss only, type \`make libdvdcss'." + echo "To build libdvdcss only, type \`$VLC_MAKE libdvdcss'." fi echo ""