--- configure.orig	2011-06-23 11:42:26.000000000 -0700
+++ configure	2011-06-23 13:34:17.000000000 -0700
@@ -4297,6 +4297,9 @@ echores "$_x11_headers"
 
 
 echocheck "X11"
+if test "$_x11" = yes ; then
+  libs_mplayer="$libs_mplayer -lXext -lX11"
+fi
 if test "$_x11" = auto && test "$_x11_headers" = yes ; then
   for I in "" -L/usr/X11R7/lib -L/usr/local/lib -L/usr/X11R6/lib -L/usr/lib/X11R6 \
            -L/usr/X11/lib -L/usr/lib32 -L/usr/openwin/lib -L/usr/local/lib64 -L/usr/X11R6/lib64 \
@@ -6777,6 +6780,7 @@ fi
 if test "$_qtx" = yes ; then
     def_qtx='#define CONFIG_QTX_CODECS 1'
     win32 && _qtx_codecs_win32=yes && def_qtx_win32='#define CONFIG_QTX_CODECS_WIN32 1'
+    darwin && extra_ldflags="$extra_ldflags -framework Carbon -framework QuickTime" && def_quicktime='#define CONFIG_QUICKTIME 1'
     codecmodules="qtx $codecmodules"
     darwin || win32 || _qtx_emulation=yes
 else
