diff options
author | Alexis Ballier <aballier@gentoo.org> | 2008-07-16 13:09:59 +0000 |
---|---|---|
committer | Alexis Ballier <aballier@gentoo.org> | 2008-07-16 13:09:59 +0000 |
commit | a9080b7eec8fa8422a73fb04a7f3721c31cf3772 (patch) | |
tree | 1894ed018efeb7216f2aa9fbeb34a61f7ee959ba /media-sound/lame | |
parent | Stable on ppc wrt bug 231954 (diff) | |
download | historical-a9080b7eec8fa8422a73fb04a7f3721c31cf3772.tar.gz historical-a9080b7eec8fa8422a73fb04a7f3721c31cf3772.tar.bz2 historical-a9080b7eec8fa8422a73fb04a7f3721c31cf3772.zip |
Add pic fix by the PaX Team. Bug #93279. The code is still not enabled, people can test it by using EXTRA_ECONF=--enable-nasm emerge lame.
Package-Manager: portage-2.2_rc1/cvs/Linux 2.6.25.7 x86_64
Diffstat (limited to 'media-sound/lame')
-rw-r--r-- | media-sound/lame/ChangeLog | 7 | ||||
-rw-r--r-- | media-sound/lame/Manifest | 11 | ||||
-rw-r--r-- | media-sound/lame/files/lame-3.98-pic-fix.patch | 583 | ||||
-rw-r--r-- | media-sound/lame/lame-3.98.ebuild | 5 |
4 files changed, 599 insertions, 7 deletions
diff --git a/media-sound/lame/ChangeLog b/media-sound/lame/ChangeLog index 8ea436aea6ad..d1853eaed6ba 100644 --- a/media-sound/lame/ChangeLog +++ b/media-sound/lame/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for media-sound/lame # Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-sound/lame/ChangeLog,v 1.95 2008/07/13 12:17:08 aballier Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-sound/lame/ChangeLog,v 1.96 2008/07/16 13:09:58 aballier Exp $ + + 16 Jul 2008; Alexis Ballier <aballier@gentoo.org> + +files/lame-3.98-pic-fix.patch, lame-3.98.ebuild: + Add pic fix by the PaX Team. Bug #93279. The code is still not enabled, + people can test it by using EXTRA_ECONF=--enable-nasm emerge lame. 13 Jul 2008; Alexis Ballier <aballier@gentoo.org> +files/lame-3.98-stdint.patch, lame-3.98.ebuild: diff --git a/media-sound/lame/Manifest b/media-sound/lame/Manifest index 5f6b8e736b55..9fa79c706b02 100644 --- a/media-sound/lame/Manifest +++ b/media-sound/lame/Manifest @@ -5,18 +5,19 @@ AUX lame-3.96-ccc.patch 658 RMD160 c598ad66543cc63897e0212e220a436da563ee71 SHA1 AUX lame-3.96.1-asneeded.patch 9027 RMD160 5456182576a331feb00d1d8931ba598e37f08804 SHA1 16ca5409f6710e3bf061f1fc3e339a0b265ac8a8 SHA256 6f9874c2f79c129a6d0d8d59d5887e8dbceff4a4bad2ad0b35987dc7d3f09809 AUX lame-3.96.1-shared-frontend.patch 945 RMD160 0a0d2cd6dfd35bb909ba238a27d8a5d370f61a8e SHA1 c7066e2e460001853a2468dd8dffd5d418182c5b SHA256 f6af4c844776f22f24e3957a2348c4c1faab8d487b85f2deca3ddd1aa151e195 AUX lame-3.98-gtk-path.patch 8606 RMD160 8bca3b986edf75853bfaee6837f9eb4832b664fa SHA1 dc77fbe83f167eeb3f77b6677a90765395b17de9 SHA256 0728822c0eb05b6dc70c0ae8e064c9be3b2a3448d10a53764397c70b7489a3b8 +AUX lame-3.98-pic-fix.patch 14748 RMD160 69146077e45ae6445459f9af356abaa585662a4e SHA1 2451a78d06f12e4d7dcf57b11cba5d0e7a38da7c SHA256 6cd158f71be645f8f62a1268f3e7d4dfe1b722360a7073970459f197cbcbd027 AUX lame-3.98-shared-frontend.patch 1008 RMD160 8e12e752a325926e1376e45ffd3b72cac61ebf4a SHA1 af371fe673e42c4ba2e6e07255d6196d76d8ef79 SHA256 fb40bfb00e47964acbe0de428cc7a3e4b3a0e0ade120bf547891bf78031f6916 AUX lame-3.98-stdint.patch 651 RMD160 84a732f356ac05941d90c2a261f9d624fc38bc5b SHA1 b4ebe2a3e8c343180b7d82e2bd2edb81a7c0d1bd SHA256 2fc25342cf5b5d5fd465c76f7899b0276e6e9f21b948f6005de0724a35dcc567 DIST lame-3.97.tar.gz 1328058 RMD160 5c4cf02c0f4e10c4cd2ab610d62478b554cd0873 SHA1 acf56065f4e31ce023b0f99002d537adb1ec09df SHA256 0a2334a6d11085298a9a3c46d5d310cca012f2e61d6efae90840a76a364dbe17 DIST lame-398.tar.gz 1415983 RMD160 754343791ac80d2403291c63f99eb409bca6b62f SHA1 287979d076834882c99d0cc01ddbd9b3697ceaae SHA256 8396bcb425ddcbfb8027d5712fa8878a2257006ccbe3ac7a772e1652e43d19b1 EBUILD lame-3.97-r1.ebuild 2344 RMD160 0a9a1f527ff190af4be8537e005f228c7bca6de2 SHA1 7b8e6829846de017788b86605bedcc46590261f5 SHA256 0562fbf1fe90d783f9f04eff7b5adfabd5b0bf1865f28826852b48086f114604 -EBUILD lame-3.98.ebuild 2407 RMD160 c7042853646008e04e7ffc448fdf00791ee0e4cd SHA1 b8a54d7197c17e6a72314d6002bd141f91ca1cc0 SHA256 e4a87439bc425ea7f53514bec125675acbf902b7494836143ff07861a7c7a6c8 -MISC ChangeLog 13154 RMD160 2f0f071db9ef17a23a8894e778dc28d9dd46d56d SHA1 9a08c29c05c10e93c919e7cfe8a501d93a09cf7b SHA256 275cb548021fa7011a99c06c14ab0f0f61601e54bec757ac3e04aa47079735a6 +EBUILD lame-3.98.ebuild 2494 RMD160 ec6b506b26dc1672be2f8792b9b0b69b4654d3a0 SHA1 3ed37b27fa133402e1f943bb9e267a325b7f9fdb SHA256 d9bc2c72704d061368ae58aef8134a18b072983ba8a6c561268370430121a89b +MISC ChangeLog 13402 RMD160 a82d581fa58872ef807095a73f64e1c027a5e450 SHA1 46ef4e586062615f2bc067067e3aa51c520ca27d SHA256 36122f3e7f94f1dffb7a2bf9b2464a934c8510c1927d377d16ae6e2c7e7d9b99 MISC metadata.xml 160 RMD160 10be84fed28405abd22adc6689e87e5bb77e3501 SHA1 0c1bb16a7cc376ef35b87d8699ec9504718d36b9 SHA256 6bafe4a5c7b42309f124ebc2a9d78ebe5379aec4dcdc88c0bda2ab79c9851a6b -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (GNU/Linux) -iEYEARECAAYFAkh58ksACgkQvFcC4BYPU0oDIQCgqTxL0btg67+HmjMA/j3mDcr9 -lVsAnjDtUXWnOdoe9elykxSNO3vx7y75 -=uK0H +iEYEARECAAYFAkh98y4ACgkQvFcC4BYPU0o8rACgsmx1dieGaCYmbU4rxsZZKZ03 +rcoAnjSKjWjCj6VZGWYTnTaI7y1SdaMa +=xFkc -----END PGP SIGNATURE----- diff --git a/media-sound/lame/files/lame-3.98-pic-fix.patch b/media-sound/lame/files/lame-3.98-pic-fix.patch new file mode 100644 index 000000000000..e4e1088f899e --- /dev/null +++ b/media-sound/lame/files/lame-3.98-pic-fix.patch @@ -0,0 +1,583 @@ +diff -urp lame-398-orig/libmp3lame/i386/choose_table.nas lame-398/libmp3lame/i386/choose_table.nas +--- lame-398-orig/libmp3lame/i386/choose_table.nas 2008-07-16 13:53:55.000000000 +0200 ++++ lame-398/libmp3lame/i386/choose_table.nas 2008-07-16 14:06:08.000000000 +0200 +@@ -111,33 +111,42 @@ choose_table_H + dw 0x1d16, 0x1e16, 0x1e17, 0x1f17, 0x1f17 + + choose_jump_table_L: +- dd table_MMX.L_case_0 +- dd table_MMX.L_case_1 +- dd table_MMX.L_case_2 +- dd table_MMX.L_case_3 +- dd table_MMX.L_case_45 +- dd table_MMX.L_case_45 +- dd table_MMX.L_case_67 +- dd table_MMX.L_case_67 +- dd table_MMX.L_case_8_15 +- dd table_MMX.L_case_8_15 +- dd table_MMX.L_case_8_15 +- dd table_MMX.L_case_8_15 +- dd table_MMX.L_case_8_15 +- dd table_MMX.L_case_8_15 +- dd table_MMX.L_case_8_15 +- dd table_MMX.L_case_8_15 ++ dd table_MMX.L_case_0 - choose_table_MMX ++ dd table_MMX.L_case_1 - choose_table_MMX ++ dd table_MMX.L_case_2 - choose_table_MMX ++ dd table_MMX.L_case_3 - choose_table_MMX ++ dd table_MMX.L_case_45 - choose_table_MMX ++ dd table_MMX.L_case_45 - choose_table_MMX ++ dd table_MMX.L_case_67 - choose_table_MMX ++ dd table_MMX.L_case_67 - choose_table_MMX ++ dd table_MMX.L_case_8_15 - choose_table_MMX ++ dd table_MMX.L_case_8_15 - choose_table_MMX ++ dd table_MMX.L_case_8_15 - choose_table_MMX ++ dd table_MMX.L_case_8_15 - choose_table_MMX ++ dd table_MMX.L_case_8_15 - choose_table_MMX ++ dd table_MMX.L_case_8_15 - choose_table_MMX ++ dd table_MMX.L_case_8_15 - choose_table_MMX ++ dd table_MMX.L_case_8_15 - choose_table_MMX + + segment_code + ; + ; use MMX + ; + ++extern _GLOBAL_OFFSET_TABLE_ ++get_pc.bp: ++ mov ebp, [esp] ++ retn ++ + align 16 + ; int choose_table(int *ix, int *end, int *s) + choose_table_MMX: +- mov ecx,[esp+4] ;ecx = begin +- mov edx,[esp+8] ;edx = end ++ push ebp ++ call get_pc.bp ++ add ebp, _GLOBAL_OFFSET_TABLE_ + $$ - $ wrt ..gotpc ++ ++ mov ecx,[esp+8] ;ecx = begin ++ mov edx,[esp+12] ;edx = end + sub ecx,edx ;ecx = begin-end(should be minus) + test ecx,8 + pxor mm0,mm0 ;mm0=[0:0] +@@ -169,13 +178,16 @@ choose_table_MMX: + + cmp eax,15 + ja .with_ESC +- jmp [choose_jump_table_L+eax*4] ++ lea ecx,[ebp + choose_table_MMX wrt ..gotoff] ++ add ecx,[ebp + choose_jump_table_L+eax*4 wrt ..gotoff] ++ jmp ecx + + .with_ESC1: + emms +- mov ecx, [esp+12] ; *s ++ mov ecx, [esp+16] ; *s + mov [ecx], eax + or eax,-1 ++ pop ebp + ret + + .with_ESC: +@@ -187,12 +199,12 @@ choose_table_MMX: + push esi + bsr eax, eax + %assign _P 4*2 +- movq mm5, [D15_15_15_15] +- movq mm6, [D14_14_14_14] +- movq mm3, [mul_add] ++ movq mm5, [ebp + D15_15_15_15 wrt ..gotoff] ++ movq mm6, [ebp + D14_14_14_14 wrt ..gotoff] ++ movq mm3, [ebp + mul_add wrt ..gotoff] + +- mov ecx, [esp+_P+4] ; = ix +-; mov edx, [esp+_P+8] ; = end ++ mov ecx, [esp+_P+8] ; = ix ++; mov edx, [esp+_P+12] ; = end + sub ecx, edx + + xor esi, esi ; sum = 0 +@@ -209,7 +221,7 @@ choose_table_MMX: + psubw mm7, mm2 ; 14$B$h$jBg$-$$$H$-(B linbits_sum++; + pmaddwd mm0, mm3 ; {0, 0, y, x}*{1, 16, 1, 16} + movd ebx, mm0 +- mov esi, [largetbl+ebx*4+(16*16+16)*4] ++ mov esi, [ebp + largetbl+ebx*4+(16*16+16)*4 wrt ..gotoff] + + jz .H_dual_exit + +@@ -224,9 +236,9 @@ choose_table_MMX: + pmaddwd mm0, mm3 ; {y, x, y, x}*{1, 16, 1, 16} + movd ebx, mm0 + punpckhdq mm0,mm0 +- add esi, [largetbl+ebx*4+(16*16+16)*4] ++ add esi, [ebp + largetbl+ebx*4+(16*16+16)*4 wrt ..gotoff] + movd ebx, mm0 +- add esi, [largetbl+ebx*4+(16*16+16)*4] ++ add esi, [ebp + largetbl+ebx*4+(16*16+16)*4 wrt ..gotoff] + add ecx, 16 + psubw mm7, mm2 ; 14$B$h$jBg$-$$$H$-(B linbits_sum++; + jnz .H_dual_lp1 +@@ -237,8 +249,8 @@ choose_table_MMX: + paddd mm7,mm1 + punpckldq mm7,mm7 + +- pmaddwd mm7, [linbits32+eax*8] ; linbits +- mov ax, [choose_table_H+eax*2] ++ pmaddwd mm7, [ebp + linbits32+eax*8 wrt ..gotoff] ; linbits ++ mov ax, [ebp + choose_table_H+eax*2 wrt ..gotoff] + + movd ecx, mm7 + punpckhdq mm7,mm7 +@@ -261,54 +273,57 @@ choose_table_MMX: + mov edx, ecx + shr eax, 8 + .chooseE_s1: +- mov ecx, [esp+12] ; *s ++ mov ecx, [esp+16] ; *s + and eax, 0xff + add [ecx], edx ++ pop ebp + ret + + table_MMX.L_case_0: + emms ++ pop ebp + ret + + table_MMX.L_case_1: + emms +- mov eax, [esp+12] ; *s +- mov ecx, [esp+4] ; *ix ++ mov eax, [esp+16] ; *s ++ mov ecx, [esp+8] ; *ix + sub ecx, edx + push ebx + .lp: + mov ebx, [edx+ecx] + add ebx, ebx + add ebx, [edx+ecx+4] +- movzx ebx, byte [ebx+t1l] ++ movzx ebx, byte [ebp + ebx+t1l wrt ..gotoff] + add [eax], ebx + add ecx, 8 + jnz .lp + pop ebx + mov eax, 1 ++ pop ebp + ret + + table_MMX.L_case_45: + push dword 7 +- mov ecx, tableABC+9*8 ++ lea ecx, [ebp + tableABC+9*8 wrt ..gotoff] + jmp from3 + + table_MMX.L_case_67: + push dword 10 +- mov ecx, tableABC ++ lea ecx, [ebp + tableABC wrt ..gotoff] + jmp from3 + + table_MMX.L_case_8_15: + push dword 13 +- mov ecx, tableDEF ++ lea ecx, [ebp + tableDEF wrt ..gotoff] + from3: +- mov eax,[esp+8] ;eax = *begin +-; mov edx,[esp+12] ;edx = *end ++ mov eax,[esp+12] ;eax = *begin ++; mov edx,[esp+16] ;edx = *end + + push ebx + sub eax, edx + +- movq mm5,[mul_add] ++ movq mm5,[ebp + mul_add wrt ..gotoff] + pxor mm2,mm2 ;mm2 = sum + + test eax, 8 +@@ -361,22 +376,23 @@ from3: + .choose3_s2: + pop ecx + add eax, ecx +- mov ecx, [esp+12] ; *s ++ mov ecx, [esp+16] ; *s + add [ecx], edx ++ pop ebp + ret + + table_MMX.L_case_2: + push dword 2 +- mov ecx,table23 +- pmov mm5,[mul_add23] ++ lea ecx,[ebp + table23 wrt ..gotoff] ++ pmov mm5,[ebp + mul_add23 wrt ..gotoff] + jmp from2 + table_MMX.L_case_3: + push dword 5 +- mov ecx,table56 +- pmov mm5,[mul_add56] ++ lea ecx,[ebp + table56 wrt ..gotoff] ++ pmov mm5,[ebp + mul_add56 wrt ..gotoff] + from2: +- mov eax,[esp+8] ;eax = *begin +-; mov edx,[esp+12] ;edx = *end ++ mov eax,[esp+12] ;eax = *begin ++; mov edx,[esp+16] ;edx = *end + push ebx + push edi + +@@ -426,8 +442,9 @@ from2: + mov edx, ecx + inc eax + .choose2_s1: +- mov ecx, [esp+12] ; *s ++ mov ecx, [esp+16] ; *s + add [ecx], edx ++ pop ebp + ret + + end +diff -urp lame-398-orig/libmp3lame/i386/fft3dn.nas lame-398/libmp3lame/i386/fft3dn.nas +--- lame-398-orig/libmp3lame/i386/fft3dn.nas 2008-07-16 13:53:55.000000000 +0200 ++++ lame-398/libmp3lame/i386/fft3dn.nas 2008-07-16 13:54:07.000000000 +0200 +@@ -24,26 +24,35 @@ D_1_0_0_0 dd 0.0 , 1.0 + + segment_code + ++extern _GLOBAL_OFFSET_TABLE_ ++get_pc.bp: ++ mov ebp, [esp] ++ retn ++ + ;void fht_3DN(float *fz, int nn); + + proc fht_3DN + + pushd ebp, ebx, esi, edi + +- mov r0, [esp+20] ;fi +- mov r1, [esp+24] ;r1 = nn +- sub esp, 16 ++ sub esp, 20 ++ ++ call get_pc.bp ++ add ebp, _GLOBAL_OFFSET_TABLE_ + $$ - $ wrt ..gotpc + ++ mov r0, [esp+40] ;fi ++ mov r1, [esp+44] ;r1 = nn ++ lea r3, [ebp + costab wrt ..gotoff] ;tri = costab ++ lea r4, [r0+r1*8] ;r4 = fn = &fz[n] ++ mov [esp+16], r4 + mov r4, 8 ;kx = k1/2 +- mov r3, costab ;tri = costab +- lea r6, [r0+r1*8] ;r6 = fn = &fz[n] + + pmov mm7, [r3] + + loopalign 16 + .do1 + lea r3, [r3+16] ;tri += 2; +- pmov mm6, [costab+8] ++ pmov mm6, [ebp + costab+8 wrt ..gotoff] + lea r2, [r4+r4*2] ;k3*fsize/2 + mov r5, 4 ;i = 1*fsize + +@@ -104,7 +113,7 @@ proc fht_3DN + pmovd [r1+r4*4], mm4 ;gi[k2] + puphdq mm4, mm4 + +- cmp r0, r6 ++ cmp r0, [esp + 16] + pmovd [r1+r4*2], mm0 ;gi[k1] + pmovd [r1+r2*2], mm4 ;gi[k3] + +@@ -119,12 +128,12 @@ proc fht_3DN + ; mm7 = 0x800000000 | 0 + ; + pmov mm1, mm6 +- mov r0, [esp+36] ; fz ++ mov r0, [esp+40] ; fz + puphdq mm1, mm1 ; c1 | c1 + lea r1, [r0+r4*2] + pfadd mm1, mm1 ; c1+c1 | c1+c1 + pfmul mm1, mm6 ; 2*c1*c1 | 2*c1*s1 +- pfsub mm1, [D_1_0_0_0] ; 2*c1*c1-1.0 | 2*c1*s1 = -c2 | s2 ++ pfsub mm1, [ebp + D_1_0_0_0 wrt ..gotoff] ; 2*c1*c1-1.0 | 2*c1*s1 = -c2 | s2 + + pmov mm0, mm1 + pxor mm7, mm6 ; c1 | -s1 +@@ -134,7 +143,7 @@ proc fht_3DN + puphdq mm0, mm2 ; s2 | c2 + puphdq mm6, mm3 ;-s1 | c1 + +- pxor mm0, [costab] ; c2 | -s2 ++ pxor mm0, [ebp + costab wrt ..gotoff] ; c2 | -s2 + + ; mm0 = s2| c2 + ; mm1 = -c2| s2 +@@ -233,7 +242,7 @@ proc fht_3DN + + lea r0, [r0+r4*8] + lea r1, [r1+r4*8] +- cmp r0, r6 ++ cmp r0, [esp + 16] + pmov mm0, [esp] + pmov mm1, [esp+8] + +@@ -249,17 +258,17 @@ proc fht_3DN + pfsub mm6, mm7 ; c1*a-s1*b | s1*a+c1*b + pupldq mm7,mm6 + puphdq mm6,mm7 +- pmov mm7, [costab] ++ pmov mm7, [ebp + costab wrt ..gotoff] + jb near .for + +- mov r0, [esp+36] ;fi +- cmp r4, [esp+36+4] ++ mov r0, [esp+40] ;fi ++ cmp r4, [esp+40+4] + lea r4, [r4*4] ;kx *= 4 + + jb near .do1 + .exitttt + femms +- add esp,16 ++ add esp,20 + popd ebp, ebx, esi, edi + endproc + +@@ -270,20 +279,24 @@ proc fht_E3DN + + pushd ebp, ebx, esi, edi + +- mov r0, [esp+20] ;fi +- mov r1, [esp+24] ;r1 = nn +- sub esp, 16 ++ sub esp, 20 ++ ++ call get_pc.bp ++ add ebp, _GLOBAL_OFFSET_TABLE_ + $$ - $ wrt ..gotpc + ++ mov r0, [esp+40] ;fi ++ mov r1, [esp+44] ;r1 = nn ++ lea r3, [ebp + costab wrt ..gotoff] ;tri = costab ++ lea r4, [r0+r1*8] ;r4 = fn = &fz[n] ++ mov [esp+16], r4 + mov r4, 8 ;kx = k1/2 +- mov r3, costab ;tri = costab +- lea r6, [r0+r1*8] ;r6 = fn = &fz[n] + + pmov mm7, [r3] + + loopalign 16 + .do1 + lea r3, [r3+16] ;tri += 2; +- pmov mm6, [costab+8] ++ pmov mm6, [ebp + costab+8 wrt ..gotoff] + lea r2, [r4+r4*2] ;k3*fsize/2 + mov r5, 4 ;i = 1*fsize + +@@ -324,7 +337,7 @@ proc fht_E3DN + pfadd mm3, mm4 ;f0+f2|f1+f3 + pfsub mm5, mm4 ;f0-f2|f1-f3 + +- cmp r0, r6 ++ cmp r0, [esp + 16] + pmovd [r1+r4*2], mm3 ;gi[k1] + pmovd [r1+r2*2], mm5 ;gi[k3] + puphdq mm3, mm3 +@@ -343,12 +356,12 @@ proc fht_E3DN + ; mm7 = 0x800000000 | 0 + ; + pmov mm5, mm6 +- mov r0, [esp+36] ; fz ++ mov r0, [esp+40] ; fz + puphdq mm5, mm5 ; c1 | c1 + lea r1, [r0+r4*2] + pfadd mm5, mm5 ; c1+c1 | c1+c1 + pfmul mm5, mm6 ; 2*c1*c1 | 2*c1*s1 +- pfsub mm5, [D_1_0_0_0] ; 2*c1*c1-1.0 | 2*c1*s1 = -c2 | s2 ++ pfsub mm5, [ebp + D_1_0_0_0 wrt ..gotoff] ; 2*c1*c1-1.0 | 2*c1*s1 = -c2 | s2 + + pswapd mm4, mm5 ; s2 |-c2 + pxor mm4, mm7 ; s2 | c2 +@@ -447,7 +460,7 @@ proc fht_E3DN + + lea r0, [r0+r4*8] + lea r1, [r1+r4*8] +- cmp r0, r6 ++ cmp r0, [esp + 16] + pmov mm4, [esp] + pmov mm5, [esp+8] + +@@ -462,16 +475,16 @@ proc fht_E3DN + + pfsub mm6, mm7 ; c1*a-s1*b | s1*a+c1*b + pswapd mm6, mm6 ; ??? ; s1*a+c1*b | c1*a-s1*b +- pmov mm7, [costab] ++ pmov mm7, [ebp + costab wrt ..gotoff] + jb near .for + +- mov r0, [esp+36] ;fi +- cmp r4, [esp+36+4] ++ mov r0, [esp+40] ;fi ++ cmp r4, [esp+40+4] + lea r4, [r4*4] ;kx *= 4 + + jb near .do1 + .exitttt + femms +- add esp,16 ++ add esp,20 + popd ebp, ebx, esi, edi + endproc +diff -urp lame-398-orig/libmp3lame/i386/fftsse.nas lame-398/libmp3lame/i386/fftsse.nas +--- lame-398-orig/libmp3lame/i386/fftsse.nas 2008-07-16 13:53:55.000000000 +0200 ++++ lame-398/libmp3lame/i386/fftsse.nas 2008-07-16 13:54:07.000000000 +0200 +@@ -25,6 +25,12 @@ costab_fft:
+ S_SQRT2 dd 1.414213562
+
+ segment_code
++
++extern _GLOBAL_OFFSET_TABLE_
++get_pc.bp:
++ mov ebp, [esp]
++ retn
++
+ ;------------------------------------------------------------------------
+ ; by K. SAKAI
+ ; 99/08/18 PIII 23k[clk]
+@@ -40,15 +46,20 @@ fht_SSE:
+ push esi
+ push edi
+ push ebp
+-%assign _P 4*4
++
++%assign _P 4*5
+
+ ;2つ目のループ
+ mov eax,[esp+_P+4] ;eax=fz
+ mov ebp,[esp+_P+8] ;=n
+ shl ebp,3
+ add ebp,eax ; fn = fz + n, この関数終了まで不変
++ push ebp
++
++ call get_pc.bp
++ add ebp, _GLOBAL_OFFSET_TABLE_ + $$ - $ wrt ..gotpc
+
+- lea ecx,[costab_fft]
++ lea ecx,[ebp + costab_fft wrt ..gotoff]
+ xor eax,eax
+ mov al,8 ; =k1=1*(sizeof float) // 4, 16, 64, 256,...
+ .lp2: ; do{
+@@ -101,12 +112,12 @@ fht_SSE:
+ ; gi[k3] = g1 - g3;
+ fld dword [edi]
+ fadd dword [edi+eax*2]
+- fld dword [S_SQRT2]
++ fld dword [ebp + S_SQRT2 wrt ..gotoff]
+ fmul dword [edi+eax*4]
+
+ fld dword [edi]
+ fsub dword [edi+eax*2]
+- fld dword [S_SQRT2]
++ fld dword [ebp + S_SQRT2 wrt ..gotoff]
+ fmul dword [edi+edx*2]
+
+ fld st1
+@@ -121,7 +132,7 @@ fht_SSE:
+ fsubp st1,st0
+ fstp dword [edi+eax*4]
+
+- cmp ebx,ebp
++ cmp ebx,[esp]
+ jl near .lp20 ; while (fi<fn);
+
+
+@@ -136,17 +147,17 @@ fht_SSE:
+ ; s2 = c1*s1 + s1*c1 = 2*s1*c1;
+ shufps xmm7,xmm7,R4(1,0,0,1)
+ movss xmm5,xmm7 ; = { --, --, --, s1}
+- xorps xmm7,[Q_MMPP] ; = {-s1, -c1, +c1, +s1} -> 必要
++ xorps xmm7,[ebp + Q_MMPP wrt ..gotoff] ; = {-s1, -c1, +c1, +s1} -> 必要
+
+ addss xmm5,xmm5 ; = (--, --, --, 2*s1)
+ add esi,4 ; esi = fi = fz + i
+ shufps xmm5,xmm5,R4(0,0,0,0) ; = (2*s1, 2*s1, 2*s1, 2*s1)
+ mulps xmm5,xmm6 ; = (2*s1*c1, 2*s1*s1, 2*s1*s1, 2*s1*c1)
+- subps xmm5,[D_1100] ; = (--, 2*s1*s1-1, --, 2*s1*c1) = {-- -c2 -- s2}
++ subps xmm5,[ebp + D_1100 wrt ..gotoff] ; = (--, 2*s1*s1-1, --, 2*s1*c1) = {-- -c2 -- s2}
+ movaps xmm4,xmm5
+ shufps xmm5,xmm5,R4(2,0,2,0) ; = {-c2, s2, -c2, s2} -> 必要
+
+- xorps xmm4,[Q_MMPP] ; = {--, c2, --, s2}
++ xorps xmm4,[ebp + Q_MMPP wrt ..gotoff] ; = {--, c2, --, s2}
+ shufps xmm4,xmm4,R4(0,2,0,2) ; = {s2, c2, s2, c2} -> 必要
+
+ loopalign 16
+@@ -222,7 +233,7 @@ fht_SSE:
+ movss [edi+eax*4],xmm2
+ movss [esi+edx*2],xmm0
+ lea esi,[esi + eax*8] ; fi += (k1 * 4);
+- cmp esi,ebp
++ cmp esi,[esp]
+ jl near .lp21 ; while (fi<fn);
+
+
+@@ -247,7 +258,7 @@ fht_SSE:
+ shufps xmm0,xmm0,R4(1,1,0,0) ; = {t_s, t_s, t_c, t_c}
+ mulps xmm6,xmm0 ; = {c3*ts, s3*ts, s3*tc, c3*tc}
+ movhlps xmm4,xmm6 ; = {--, --, c3*ts, s3*ts}
+- xorps xmm4,[Q_MPMP] ; = {--, --, -c3*ts, s3*ts}
++ xorps xmm4,[ebp + Q_MPMP wrt ..gotoff] ; = {--, --, -c3*ts, s3*ts}
+ subps xmm6,xmm4 ; = {-,-, c3*ts+s3*tc, c3*tc-s3*ts}={-,-,s1,c1}
+
+ ; c3 = c1*t_c - s1*t_s;
+@@ -255,7 +266,7 @@ fht_SSE:
+ shufps xmm6,xmm6,0x14 ; = {c1, s1, s1, c1}
+ mulps xmm0,xmm6 ; = {ts*c1 ts*s1 tc*s1 tc*c1}
+ movhlps xmm3,xmm0
+- xorps xmm3,[Q_MPMP]
++ xorps xmm3,[ebp + Q_MPMP wrt ..gotoff]
+ subps xmm0,xmm3 ; = {--, --, s3, c3}
+
+ ; {s2 s4 c4 c2} = {2*s1*c1 2*s3*c3 1-2*s3*s3 1-2*s1*s1}
+@@ -268,7 +279,7 @@ fht_SSE:
+ sub edi,ebx ; edi = fz - i/2
+ mulps xmm7, xmm6 ; {s1*s1*2, s3*s3*2, s3*c3*2, s1*c1*2}
+ lea esi,[edi + ebx*2] ; esi = fi = fz +i/2
+- subps xmm7, [D_1100] ; {-c2, -c4, s4, s2}
++ subps xmm7, [ebp + D_1100 wrt ..gotoff] ; {-c2, -c4, s4, s2}
+ lea edi,[edi + eax*2-4] ; edi = gi = fz +k1-i/2
+
+ ; fi = fz +i;
+@@ -286,7 +297,7 @@ fht_SSE:
+ ; d = s2*fi[k3 ] - c2*gi[k3 ];
+
+ movaps xmm4,xmm7 ; = {-c2 -c4 s4 s2}
+- xorps xmm4,[Q_MMPP] ; = { c2 c4 s4 s2}
++ xorps xmm4,[ebp + Q_MMPP wrt ..gotoff] ; = { c2 c4 s4 s2}
+ shufps xmm4,xmm4,0x1B ; = { s2 s4 c4 c2}
+ movlps xmm0,[esi+eax*2]
+ movlps xmm1,[edi+eax*2]
+@@ -390,7 +401,7 @@ fht_SSE:
+ ; fi += k4;
+ lea edi,[edi + eax*8] ; gi += (k1 * 4);
+ lea esi,[esi + eax*8] ; fi += (k1 * 4);
+- cmp esi,ebp
++ cmp esi,[esp]
+ jl near .lp220 ; while (fi<fn);
+ ; } while (fi<fn);
+
+@@ -405,6 +416,7 @@ fht_SSE:
+ cmp eax,[esp+_P+8] ; while ((k1 * 4)<n);
+ jle near .lp2
+ pop ebp
++ pop ebp
+ pop edi
+ pop esi
+ pop ebx
diff --git a/media-sound/lame/lame-3.98.ebuild b/media-sound/lame/lame-3.98.ebuild index 4e0b7cfc94aa..1c3669d7b96a 100644 --- a/media-sound/lame/lame-3.98.ebuild +++ b/media-sound/lame/lame-3.98.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2008 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-sound/lame/lame-3.98.ebuild,v 1.2 2008/07/13 12:17:08 aballier Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-sound/lame/lame-3.98.ebuild,v 1.3 2008/07/16 13:09:58 aballier Exp $ inherit flag-o-matic toolchain-funcs eutils autotools versionator @@ -41,6 +41,9 @@ src_unpack() { # Dont prevent stdint.h from being included when it's in fact needed epatch "${FILESDIR}"/${PN}-3.98-stdint.patch + # PIC Fix by the PaX Team, bug #93279 + epatch "${FILESDIR}"/${PN}-3.98-pic-fix.patch + AT_M4DIR="${S}" eautoreconf epunt_cxx # embedded bug #74498 } |