Revision
16495
Author
gmaruzz
Date
2010-01-24 06:29:02 -0600 (Sun, 24 Jan 2010)

Log Message

gsmopen: let's use the spandsp library that comes with FreeSWITCH. Thx Steve

Modified Paths

Diff

Modified: freeswitch/branches/gmaruzz/mod_gsmopen/Makefile (16494 => 16495)


--- freeswitch/branches/gmaruzz/mod_gsmopen/Makefile	2010-01-24 11:04:07 UTC (rev 16494)
+++ freeswitch/branches/gmaruzz/mod_gsmopen/Makefile	2010-01-24 12:29:02 UTC (rev 16495)
@@ -1,9 +1,9 @@
 MODNAME=mod_gsmopen
 SVNDEF := -D'GSMOPEN_SVN_VERSION="$(shell svnversion -n .)"'
 #LOCAL_CFLAGS += $(SVNDEF) -I/usr/src/gsmlib-1.10
-LOCAL_CFLAGS += $(SVNDEF)
+LOCAL_CFLAGS += $(SVNDEF) -I../../../../libs/spandsp/src -I../../../..//libs/tiff-3.8.2/libtiff
 #LOCAL_LDFLAGS=-lasound -L/usr/src/gsmlib-1.10/gsmlib/.libs -lgsmme
-LOCAL_LDFLAGS=-lasound -lgsmme
-LOCAL_OBJS=gsmopen_protocol.o celliax_spandsp.o
+LOCAL_LDFLAGS=-L../../../../libs/spandsp/src -lasound -lgsmme -lspandsp
+LOCAL_OBJS=gsmopen_protocol.o 
 #OUR_OBJS += /usr/src/gsmlib-1.10/gsmlib/libgsmme.la
 include ../../../../build/modmake.rules

Modified: freeswitch/branches/gmaruzz/mod_gsmopen/Makefile.am (16494 => 16495)


--- freeswitch/branches/gmaruzz/mod_gsmopen/Makefile.am	2010-01-24 11:04:07 UTC (rev 16494)
+++ freeswitch/branches/gmaruzz/mod_gsmopen/Makefile.am	2010-01-24 12:29:02 UTC (rev 16495)
@@ -1,7 +1,7 @@
 include $(top_srcdir)/build/modmake.rulesam
 MODNAME=mod_gsmopen
 mod_LTLIBRARIES = mod_gsmopen.la
-mod_gsmopen_la_SOURCES  = mod_gsmopen.cpp gsmopen_protocol.cpp celliax_spandsp.c
+mod_gsmopen_la_SOURCES  = mod_gsmopen.cpp gsmopen_protocol.cpp 
 mod_gsmopen_la_CFLAGS   = $(AM_CFLAGS) -DGSMOPEN_SVN_VERSION=\"`cat $(switch_builddir)/.version`\"
 mod_gsmopen_la_LIBADD   = $(switch_builddir)/libfreeswitch.la
-mod_gsmopen_la_LDFLAGS  = -avoid-version -module -no-undefined -lasound -lgsmme
+mod_gsmopen_la_LDFLAGS  = -avoid-version -module -no-undefined -lasound -lgsmme -lspandsp

Modified: freeswitch/branches/gmaruzz/mod_gsmopen/gsmopen.h (16494 => 16495)


--- freeswitch/branches/gmaruzz/mod_gsmopen/gsmopen.h	2010-01-24 11:04:07 UTC (rev 16494)
+++ freeswitch/branches/gmaruzz/mod_gsmopen/gsmopen.h	2010-01-24 12:29:02 UTC (rev 16495)
@@ -34,6 +34,8 @@
  *
  */
 
+#define __STDC_LIMIT_MACROS
+
 #ifdef WIN32
 #define HAVE_VSNPRINTF
 #pragma warning(disable: 4290)
@@ -80,7 +82,7 @@
 #include <sys/ioctl.h>
 #include <iconv.h>
 #endif //WIN32
-#include <libteletone.h>
+//#include <libteletone.h>
 
 #ifdef GSMOPEN_ALSA
 #define ALSA_PCM_NEW_HW_PARAMS_API
@@ -97,7 +99,7 @@
 #endif                          /* WANT_SPEEX */
 #endif// GSMOPEN_PORTAUDIO
 
-#include "celliax_spandsp.h"
+//#include "celliax_spandsp.h"
 #ifndef WIN32
 #include <sys/time.h>
 //#include <X11/Xlib.h>
