summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorpontscho <pontscho@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-06-05 10:16:32 +0000
committerpontscho <pontscho@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-06-05 10:16:32 +0000
commit1eb94e0c23fe9b04e1fe14cdbb35e9f20f24ed6f (patch)
tree00f97ee12a2fd8ff93679da244ca9cc49be4b57c /configure
parent61948baa991599920c01001f84ceb01e07bb7a20 (diff)
downloadmpv-1eb94e0c23fe9b04e1fe14cdbb35e9f20f24ed6f.tar.bz2
mpv-1eb94e0c23fe9b04e1fe14cdbb35e9f20f24ed6f.tar.xz
add and disable esd detection support ;)
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@1030 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure67
1 files changed, 45 insertions, 22 deletions
diff --git a/configure b/configure
index b7fca809f1..e875f42e9e 100755
--- a/configure
+++ b/configure
@@ -6,6 +6,8 @@
#
# Changes in reversed order:
#
+# 2001/06/05 by Pontscho
+# - added alsa and esd detection
#
# 2001/06/05 by Nick Kurshev
# - added checking of kernel version
@@ -115,8 +117,9 @@ params:
--enable-xmmp use XMMP audio drivers
--enable-lirc enable LIRC (remote control) support
- --disable-alsa disable alsa support [autodetect]
-
+ --disable-alsa disable alsa support [autodetect]
+ --disable-esd disable esd sound support [autodetect]
+
--disable-gcc-checking disable gcc version checking
--disable-select disable audio select() support ( for example required this
@@ -292,6 +295,7 @@ _select='#define HAVE_AUDIO_SELECT'
_gui=no;
_alsa=yes
+_esd=yes
for i in `echo $pparam`; do
@@ -596,29 +600,37 @@ rm -f $TMPC $TMPO
cat > $TMPC << EOF
#include <sys/asoundlib.h>
-#include <soundcard.h>
-int main( void ) { if(SND_LIB_MAJOR==0&&SND_LIB_MINOR==5)return 1; return 0; }
+#include <sys/soundcard.h>
+int main( void ) { if(SND_LIB_MAJOR==0&&SND_LIB_MINOR==5)return 0; return 1; }
EOF
-_alsaver='notfound'
-$_cc -o $TMPO -lasound $TMPC &> /dev/null || _alsa=no
-
-[ $_alsa == "yes" ] && $TMPO && { _alsaver='0.5.x'; }
+_alsaver='not found'
+$_cc -o $TMPO -lasound $TMPC 2> /dev/null || _alsa=no
+[ $_alsa == 'yes' ] && $TMPO && { _alsaver='0.5.x'; }
-if [ $_alsaver = 'notfound' ]; then
+if [ $_alsaver == 'not found' ]; then
cat > $TMPC << EOF
#include <sys/asoundlib.h>
-#include <soundcard.h>
-int main( void ) { if(SND_LIB_MAJOR==0&&SND_LIB_MINOR==9)return 1; return 0; }
+#include <sys/soundcard.h>
+int main( void ) { if(SND_LIB_MAJOR==0&&SND_LIB_MINOR==9)return 0; return 1; }
EOF
-_alsaver='notfound'
-$_cc -o $TMPO -lasound $TMPC &> /dev/null || _alsa=no
-[ $_alsa == "yes" ] && $TMPO && { _alsaver='0.9.x'; }
+_alsaver='not found'
+$_cc -o $TMPO -lasound $TMPC 2> /dev/null || _alsa=no
+[ $_alsa == 'yes' ] && $TMPO && { _alsaver='0.9.x'; }
fi
# ---
+cat > $TMPC << EOF
+#include <esd.h>
+int main( void ){ return 0; }
+EOF
+
+$_cc -o $TMPO -lesd $TMPC 2> /dev/null || { _esd=no; }
+
+# ---
+
# check for the parameters.
_prefix="/usr/local"
@@ -792,6 +804,9 @@ do
_alsaver='notfound'
_alsa=no
;;
+ --disable-esd)
+ _esd=no
+ ;;
--with-win32libdir=*)
_win32libdir=`echo $ac_option | cut -d '=' -f 2`
_win32libdirnotify=no
@@ -936,6 +951,7 @@ echo "Checking for PNG support ... $_png"
echo "Checking for DirectShow ... $_dshow"
echo "Checking for fastmemcpy ... $_fastmemcpy"
echo "Checking for alsa ... $_alsaver"
+echo "Checking for esd ... $_esd"
# write conf files.
if [ $_gl = yes ]; then
@@ -1221,13 +1237,18 @@ else
_gui='#undef HAVE_GUI'
fi
-if [ "$_alsaver" != "notfound" ]; then
-[ $_alsaver == '0.5.x' ] && { _aosrc="$_aosrc ao_alsa5.c"; $_alsa='#define HAVE_ALSA5'; }
-# [ $_alsaver == '0.9.x' ] && { _aosrc="$_aosrc ao_alsa9.c"; }
-else
- _alsa=' '
+_alsa5='#undef HAVE_ALSA5'
+_alsa9='#undef HAVE_ALSA9'
+if [ $_alsa == 'yes' ]; then
+ [ $_alsaver == '0.5.x' ] && { _aosrc="$_aosrc ao_alsa5.c"; _alsa5='#define HAVE_ALSA5'; }
+ # [ $_alsaver == '0.9.x' ] && { _aosrc="$_aosrc ao_alsa9.c"; _alsa9='#define HAVE_ALSA9'; }
fi
-
+
+_esdd='#undef HAVE_ESD'
+if [ $_esd == 'yes' ]; then
+ _esdd='#undef HAVE_ESD'
+fi
+
cat > $CCONF << EOF
/* -------- Generated by ./configure ----------- */
@@ -1296,8 +1317,10 @@ $_fastmemcpy
$_gui
#define PREFIX "$_prefix"
-/* ALSA support */
-$_alsa
+/* Audio lib drivers */
+$_alsa5
+$_alsa9
+$_esdd
/* Enable fast OSD/SUB renderer (looks ugly, but uses less CPU power) */
#undef FAST_OSD