[MPlayer-dev-eng] [PATCH] name clash between mp3lib and libmp3lame
Gianluigi Tiesi
mplayer at netfarm.it
Sat May 21 10:36:57 CEST 2005
I've just hacked a bit lame to compile with asm optimization on mingw
(yes there is a ml for mingw but this is related to main devel)
I've noticed a name clash between dct64 in mp3lib and libmp3lame
(there is also a clash between twolame and libmp3lame but I've posted
on their ml).
I've made a small patch to rename it to mp_dct64, I've tested on win32
(with and without libmp3lame) and on linux (without libmp3lame),
before applying please check other platforms.
I dunno if there are some other name clashes using different platform
than i386.
Patch is attached.
Bye
--
Gianluigi Tiesi <sherpya at netfarm.it>
EDP Project Leader
Netfarm S.r.l. - http://www.netfarm.it/
Free Software: http://oss.netfarm.it/
-------------- next part --------------
diff -NubBr -xCVS -xhelp_mp.h -x'*.a' -x'*.exe' -x'*.o' -xconfigure.log -xconfig.mak -x.cvsignore -xconfig.h -xcodecs.conf.h -xversion.h -x.depend main/mp3lib/dct64.c sherpya/mp3lib/dct64.c
--- main/mp3lib/dct64.c 2005-04-17 12:35:26.058486400 +0200
+++ sherpya/mp3lib/dct64.c 2005-05-21 10:08:41.812492800 +0200
@@ -310,7 +310,7 @@
* the call via dct64 is a trick to force GCC to use
* (new) registers for the b1,b2 pointer to the bufs[xx] field
*/
-void dct64(real *a,real *b,real *c)
+void mp_dct64(real *a,real *b,real *c)
{
real bufs[0x40];
dct64_1(a,b,bufs,bufs+0x20,c);
diff -NubBr -xCVS -xhelp_mp.h -x'*.a' -x'*.exe' -x'*.o' -xconfigure.log -xconfig.mak -x.cvsignore -xconfig.h -xcodecs.conf.h -xversion.h -x.depend main/mp3lib/decod386.c sherpya/mp3lib/decod386.c
--- main/mp3lib/decod386.c 2005-04-17 12:35:26.148616000 +0200
+++ sherpya/mp3lib/decod386.c 2005-05-21 10:12:11.383841600 +0200
@@ -134,9 +134,9 @@
#endif
#ifdef HAVE_ALTIVEC
-#define dct64_base(a,b,c) if(gCpuCaps.hasAltiVec) dct64_altivec(a,b,c); else dct64(a,b,c)
+#define dct64_base(a,b,c) if(gCpuCaps.hasAltiVec) dct64_altivec(a,b,c); else mp_dct64(a,b,c)
#else /* HAVE_ALTIVEC */
-#define dct64_base(a,b,c) dct64(a,b,c)
+#define dct64_base(a,b,c) mp_dct64(a,b,c)
#endif /* HAVE_ALTIVEC */
static int synth_1to1(real *bandPtr,int channel,unsigned char *out,int *pnt)
diff -NubBr -xCVS -xhelp_mp.h -x'*.a' -x'*.exe' -x'*.o' -xconfigure.log -xconfig.mak -x.cvsignore -xconfig.h -xcodecs.conf.h -xversion.h -x.depend main/mp3lib/decode_i586.c sherpya/mp3lib/decode_i586.c
--- main/mp3lib/decode_i586.c 2005-04-17 12:35:26.188673600 +0200
+++ sherpya/mp3lib/decode_i586.c 2005-05-21 10:08:49.092961600 +0200
@@ -82,7 +82,7 @@
" leal (%%ecx,%%ebp,4),%%eax\n\t"
".L74:\n\t"
" pushl %%eax\n\t"
-" call "MANGLE(dct64)"\n\t"
+" call "MANGLE(mp_dct64)"\n\t"
" addl $12,%%esp\n\t"
" movl %4,%%edx\n\t"
" leal 0(,%%edx,4),%%edx\n\t"
diff -NubBr -xCVS -xhelp_mp.h -x'*.a' -x'*.exe' -x'*.o' -xconfigure.log -xconfig.mak -x.cvsignore -xconfig.h -xcodecs.conf.h -xversion.h -x.depend main/mp3lib/mpg123.h sherpya/mp3lib/mpg123.h
--- main/mp3lib/mpg123.h 2005-04-17 12:35:26.509134400 +0200
+++ sherpya/mp3lib/mpg123.h 2005-05-21 09:44:12.029048000 +0200
@@ -120,7 +120,7 @@
extern void make_decode_tables_MMX(long scaleval);
extern int synth_1to1_MMX( real *,int,short * );
extern int synth_1to1_MMX_s(real *, int, short *, short *, int *);
-extern void dct64(real *a,real *b,real *c);
+extern void mp_dct64(real *a,real *b,real *c);
extern void dct36_3dnow(real *,real *,real *,real *,real *);
extern void dct36_3dnowex(real *,real *,real *,real *,real *);
More information about the MPlayer-dev-eng
mailing list