Browse Source

fix musl compile issues

Waldemar Brodkorb 12 years ago
parent
commit
6ca379f06d

+ 4 - 4
package/MesaLib/patches/patch-bin_mklib

@@ -1,7 +1,7 @@
 diff -Nur Mesa-8.0.5.orig/bin/mklib Mesa-8.0.5/bin/mklib
 --- Mesa-8.0.5.orig/bin/mklib	2012-10-24 21:03:58.000000000 +0200
-+++ Mesa-8.0.5/bin/mklib	2013-04-30 13:06:28.000000000 +0200
-@@ -333,12 +333,6 @@
++++ Mesa-8.0.5/bin/mklib	2013-09-19 11:59:49.000000000 +0200
+@@ -333,12 +333,6 @@ case $ARCH in
  	    # Check if objects are 32-bit and we're running in 64-bit
  	    # environment.  If so, pass -m32 flag to linker.
  	    set ${OBJECTS}
@@ -14,7 +14,7 @@ diff -Nur Mesa-8.0.5.orig/bin/mklib Mesa-8.0.5/bin/mklib
  
              if [ "${ALTOPTS}" ] ; then
                  OPTS=${ALTOPTS}
-@@ -392,12 +386,6 @@
+@@ -392,12 +386,6 @@ case $ARCH in
  	    # Check if objects are 32-bit and we're running in 64-bit
  	    # environment.  If so, pass -m32 flag to linker.
  	    set ${OBJECTS}
@@ -27,7 +27,7 @@ diff -Nur Mesa-8.0.5.orig/bin/mklib Mesa-8.0.5/bin/mklib
              if [ "${ALTOPTS}" ] ; then
                  OPTS=${ALTOPTS}
              fi
-@@ -466,12 +454,6 @@
+@@ -466,12 +454,6 @@ case $ARCH in
  		# Check if objects are 32-bit and we're running in 64-bit
  		# environment.  If so, pass -m32 flag to linker.
  		set ${OBJECTS}

+ 45 - 0
package/MesaLib/patches/patch-src_gallium_include_pipe_p_config_h

@@ -0,0 +1,45 @@
+--- Mesa-8.0.5.orig/src/gallium/include/pipe/p_config.h	2012-10-24 21:03:59.000000000 +0200
++++ Mesa-8.0.5/src/gallium/include/pipe/p_config.h	2013-09-19 12:27:54.000000000 +0200
+@@ -111,7 +111,6 @@
+  * Endian detection.
+  */
+ 
+-#ifdef __GLIBC__
+ #include <endian.h>
+ 
+ #if __BYTE_ORDER == __LITTLE_ENDIAN
+@@ -120,34 +119,6 @@
+ # define PIPE_ARCH_BIG_ENDIAN
+ #endif
+ 
+-#elif defined(__APPLE__)
+-#include <machine/endian.h>
+-
+-#if __DARWIN_BYTE_ORDER == __DARWIN_LITTLE_ENDIAN
+-# define PIPE_ARCH_LITTLE_ENDIAN
+-#elif __DARWIN_BYTE_ORDER == __DARWIN_BIG_ENDIAN
+-# define PIPE_ARCH_BIG_ENDIAN
+-#endif
+-
+-#elif defined(__sun)
+-#include <sys/isa_defs.h>
+-
+-#if defined(_LITTLE_ENDIAN)
+-# define PIPE_ARCH_LITTLE_ENDIAN
+-#elif defined(_BIG_ENDIAN)
+-# define PIPE_ARCH_BIG_ENDIAN
+-#endif
+-
+-#else
+-
+-#if defined(PIPE_ARCH_X86) || defined(PIPE_ARCH_X86_64)
+-#define PIPE_ARCH_LITTLE_ENDIAN
+-#elif defined(PIPE_ARCH_PPC) || defined(PIPE_ARCH_PPC_64)
+-#define PIPE_ARCH_BIG_ENDIAN
+-#endif
+-
+-#endif
+-
+ #if !defined(PIPE_ARCH_LITTLE_ENDIAN) && !defined(PIPE_ARCH_BIG_ENDIAN)
+ #error Unknown Endianness
+ #endif

+ 13 - 0
package/MesaLib/patches/patch-src_mesa_main_imports_h

@@ -0,0 +1,13 @@
+--- Mesa-8.0.5.orig/src/mesa/main/imports.h	2012-10-24 21:03:59.000000000 +0200
++++ Mesa-8.0.5/src/mesa/main/imports.h	2013-09-19 12:39:53.000000000 +0200
+@@ -568,10 +568,8 @@ _mesa_init_sqrt_table(void);
+ 
+ #ifdef __GNUC__
+ 
+-#if defined(__MINGW32__) || defined(__CYGWIN__) || defined(ANDROID) || defined(__APPLE__)
+ #define ffs __builtin_ffs
+ #define ffsll __builtin_ffsll
+-#endif
+ 
+ #define _mesa_ffs(i)  ffs(i)
+ #define _mesa_ffsll(i)  ffsll(i)

+ 11 - 0
package/MesaLib/patches/patch-src_mesa_main_querymatrix_c

@@ -0,0 +1,11 @@
+--- Mesa-8.0.5.orig/src/mesa/main/querymatrix.c	2012-03-30 18:19:03.000000000 +0200
++++ Mesa-8.0.5/src/mesa/main/querymatrix.c	2013-09-19 12:19:01.000000000 +0200
+@@ -70,7 +70,7 @@ fpclassify(double x)
+     }
+ }
+ 
+-#elif defined(__APPLE__) || defined(__CYGWIN__) || defined(__FreeBSD__) || \
++#elif defined(fpclassify) || defined(__APPLE__) || defined(__CYGWIN__) || defined(__FreeBSD__) || \
+      defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__) || \
+      (defined(__sun) && defined(__C99FEATURES__)) || defined(__MINGW32__) || \
+      (defined(__sun) && defined(__GNUC__)) || defined(ANDROID) || defined(__HAIKU__)