[Speex-dev] vorbis-psy compilation fix
Tengo
akin at rbcmail.ru
Wed Apr 24 10:14:43 PDT 2013
This patch enables compilation with GCC 4.7.1 and
--enable-shared=yes --enable-static=no --enable-vorbis-psy
-------------- next part --------------
diff -r -u speex/configure.ac speex/configure.ac
--- speex/configure.ac 2013-04-24 19:08:00.710564608 +0400
+++ speex/configure.ac 2013-04-24 20:04:33.589310544 +0400
@@ -204,7 +204,7 @@
AC_DEFINE([TI_C55X], , [Enable support for TI C55X DSP])
fi])
-AC_ARG_ENABLE(vorbis-psy, [ --enable-psy Enable the Vorbis psy model],
+AC_ARG_ENABLE(vorbis-psy, [ --enable-vorbis-psy Enable the Vorbis psy model],
[if test "$enableval" = yes; then
vorbis_psy=yes;
AC_DEFINE([VORBIS_PSYCHO], , [Enable support for the Vorbis psy model])
diff -r -u speex/libspeex/Makefile.am speex/libspeex/Makefile.am
--- speex/libspeex/Makefile.am 2013-04-24 19:08:00.729566052 +0400
+++ speex/libspeex/Makefile.am 2013-04-24 20:05:18.870721435 +0400
@@ -55,8 +55,8 @@
testenc_uwb_SOURCES = testenc_uwb.c
testenc_uwb_LDADD = libspeex.la $(VPSY_LIB)
testdenoise_SOURCES = testdenoise.c
-testdenoise_LDADD = libspeexdsp.la @FFT_LIBS@
+testdenoise_LDADD = libspeexdsp.la libspeex.la @FFT_LIBS@
testecho_SOURCES = testecho.c
-testecho_LDADD = libspeexdsp.la @FFT_LIBS@
+testecho_LDADD = libspeexdsp.la libspeex.la @FFT_LIBS@
testjitter_SOURCES = testjitter.c
-testjitter_LDADD = libspeexdsp.la @FFT_LIBS@
+testjitter_LDADD = libspeexdsp.la libspeex.la @FFT_LIBS@
diff -r -u speex/libspeex/smallft.c speex/libspeex/smallft.c
--- speex/libspeex/smallft.c 2013-04-24 19:08:00.741566964 +0400
+++ speex/libspeex/smallft.c 2013-04-24 20:37:07.586436790 +0400
@@ -1231,17 +1231,17 @@
for(i=0;i<n;i++)c[i]=ch[i];
}
-void spx_drft_forward(struct drft_lookup *l,float *data){
+EXPORT void spx_drft_forward(struct drft_lookup *l,float *data){
if(l->n==1)return;
drftf1(l->n,data,l->trigcache,l->trigcache+l->n,l->splitcache);
}
-void spx_drft_backward(struct drft_lookup *l,float *data){
+EXPORT void spx_drft_backward(struct drft_lookup *l,float *data){
if (l->n==1)return;
drftb1(l->n,data,l->trigcache,l->trigcache+l->n,l->splitcache);
}
-void spx_drft_init(struct drft_lookup *l,int n)
+EXPORT void spx_drft_init(struct drft_lookup *l,int n)
{
l->n=n;
l->trigcache=(float*)speex_alloc(3*n*sizeof(*l->trigcache));
@@ -1249,7 +1249,7 @@
fdrffti(n, l->trigcache, l->splitcache);
}
-void spx_drft_clear(struct drft_lookup *l)
+EXPORT void spx_drft_clear(struct drft_lookup *l)
{
if(l)
{
diff -r -u speex/libspeex/vorbis_psy.c speex/libspeex/vorbis_psy.c
--- speex/libspeex/vorbis_psy.c 2013-04-24 19:08:00.742567040 +0400
+++ speex/libspeex/vorbis_psy.c 2013-04-24 20:06:45.318233696 +0400
@@ -294,7 +294,7 @@
}
-VorbisPsy *vorbis_psy_init(int rate, int n)
+EXPORT VorbisPsy *vorbis_psy_init(int rate, int n)
{
long i,j,lo=-99,hi=1;
VorbisPsy *p = speex_alloc(sizeof(VorbisPsy));
@@ -354,7 +354,7 @@
return p;
}
-void vorbis_psy_destroy(VorbisPsy *p)
+EXPORT void vorbis_psy_destroy(VorbisPsy *p)
{
if(p){
spx_drft_clear(&p->lookup);
@@ -369,7 +369,7 @@
}
}
-void compute_curve(VorbisPsy *psy, float *audio, float *curve)
+EXPORT void compute_curve(VorbisPsy *psy, float *audio, float *curve)
{
int i;
float work[psy->n];
More information about the Speex-dev
mailing list