changeset 32302:6d3212dd47b2

Drop two unnecessary Xlib.h #includes and use helper functions.
author diego
date Mon, 27 Sep 2010 17:18:39 +0000
parents a65635702512
children cad51466b42e
files configure mp3lib/dct64_sse.c
diffstat 2 files changed, 5 insertions(+), 14 deletions(-) [+]
line wrap: on
line diff
--- a/configure	Mon Sep 27 12:10:59 2010 +0000
+++ b/configure	Mon Sep 27 17:18:39 2010 +0000
@@ -4242,11 +4242,6 @@
 
 echocheck "X11"
 if test "$_x11" = auto && test "$_x11_headers" = yes ; then
-  cat > $TMPC <<EOF
-#include <X11/Xlib.h>
-#include <X11/Xutil.h>
-int main(void) { XCreateWindow(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); return 0; }
-EOF
   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 \
            -L/usr/lib ; do
@@ -4255,8 +4250,8 @@
     else
       _ld_tmp="$I -lXext -lX11 $_ld_pthread"
     fi
-    cc_check $_ld_tmp && libs_mplayer="$libs_mplayer $_ld_tmp" \
-                      && _x11=yes && break
+    statement_check X11/Xutil.h 'XCreateWindow(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0)' $_ld_tmp &&
+      libs_mplayer="$libs_mplayer $_ld_tmp" && _x11=yes && break
   done
 fi
 if test "$_x11" = yes ; then
@@ -4406,13 +4401,8 @@
 
 echocheck "Xinerama"
 if test "$_xinerama" = auto ; then
-  cat > $TMPC <<EOF
-#include <X11/Xlib.h>
-#include <X11/extensions/Xinerama.h>
-int main(void) { XineramaIsActive(0); return 0; }
-EOF
   _xinerama=no
-  cc_check -lXinerama && _xinerama=yes
+  statement_check X11/extensions/Xinerama.h 'XineramaIsActive(0)' -lXinerama && _xinerama=yes
 fi
 
 if test "$_xinerama" = yes ; then
--- a/mp3lib/dct64_sse.c	Mon Sep 27 12:10:59 2010 +0000
+++ b/mp3lib/dct64_sse.c	Mon Sep 27 17:18:39 2010 +0000
@@ -8,7 +8,8 @@
 #include "libavutil/mem.h"
 #include "mpg123.h"
 
-extern float __attribute__((aligned(16))) costab_mmx[];
+extern const unsigned int __attribute__((aligned(16))) costab_mmx[];
+//extern float __attribute__((aligned(16))) costab_mmx[];
 
 static const int ppnn[4] __attribute__((aligned(16))) =
 { 0, 0, 1 << 31, 1 << 31 };