summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Loeser <halcy0n@gentoo.org>2005-08-21 02:45:34 +0000
committerMark Loeser <halcy0n@gentoo.org>2005-08-21 02:45:34 +0000
commit3c91aef9ba6114be37d46e5673765d6bdbba38cd (patch)
tree61c1f37ff82d1f246518f7cc2f6d1059366671c8
parentUpdate to today's CVS. This adds a USE flag for xprint. Also, get rid of the ... (diff)
downloadgentoo-2-3c91aef9ba6114be37d46e5673765d6bdbba38cd.tar.gz
gentoo-2-3c91aef9ba6114be37d46e5673765d6bdbba38cd.tar.bz2
gentoo-2-3c91aef9ba6114be37d46e5673765d6bdbba38cd.zip
Fix bad variable handling in asm, fixes compilation on gcc4 and gcc-3.4 when
(Portage version: 2.0.51.22-r2)
-rw-r--r--media-libs/libmovtar/ChangeLog7
-rw-r--r--media-libs/libmovtar/Manifest3
-rw-r--r--media-libs/libmovtar/files/libmovtar-0.1.3-asm.patch121
-rw-r--r--media-libs/libmovtar/libmovtar-0.1.3-r1.ebuild4
4 files changed, 132 insertions, 3 deletions
diff --git a/media-libs/libmovtar/ChangeLog b/media-libs/libmovtar/ChangeLog
index 4acabe2b59a1..21cf8d5fa4ca 100644
--- a/media-libs/libmovtar/ChangeLog
+++ b/media-libs/libmovtar/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for media-libs/libmovtar
# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-libs/libmovtar/ChangeLog,v 1.10 2005/05/07 00:20:16 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/libmovtar/ChangeLog,v 1.11 2005/08/21 02:45:34 halcy0n Exp $
+
+ 21 Aug 2005; Mark Loeser <halcy0n@gentoo.org>
+ +files/libmovtar-0.1.3-asm.patch, libmovtar-0.1.3-r1.ebuild:
+ Fix bad variable handling in asm, fixes compilation on gcc4 and gcc-3.4 when
+ -funit-at-a-time is used; bug #101397
07 May 2005; Diego Pettenò <flameeyes@gentoo.org>
+files/libmovtar-0.1.3-m4.patch, +metadata.xml, libmovtar-0.1.3-r1.ebuild:
diff --git a/media-libs/libmovtar/Manifest b/media-libs/libmovtar/Manifest
index e4dde376ee6f..85553c75e30d 100644
--- a/media-libs/libmovtar/Manifest
+++ b/media-libs/libmovtar/Manifest
@@ -1,7 +1,8 @@
MD5 af29e6374e551f2e2c44e2a9b1dbe8eb ChangeLog 1689
-MD5 f8f068434bd92fc0e43da0f08bc4ba76 libmovtar-0.1.3-r1.ebuild 1025
+MD5 12d55815df6be9683bde78078a5de1b3 libmovtar-0.1.3-r1.ebuild 1060
MD5 25473b6655fde2985f9e373862873020 metadata.xml 159
MD5 2a61a0e27ed6619e4462dc607c4ce0ac files/digest-libmovtar-0.1.3-r1 67
MD5 cedf741244f17031bc40505160893af2 files/jpegint.h 15712
MD5 f1372fda16838484031b86fbed77a8f0 files/libmovtar-0.1.3-gcc4.patch 454
MD5 c933da042a042cbe35ac8ff95a773e4d files/libmovtar-0.1.3-m4.patch 787
+MD5 ea0706326665d31bbe239b762158b5aa files/libmovtar-0.1.3-asm.patch 5179
diff --git a/media-libs/libmovtar/files/libmovtar-0.1.3-asm.patch b/media-libs/libmovtar/files/libmovtar-0.1.3-asm.patch
new file mode 100644
index 000000000000..10ffc61bbd3d
--- /dev/null
+++ b/media-libs/libmovtar/files/libmovtar-0.1.3-asm.patch
@@ -0,0 +1,121 @@
+diff -ur libmovtar-0.1.3-orig/movtar_play.c libmovtar-0.1.3/movtar_play.c
+--- libmovtar-0.1.3-orig/movtar_play.c 2005-08-20 16:24:54.000000000 -0400
++++ libmovtar-0.1.3/movtar_play.c 2005-08-20 16:48:03.000000000 -0400
+@@ -173,8 +173,11 @@
+ "punpcklbw %%mm7,%%mm0\n"// mm0: y3 y2 y1 y0 - expand to 16 bit
+ "punpcklbw %%mm7,%%mm1\n"// mm1: cb3 cb2 cb1 cb0
+ "punpcklbw %%mm7,%%mm2\n"// mm2: cr3 cr2 cr1 cr0
+- "psubw te0,%%mm1\n" //minus 128 for cb and cr
+- "psubw te0,%%mm2\n"
++ //"psubw te0,%%mm1\n" //minus 128 for cb and cr
++ //"psubw te0,%%mm2\n"
++ "psubw %4,%%mm1\n" //minus 128 for cb and cr
++ "psubw %4,%%mm2\n"
++
+ "psllw $2,%%mm1\n" // shift left 2 bits for Cr and Cb to fit the mult constants
+ "psllw $2,%%mm2\n"
+
+@@ -190,8 +193,11 @@
+ //------------------
+ // R G B
+
+- "pmulhw te1,%%mm3\n"// multiplicate in the constants: mm3: cb1/green cb1/blue cb0/green cb0/blue
+- "pmulhw te2,%%mm4\n"// mm4: cr1/red cb1/green cr0/red cr0/green
++ //"pmulhw te1,%%mm3\n"// multiplicate in the constants: mm3: cb1/green cb1/blue cb0/green cb0/blue
++ //"pmulhw te2,%%mm4\n"// mm4: cr1/red cb1/green cr0/red cr0/green
++ "pmulhw %5,%%mm3\n"// multiplicate in the constants: mm3: cb1/green cb1/blue cb0/green cb0/blue
++ "pmulhw %6,%%mm4\n"// mm4: cr1/red cb1/green cr0/red cr0/green
++
+
+ "movq %%mm0,%%mm5\n" // mm5: y3 y2 y1 y0
+ "punpcklwd %%mm5,%%mm5\n" // expand to 32 bit: y1 y1 y0 y0
+@@ -223,8 +229,11 @@
+ "punpckhwd %%mm0,%%mm0\n" //mm0 = y3 y3 y2 y2
+ "punpckhwd %%mm1,%%mm1\n" //mm1 = cb3 cb3 cb2 cb2
+ "punpckhwd %%mm2,%%mm2\n" //mm2 = cr3 cr3 cr2 cr2
+- "pmulhw te1,%%mm1\n" //mm1 = cb * ?
+- "pmulhw te2,%%mm2\n" //mm2 = cr * ?
++ //"pmulhw te1,%%mm1\n" //mm1 = cb * ?
++ //"pmulhw te2,%%mm2\n" //mm2 = cr * ?
++ "pmulhw %5,%%mm1\n" //mm1 = cb * ?
++ "pmulhw %6,%%mm2\n" //mm2 = cr * ?
++
+ "movq %%mm0,%%mm3\n" //mm3 = y3 y3 y2 y2
+ "punpcklwd %%mm3,%%mm3\n" //mm3 = y2 y2 y2 y2
+ "punpckhwd %%mm0,%%mm0\n" //mm0 = y3 y3 y3 y3
+@@ -250,7 +259,8 @@
+ "movq %%mm3,8%0\n" // save two more RGB pixels
+
+ :"=m"(outptr[0])
+- :"m"(inptr0[0]),"m"(inptr1[0]),"m"(inptr2[0]) //y cb cr
++ :"m"(inptr0[0]),"m"(inptr1[0]),"m"(inptr2[0]),"m"(te0),"m"(te1),
++ "m"(te2) //y cb cr
+ : "st");
+ #endif
+ outptr+=16;
+@@ -318,8 +328,11 @@
+ "punpcklbw %%mm7,%%mm0\n"// mm0: y3 y2 y1 y0 - expand to 16 bit
+ "punpcklbw %%mm7,%%mm1\n"// mm1: cb3 cb2 cb1 cb0
+ "punpcklbw %%mm7,%%mm2\n"// mm2: cr3 cr2 cr1 cr0
+- "psubw te0,%%mm1\n" //minus 128 for cb and cr
+- "psubw te0,%%mm2\n"
++ //"psubw te0,%%mm1\n" //minus 128 for cb and cr
++// "psubw te0,%%mm2\n"
++ "psubw %5,%%mm1\n" //minus 128 for cb and cr
++ "psubw %5,%%mm2\n"
++
+ "psllw $2,%%mm1\n" // shift left 2 bits for Cr and Cb to fit the mult constants
+ "psllw $2,%%mm2\n"
+
+@@ -335,8 +348,11 @@
+ //------------------
+ // R G B
+
+- "pmulhw te1,%%mm3\n"// multiplicate in the constants: mm3: cb1/green cb1/blue cb0/green cb0/blue
+- "pmulhw te2,%%mm4\n"// mm4: cr1/red cb1/green cr0/red cr0/green
++ //"pmulhw te1,%%mm3\n"// multiplicate in the constants: mm3: cb1/green cb1/blue cb0/green cb0/blue
++ //"pmulhw te2,%%mm4\n"// mm4: cr1/red cb1/green cr0/red cr0/green
++ "pmulhw %6,%%mm3\n"// multiplicate in the constants: mm3: cb1/green cb1/blue cb0/green cb0/blue
++ "pmulhw %7,%%mm4\n"// mm4: cr1/red cb1/green cr0/red cr0/green
++
+
+ "movq %%mm0,%%mm5\n" // mm5: y3 y2 y1 y0
+ "punpcklwd %%mm5,%%mm5\n" // expand to 32 bit: y1 y1 y0 y0
+@@ -367,8 +383,11 @@
+ "punpckhwd %%mm0,%%mm0\n" //mm0 = y3 y3 y2 y2
+ "punpckhwd %%mm1,%%mm1\n" //mm1 = cb3 cb3 cb2 cb2
+ "punpckhwd %%mm2,%%mm2\n" //mm2 = cr3 cr3 cr2 cr2
+- "pmulhw te1,%%mm1\n" //mm1 = cb * ?
+- "pmulhw te2,%%mm2\n" //mm2 = cr * ?
++// "pmulhw te1,%%mm1\n" //mm1 = cb * ?
++// "pmulhw te2,%%mm2\n" //mm2 = cr * ?
++ "pmulhw %6,%%mm1\n" //mm1 = cb * ?
++ "pmulhw %7,%%mm2\n" //mm2 = cr * ?
++
+ "movq %%mm0,%%mm3\n" //mm3 = y3 y3 y2 y2
+ "punpcklwd %%mm3,%%mm3\n" //mm3 = y2 y2 y2 y2
+ "punpckhwd %%mm0,%%mm0\n" //mm0 = y3 y3 y3 y3
+@@ -439,18 +458,20 @@
+ // and would replace all the workaround code below !!!! Reason: There is no packusdw !!
+ "movq %%mm5, %%mm6\n" // copy mm5
+ "psrlq $16, %%mm6\n" // shift out pixel 1, keep pixel 0
+- "pand shiftmask, %%mm5\n" // and out pixel 0
++ //"pand shiftmask, %%mm5\n" // and out pixel 0
++ "pand %4, %%mm5\n" // and out pixel 0
+ "por %%mm6, %%mm5\n" // or pix 0 and pix 1 together
+ "movd %%mm5, %0\n" // write pix 0 and 1 out
+
+ "movq %%mm3, %%mm0\n" // copy mm3
+ "psrlq $16, %%mm0\n" // shift out pixel 3, keep pixel 2
+- "pand shiftmask, %%mm3\n" // and out pixel 2
++ "pand %4, %%mm3\n" // and out pixel 2
+ "por %%mm0, %%mm3\n" // or pix 3 and pix 2 together
+ "movd %%mm3, 4%0\n" // write pix 2 and 3
+
+ :"=m"(outptr[0])
+- :"m"(inptr0[0]),"m"(inptr1[0]),"m"(inptr2[0]) //y cb cr
++ :"m"(inptr0[0]),"m"(inptr1[0]),"m"(inptr2[0]),"m"(shiftmask),"m"(te0),
++ "m"(te1), "m"(te2)//y cb cr
+ : "st");
+ #endif
+ outptr+=8;
diff --git a/media-libs/libmovtar/libmovtar-0.1.3-r1.ebuild b/media-libs/libmovtar/libmovtar-0.1.3-r1.ebuild
index e91350d222d1..57481c6a9f1f 100644
--- a/media-libs/libmovtar/libmovtar-0.1.3-r1.ebuild
+++ b/media-libs/libmovtar/libmovtar-0.1.3-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-libs/libmovtar/libmovtar-0.1.3-r1.ebuild,v 1.14 2005/05/07 00:20:16 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/libmovtar/libmovtar-0.1.3-r1.ebuild,v 1.15 2005/08/21 02:45:34 halcy0n Exp $
IUSE="mmx"
@@ -29,6 +29,8 @@ src_unpack() {
# Fix building with gcc4
epatch ${FILESDIR}/${P}-gcc4.patch
epatch ${FILESDIR}/${P}-m4.patch
+ # bug #101397
+ epatch ${FILESDIR}/${P}-asm.patch
}
src_compile() {