patches/liboil-03-ss12u1.diff
author yippi
Thu, 08 Apr 2010 21:05:48 +0000
changeset 17810 336f5afbb6b3
parent 17795 patches/liboil-03-studio-workarounds.diff@c92618c168c1
permissions -rw-r--r--
2010-04-08 Brian Cameron <[email protected]> * base-specs/liboil.spec, patches/liboil-04-ss11.diff: Add patch so that liboil can compile with the SS11 compiler. * patches/liboil-05-sse.diff: Require SSE2 support to enable SSE. This is because liboil has SSE and SSE2 code combined in the same files, and Sun Studio requires that architecture specific code be in separate files. It would be better to reorganize the code when we have time. * patches/liboil-03-ss12u1.diff: Renamed from liboil-03-studio-workarounds.diff. Keeping this as a separate patch so that the SS11 and SS12 fixes can be backed out easily as we update the compiler.

--- liboil-0.3.16/liboil/Makefile.am-orig	2010-03-31 02:18:29.020416389 -0500
+++ liboil-0.3.16/liboil/Makefile.am	2010-03-31 02:18:45.577467717 -0500
@@ -28,12 +28,12 @@ if HAVE_3DNOW_INTRINSICS
 #libs_i386 += 3dnow/lib3dnow.la
 endif
 
-if HAVE_AMD64
-if HAVE_GCC_ASM
-SUBDIRS += amd64 i386_amd64
-libs += amd64/libamd64.la i386_amd64/libi386_amd64.la
-endif
-endif
+#if HAVE_AMD64
+#if HAVE_GCC_ASM
+#SUBDIRS += amd64 i386_amd64
+#libs += amd64/libamd64.la i386_amd64/libi386_amd64.la
+#endif
+#endif
 
 if HAVE_POWERPC
 if HAVE_GCC_ASM
--- liboil-0.3.16/liboil/i386/trans8x8_i386.c-orig	2010-04-05 18:56:25.689914551 -0500
+++ liboil-0.3.16/liboil/i386/trans8x8_i386.c	2010-04-05 18:58:26.305370945 -0500
@@ -136,6 +136,8 @@ trans8x8_u16_mmx (uint16_t *dest, int ds
 }
 OIL_DEFINE_IMPL_FULL (trans8x8_u16_mmx, trans8x8_u16, OIL_IMPL_FLAG_MMX);
 
+/* These two functions crash when used with Sun Studio compiler */
+#if !defined (__SUNPRO_C)
 static void
 trans8x8_u16_asm1 (uint16_t *dest, int dstr, uint16_t *src, int sstr)
 {
@@ -233,4 +235,5 @@ trans8x8_u16_asm2 (uint16_t *dest, int d
       : "eax", "ecx", "edx", "esi", "edi");
 }
 OIL_DEFINE_IMPL (trans8x8_u16_asm2, trans8x8_u16);
+#endif