[MPlayer-dev-eng] check for XFree86-VidModeExtension broken for xfree 3.3.x
Trent Piepho
xyzzy at speakeasy.org
Tue Feb 1 09:28:26 CET 2005
On Tue, 1 Feb 2005, Diego Biurrun wrote:
> Trent Piepho writes:
> > The XFree86-VidModeExtension extension isn't detected, when it used to be
> > in older versions of mplayer. This is problematic, as xfree 3.3.x doesn't
> > have DGA2 to switch modes. This patch fixes it.
> >
> > + _xf86xk=no
>
> You add a check so you should also add --disable and --enable options
> to configure.
Ok, here is an updated patch. IMHO, the multi-media keyboard support is such
a minor thing it's not really worth the clutter of another configure option.
-------------- next part --------------
Index: configure
===================================================================
RCS file: /cvsroot/mplayer/main/configure,v
retrieving revision 1.957
diff -u -r1.957 configure
--- configure 22 Jan 2005 18:30:23 -0000 1.957
+++ configure 1 Feb 2005 08:26:52 -0000
@@ -161,6 +161,7 @@
--enable-lirc enable LIRC (remote control) support [autodetect]
--enable-lircc enable LIRCCD (LIRC client daemon) input [autodetect]
--enable-joystick enable joystick support [disable]
+ --disable-xk disable support for 'multimedia' keys [autodetect]
--disable-tv disable TV Interface (tv/dvb grabbers) [enable]
--disable-tv-v4l disable Video4Linux TV Interface support [autodetect]
--disable-tv-v4l2 disable Video4Linux2 TV Interface support [autodetect]
@@ -1341,6 +1342,7 @@
_mga=auto
_xmga=auto
_vm=auto
+_xk=auto
_mlib=auto
_sgiaudio=auto
_sunaudio=auto
@@ -1547,6 +1549,8 @@
--disable-xmga) _xmga=no ;;
--enable-vm) _vm=yes ;;
--disable-vm) _vm=no ;;
+ --enable-xk) _xk=yes ;;
+ --disable-xk) _xk=no ;;
--enable-mlib) _mlib=yes ;;
--disable-mlib) _mlib=no ;;
--enable-sunaudio) _sunaudio=yes ;;
@@ -3550,7 +3554,6 @@
cat > $TMPC <<EOF
#include <X11/Xlib.h>
#include <X11/extensions/xf86vmode.h>
-#include <X11/XF86keysym.h>
int main(void) { (void) XF86VidModeQueryExtension(0, 0, 0); return 0; }
EOF
_vm=no
@@ -3566,6 +3569,28 @@
fi
echores "$_vm"
+# Check for the presence of special keycodes, like audio control buttons
+# that XFree86 might have. Used to be bundled with the xf86vm check, but
+# has nothing to do with xf86vm and XFree 3.x has xf86vm but does NOT
+# have these new keycodes
+echocheck "XF86keysym"
+if test "$_x11" = yes && test "$_xk" != no ; then
+ cat > $TMPC <<EOF
+#include <X11/Xlib.h>
+#include <X11/XF86keysym.h>
+int main(void) { return XF86XK_AudioPause; }
+EOF
+ _xf86xk=no
+ cc_check $_inc_x11 $_ld_x11 && _xf86xk=yes
+else
+ _xf86xk=no
+fi
+if test "$_xf86xk" = yes ; then
+ _def_xk='#define HAVE_XF86XK 1'
+else
+ _def_xk='#undef HAVE_XF86XK'
+fi
+echores "$_xf86xk"
echocheck "DGA"
# Version 2 is preferred to version 1 if available
@@ -7391,6 +7416,7 @@
$_def_xv
$_def_xvmc
$_def_vm
+$_def_xk
$_def_xinerama
$_def_gl
$_def_gl_win32
Index: libvo/x11_common.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/x11_common.c,v
retrieving revision 1.186
diff -u -r1.186 x11_common.c
--- libvo/x11_common.c 27 Dec 2004 11:09:49 -0000 1.186
+++ libvo/x11_common.c 1 Feb 2005 08:26:52 -0000
@@ -37,6 +37,9 @@
#ifdef HAVE_XF86VM
#include <X11/extensions/xf86vmode.h>
+#endif
+
+#ifdef HAVE_XF86XK
#include <X11/XF86keysym.h>
#endif
More information about the MPlayer-dev-eng
mailing list