@@ -105,6 +107,10 @@
 //#include <X11/Xatom.h>
 #endif //WIN32
 
+#define SPANDSP_EXPOSE_INTERNAL_STRUCTURES
+#include <spandsp.h>
+#include <spandsp/version.h>
+
 #ifdef _MSC_VER
 //Windows macro  for FD_SET includes a warning C4127: conditional expression is constant
 #pragma warning(push)

Modified: freeswitch/branches/gmaruzz/mod_gsmopen/mod_gsmopen.cpp (16494 => 16495)


--- freeswitch/branches/gmaruzz/mod_gsmopen/mod_gsmopen.cpp	2010-01-24 11:04:07 UTC (rev 16494)
+++ freeswitch/branches/gmaruzz/mod_gsmopen/mod_gsmopen.cpp	2010-01-24 12:29:02 UTC (rev 16495)
@@ -276,7 +276,7 @@
 	//teletone_dtmf_detect_init(&tech_pvt->dtmf_detect, tech_pvt->read_codec.implementation->actual_samples_per_second);
 	//teletone_dtmf_detect_init(&tech_pvt->dtmf_detect, 8000);
     dtmf_rx_init(&tech_pvt->dtmf_state, NULL, NULL);
-    dtmf_rx_parms(&tech_pvt->dtmf_state, 0, 10, 10);
+    dtmf_rx_parms(&tech_pvt->dtmf_state, 0, 10, 10, -99);
 
 #ifdef GSMOPEN_ALSA
 	if(tech_pvt->no_sound==0){

Modified: freeswitch/branches/gmaruzz/mod_gsmopen/noalsa/mod_gsmopen/Makefile (16494 => 16495)


--- freeswitch/branches/gmaruzz/mod_gsmopen/noalsa/mod_gsmopen/Makefile	2010-01-24 11:04:07 UTC (rev 16494)
+++ freeswitch/branches/gmaruzz/mod_gsmopen/noalsa/mod_gsmopen/Makefile	2010-01-24 12:29:02 UTC (rev 16495)
@@ -1,6 +1,6 @@
 MODNAME=mod_gsmopen
 SVNDEF := -D'GSMOPEN_SVN_VERSION="$(shell svnversion -n .)"'
-LOCAL_CFLAGS += $(SVNDEF) -DNO_ALSA
+LOCAL_CFLAGS += $(SVNDEF) -DNO_ALSA  -I../../../../../../libs/spandsp/src -I../../../../../..//libs/tiff-3.8.2/libtiff
 LOCAL_LDFLAGS=-lgsmme
 LOCAL_OBJS=gsmopen_protocol.o 
 include ../../../../../../build/modmake.rules

Modified: freeswitch/branches/gmaruzz/mod_gsmopen/nogsmlib_noalsa_nocplusplus/mod_gsmopen/Makefile (16494 => 16495)


--- freeswitch/branches/gmaruzz/mod_gsmopen/nogsmlib_noalsa_nocplusplus/mod_gsmopen/Makefile	2010-01-24 11:04:07 UTC (rev 16494)
+++ freeswitch/branches/gmaruzz/mod_gsmopen/nogsmlib_noalsa_nocplusplus/mod_gsmopen/Makefile	2010-01-24 12:29:02 UTC (rev 16495)
@@ -1,6 +1,6 @@
 MODNAME=mod_gsmopen
 SVNDEF := -D'GSMOPEN_SVN_VERSION="$(shell svnversion -n .)"'
-LOCAL_CFLAGS += $(SVNDEF) -DNO_GSMLIB -DNO_ALSA
+LOCAL_CFLAGS += $(SVNDEF) -DNO_GSMLIB -DNO_ALSA -I../../../../../../libs/spandsp/src -I../../../../../..//libs/tiff-3.8.2/libtiff
 LOCAL_LDFLAGS=
 LOCAL_OBJS=gsmopen_protocol.o 
 include ../../../../../../build/modmake.rules

Modified: freeswitch/branches/gmaruzz/mod_gsmopen/nogsmlib_nocplusplus/mod_gsmopen/Makefile (16494 => 16495)


--- freeswitch/branches/gmaruzz/mod_gsmopen/nogsmlib_nocplusplus/mod_gsmopen/Makefile	2010-01-24 11:04:07 UTC (rev 16494)
+++ freeswitch/branches/gmaruzz/mod_gsmopen/nogsmlib_nocplusplus/mod_gsmopen/Makefile	2010-01-24 12:29:02 UTC (rev 16495)
@@ -1,6 +1,6 @@
 MODNAME=mod_gsmopen
 SVNDEF := -D'GSMOPEN_SVN_VERSION="$(shell svnversion -n .)"'
-LOCAL_CFLAGS += $(SVNDEF) -Wno-error=address -DNO_GSMLIB
-LOCAL_LDFLAGS=-lasound 
+LOCAL_CFLAGS += $(SVNDEF) -Wno-error=address -DNO_GSMLIB -I../../../../../../libs/spandsp/src -I../../../../../..//libs/tiff-3.8.2/libtiff
+LOCAL_LDFLAGS=-lasound  -L../../../../../../libs/spandsp/src -lspandsp
 LOCAL_OBJS=gsmopen_protocol.o 
 include ../../../../../../build/modmake.rules

Modified: freeswitch/branches/gmaruzz/mod_gsmopen/portaudio_gsmlib_cplusplus_noalsa/mod_gsmopen/Makefile (16494 => 16495)


--- freeswitch/branches/gmaruzz/mod_gsmopen/portaudio_gsmlib_cplusplus_noalsa/mod_gsmopen/Makefile	2010-01-24 11:04:07 UTC (rev 16494)
+++ freeswitch/branches/gmaruzz/mod_gsmopen/portaudio_gsmlib_cplusplus_noalsa/mod_gsmopen/Makefile	2010-01-24 12:29:02 UTC (rev 16495)
@@ -1,6 +1,6 @@
 MODNAME=mod_gsmopen
 SVNDEF := -D'GSMOPEN_SVN_VERSION="$(shell svnversion -n .)"'
-LOCAL_CFLAGS += $(SVNDEF) -DNO_ALSA -DGSMOPEN_PORTAUDIO
-LOCAL_LDFLAGS=-lportaudio -lspeex -lspeexdsp -lgsmme
-LOCAL_OBJS=gsmopen_protocol.o pablio.o pa_ringbuffer.o celliax_spandsp.o
+LOCAL_CFLAGS += $(SVNDEF) -DNO_ALSA -DGSMOPEN_PORTAUDIO -I../../../../../../libs/spandsp/src -I../../../../../..//libs/tiff-3.8.2/libtiff
+LOCAL_LDFLAGS=-lportaudio -lspeex -lspeexdsp -lgsmme -L../../../../../../libs/spandsp/src -lspandsp
+LOCAL_OBJS=gsmopen_protocol.o pablio.o pa_ringbuffer.o 
 include ../../../../../../build/modmake.rules

Modified: freeswitch/branches/gmaruzz/mod_gsmopen/portaudio_nogsmlib_noalsa_nocplusplus/mod_gsmopen/Makefile (16494 => 16495)


--- freeswitch/branches/gmaruzz/mod_gsmopen/portaudio_nogsmlib_noalsa_nocplusplus/mod_gsmopen/Makefile	2010-01-24 11:04:07 UTC (rev 16494)
+++ freeswitch/branches/gmaruzz/mod_gsmopen/portaudio_nogsmlib_noalsa_nocplusplus/mod_gsmopen/Makefile	2010-01-24 12:29:02 UTC (rev 16495)
@@ -1,6 +1,6 @@
 MODNAME=mod_gsmopen
 SVNDEF := -D'GSMOPEN_SVN_VERSION="$(shell svnversion -n .)"'
-LOCAL_CFLAGS += $(SVNDEF) -DNO_GSMLIB -DNO_ALSA -DGSMOPEN_PORTAUDIO
-LOCAL_LDFLAGS=-lportaudio -lspeex -lspeexdsp
-LOCAL_OBJS=gsmopen_protocol.o pablio.o pa_ringbuffer.o celliax_spandsp.o
+LOCAL_CFLAGS += $(SVNDEF) -DNO_GSMLIB -DNO_ALSA -DGSMOPEN_PORTAUDIO -I../../../../../../libs/spandsp/src -I../../../../../..//libs/tiff-3.8.2/libtiff
+LOCAL_LDFLAGS=-lportaudio -lspeex -lspeexdsp -L../../../../../../libs/spandsp/src -lspandsp
+LOCAL_OBJS=gsmopen_protocol.o pablio.o pa_ringbuffer.o 
 include ../../../../../../build/modmake.rules