summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorarpi_esp <arpi_esp@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-04-15 20:31:58 +0000
committerarpi_esp <arpi_esp@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-04-15 20:31:58 +0000
commit21f9a7c8571420a820309d6e76bd78dafe652d97 (patch)
tree7b5ac72566b9d4b7bdef58090bb5b440d21089b8 /configure
parent448db7e50bab753155de986e1da55687df39016d (diff)
downloadmpv-21f9a7c8571420a820309d6e76bd78dafe652d97.tar.bz2
mpv-21f9a7c8571420a820309d6e76bd78dafe652d97.tar.xz
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@449 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure126
1 files changed, 58 insertions, 68 deletions
diff --git a/configure b/configure
index 90b1551a6d..d49fb504a9 100755
--- a/configure
+++ b/configure
@@ -6,10 +6,6 @@
#
# Changes in reversed order:
#
-# 2001/04/15 by Pontscho
-# - added --disable-select option
-# - added X11DIR variable in config.mak and fix syncfb Makefile -L/usr/X11/lib bug
-#
# 2001/03/24 by Mike Graffam:
# - added autodetect code for XF86VidMode, along with explicit --enable-vm
#
@@ -93,10 +89,7 @@ params:
--enable-termcap use termcap database for key codes
--enable-xmmp use XMMP audio drivers
- --enable-lirc enable LIRC ( remote control ) support
-
- --disable-select disable audio select() support ( for example required this
- option ALSA or Vortex2 driver )
+ --enable-lirc enable LIRC (remote control) support
--with-x11libdir=DIR X library files are in DIR
--with-win32libdir=DIR windows codec files
@@ -137,6 +130,16 @@ MCONF='config.mak'
# --- Check for C compiler:
_cc=gcc
+_x11=auto
+
+_x11libdir=
+if [ -e /usr/X11R6 ]; then
+ _x11libdir=-L/usr/X11R6/lib
+else
+ if [ -e /usr/X11 ]; then
+ _x11libdir=-L/usr/X11/lib
+ fi
+fi
for ac_option
do
@@ -144,6 +147,15 @@ do
--cc=*)
_cc=`echo $ac_option | cut -d '=' -f 2`
;;
+ --with-x11libdir=*)
+ _x11libdir=-L`echo $ac_option | cut -d '=' -f 2`
+ ;;
+ --enable-x11)
+ _x11=yes
+ ;;
+ --disable-x11)
+ _x11=no
+ ;;
esac
done
@@ -170,7 +182,6 @@ _gl=no
_sdl=no
_xv=no
_vm=no
-_x11=no
_3dfx=no
_syncfb=no
_mlib=no
@@ -179,7 +190,7 @@ _xmga=no
_dga=no
_dga2=no
_svga=no
-_fbdev=no
+_fbdev=yes
_lirc=no
_xdpms=no
@@ -188,11 +199,8 @@ _y=1
_gllib=
_sdllib=
-_x11lib=
_xvlib=
-_xlibdir=
-
-_select='#define HAVE_AUDIO_SELECT'
+_x11lib=
for i in `echo $pparam`; do
@@ -229,13 +237,6 @@ for i in `echo $pparam`; do
done
-if [ -e /usr/X11R6 ]; then
- _x11libdir=-L/usr/X11R6/lib
-else
- if [ -e /usr/X11 ]; then
- _x11libdir=-L/usr/X11/lib
- fi
-fi
_win32libdirnotify=no
if [ -e /usr/lib/win32 ]; then
@@ -375,21 +376,15 @@ fi
#echo "DONE (${proc})."
-# check GL & X11 & Xext & Xv & SDL & termcap libs
-
-$_cc $TMPC -o $TMPO $_x11libdir/ -lGL &> /dev/null && _gl=yes
-$_cc $TMPC -o $TMPO $_x11libdir/ -lXxf86vm &> /dev/null && _vm=yes
$_cc $TMPC -o $TMPO -lvgagl -lvga &> /dev/null && _svga=yes
-$_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext &> /dev/null && _x11=yes
-$_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXdpms &> /dev/null && _xdpms=yes
-$_cc $TMPC -o $TMPO $_x11libdir -lXv &> /dev/null && _xv=yes
-$_cc $TMPC -o $TMPO $_x11libdir -L/usr/local/lib/ -lpthread &> /dev/null || \
+
+$_cc $TMPC -o $TMPO -lpthread &> /dev/null || \
{ echo "Lib pthread not found."; rm -f $TMPC $TMPO ; exit 1; }
# SDL disabled by default (0.11pre22-) because of the compilation problems
# this is very buggy & experimental code, use it only if you really need it!!
_have_sdl=no
-$_cc $TMPC -o $TMPO $_x11libdir -L/usr/local/lib/ -lSDL -lpthread &> /dev/null && _have_sdl=yes
+$_cc $TMPC -o $TMPO -L/usr/local/lib/ -lSDL -lpthread &> /dev/null && _have_sdl=yes
_termcap=no
$_cc $TMPC -o $TMPO -ltermcap &> /dev/null && _termcap=yes
@@ -397,7 +392,28 @@ $_cc $TMPC -o $TMPO -ltermcap &> /dev/null && _termcap=yes
_binutils=no
as libac3/downmix/downmix_i386.S -o $TMPO &> /dev/null && _binutils=yes
-# LGB: Check DGA
+# ----------- Check X11 and related libs (GL, Xxf86vm, Xv, DGA) --------------
+
+if [ $_x11 = auto ]; then
+ _x11=no
+ $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext &> /dev/null && _x11=yes
+fi
+
+if [ $_x11 = yes ]; then
+
+$_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXdpms &> /dev/null && _xdpms=yes
+$_cc $TMPC -o $TMPO $_x11libdir -lXv &> /dev/null && _xv=yes
+
+$_cc $TMPC -o $TMPO $_x11libdir -lGL &> /dev/null && _gl=yes
+
+cat > $TMPC << EOF
+#include <GL/gl.h>
+int main( void ) { return 0; }
+EOF
+$_cc $TMPC -o $TMPO $_x11libdir -lGL &> /dev/null || \
+ { _gl=no; echo "GL includes not found!";}
+
+$_cc $TMPC -o $TMPO $_x11libdir -lXxf86vm &> /dev/null && _vm=yes
cat > $TMPC << EOF
#include <stdio.h>
@@ -406,7 +422,6 @@ cat > $TMPC << EOF
int main (void) { return 0;}
EOF
-_dga=no
$_cc $TMPC -o $TMPO -L/usr/X11R6/lib -L/usr/X11/lib -lX11 -lXext -lXxf86dga -lXxf86vm &> /dev/null && _dga=yes
# Note: the -lXxf86vm library is the VideoMode extension and though it's
# not needed for DGA, AFAIK every distribution packages together with DGA
@@ -414,8 +429,6 @@ $_cc $TMPC -o $TMPO -L/usr/X11R6/lib -L/usr/X11/lib -lX11 -lXext -lXxf86dga -lXx
# for further mplayer versions to set resolution by mplayer itself.
# If you run into problems, remove '-lXxf86vm'.
-# ---
-
# Check if DGA is 2.0 or greater
cat > $TMPC << EOF
#include <stdio.h>
@@ -427,24 +440,10 @@ EOF
_dga2=no
$_cc $TMPC -o $TMPO -L/usr/X11R6/lib -L/usr/X11/lib -lX11 -lXext -lXxf86dga -lXxf86vm &> /dev/null && _dga2=yes
-
-cat > $TMPC << EOF
-#include <GL/gl.h>
-int main( void ) { return 0; }
-EOF
-
-$_cc $TMPC -o $TMPO $_x11libdir/ -lGL &> /dev/null || \
- { _gl=no; echo "GL includes not found!";}
+fi
rm -f $TMPC $TMPO
-
-if [ $_x11 = 'yes' ]; then
- if [ $_mga = 'yes' ]; then
- _xmga=yes
- fi
-fi
-
# ---
# check for the parameters.
@@ -494,9 +493,6 @@ do
--enable-vm)
_vm=yes
;;
- --enable-x11)
- _x11=yes
- ;;
--enable-3dfx)
_3dfx=yes
;;
@@ -518,9 +514,6 @@ do
--enable-lirc)
_lirc=yes
;;
- --enable-select)
- _select='#define HAVE_AUDIO_SELECT'
- ;;
--disable-sse)
_sse=no
;;
@@ -552,9 +545,6 @@ do
--disable-vm)
_vm=no
;;
- --disable-x11)
- _x11=no
- ;;
--disable-mlib)
_mlib=no
;;
@@ -573,12 +563,6 @@ do
--disable-termcap)
_termcap=no
;;
- --disable-select)
- _select='#undef HAVE_AUDIO_SELECT'
- ;;
- --with-x11libdir=*)
- _x11libdir=-L`echo $ac_option | cut -d '=' -f 2`
- ;;
--with-win32libdir=*)
_win32libdir=`echo $ac_option | cut -d '=' -f 2`
_win32libdirnotify=no
@@ -589,11 +573,19 @@ do
--size-y=*)
_y=`echo $ac_option | cut -d '=' -f 2`
;;
+ --with-x11libdir=*)
+ ;;
--cc=*)
;;
esac
done
+if [ $_x11 = 'yes' ]; then
+ if [ $_mga = 'yes' ]; then
+ _xmga=yes
+ fi
+fi
+
# to screen.
echo "Using C compiler: $_cc"
echo "Checking for cpu vendor ... $pvendor ( $pfamily:$pmodel:$pstepping )"
@@ -683,12 +675,10 @@ cat > $MCONF << EOF
AR=ar
CC=$_cc
-X11DIR=$_x11libdir
# OPTFLAGS=-O4 -march=$proc -mcpu=$proc -pipe -fomit-frame-pointer -ffast-math
OPTFLAGS=-O4 -march=$proc -mcpu=$proc -pipe -ffast-math
# LIBS=-L/usr/lib -L/usr/local/lib $_x11libdir $_gllib $_sdllib $_dgalib $_x11lib $_xvlib
-# X_LIBS=$_x11libdir $_gllib $_sdllib $_dgalib $_x11lib $_xvlib $_vmlib $_svgalib
-X_LIBS=\$(X11DIR) $_gllib $_sdllib $_dgalib $_x11lib $_xvlib $_vmlib $_svgalib
+X_LIBS=$_x11libdir $_gllib $_sdllib $_dgalib $_x11lib $_xvlib $_vmlib $_svgalib
TERMCAP_LIB=$_libtermcap
XMM_LIBS = $_xmmplibs
LIRC_LIBS = $_lirclibs
@@ -847,7 +837,7 @@ cat > $CCONF << EOF
/* Undefine this if your soundcard driver has no working select().
If you have kernel Oops, player hangups, or just no audio, you should
try to recompile MPlayer with this option disabled! */
-$_select
+#define HAVE_AUDIO_SELECT
/* You have a choice for MP3 decoding: mp3lib(mpg123) or Win32(l3codeca.acm)
#define this if you prefer mpg123 (with 3Dnow! support) than l3codeca.acm