]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
gsmopen: compile with gsmlib by default, cosmetics on unicode console tests
authorGiovanni Maruzzelli <gmaruzz@gmail.com>
Fri, 20 Apr 2012 07:32:05 +0000 (09:32 +0200)
committerGiovanni Maruzzelli <gmaruzz@gmail.com>
Fri, 20 Apr 2012 07:32:05 +0000 (09:32 +0200)
src/mod/endpoints/mod_gsmopen/Makefile
src/mod/endpoints/mod_gsmopen/Makefile.am
src/mod/endpoints/mod_gsmopen/gsmopen_protocol.cpp
src/mod/endpoints/mod_gsmopen/mod_gsmopen.cpp

index e728199f1af5b9cf7918c457545059ff126fcfbc..bf1920aa6f5b607d12d58742c37242327c282082 100644 (file)
@@ -1,6 +1,6 @@
 MODNAME=mod_gsmopen
 SVNDEF := -D'GSMOPEN_SVN_VERSION="$(shell svnversion -n .)"'
 LOCAL_CFLAGS += $(SVNDEF) -I../../../../libs/spandsp/src -I../../../..//libs/tiff-3.8.2/libtiff
-LOCAL_LDFLAGS=-L../../../../libs/spandsp/src -lspandsp -lctb-0.16 #-lgsmme
+LOCAL_LDFLAGS=-L../../../../libs/spandsp/src -lspandsp -lctb-0.16 -lgsmme
 LOCAL_OBJS=gsmopen_protocol.o
 include ../../../../build/modmake.rules
index 491cf4ab422244cfa403e0492d96cca3b89f83dd..cef21e9871ca8c387f02fb99c65225597e9feb5d 100644 (file)
@@ -13,7 +13,7 @@ mod_LTLIBRARIES = mod_gsmopen.la
 mod_gsmopen_la_SOURCES  = mod_gsmopen.cpp gsmopen_protocol.cpp 
 mod_gsmopen_la_CFLAGS   = $(AM_CFLAGS) -I$(SPANDSP_DIR)/src -I$(TIFF_DIR)/libtiff -I$(SPANDSP_BUILDDIR)/src -I$(TIFF_BUILDDIR)/libtiff -I. -DGSMOPEN_SVN_VERSION=\"`cat $(switch_builddir)/.version`\"
 mod_gsmopen_la_LIBADD   = $(switch_builddir)/libfreeswitch.la $(SPANDSP_LA) $(TIFF_LA)
-mod_gsmopen_la_LDFLAGS  = -avoid-version -module -no-undefined -lctb-0.16 #-lgsmme
+mod_gsmopen_la_LDFLAGS  = -avoid-version -module -no-undefined -lctb-0.16 -lgsmme
 
 $(SPANDSP_LA): $(TIFF_LA) $(SPANDSP_DIR) $(SPANDSP_DIR)/.update
        cd $(SPANDSP_BUILDDIR) && $(MAKE) -j1
index 0bd4f78a552ea163e059f24182bf3b6ccd40ab2e..e422c9570b16b3e43de4f9ff534cccdc95e5fb62 100644 (file)
@@ -2297,7 +2297,7 @@ int ucs2_to_utf8(private_t *tech_pvt, char *ucs2_in, char *utf8_out, size_t outb
 
        memset(converted, '\0', sizeof(converted));
 
-       DEBUGA_GSMOPEN("ucs2_in=|%s|, utf8_out=|%s| èèè, %s\n", GSMOPEN_P_LOG, ucs2_in, utf8_out, "èèè");
+       DEBUGA_GSMOPEN("ucs2_in=|%s|, utf8_out=|%s|\n", GSMOPEN_P_LOG, ucs2_in, utf8_out);
        /* cicopet */
        for (c = 0; c < strlen(ucs2_in); c++) {
                sprintf(stringa, "0x%c%c", ucs2_in[c], ucs2_in[c + 1]);
@@ -2724,8 +2724,8 @@ int gsmopen_sendsms(private_t *tech_pvt, char *dest, char *text)
                        SMSMessageRef smsMessage;
 
                        memset(mesg_test, '\0', sizeof(mesg_test));
-                       //sprintf(mesg_test,":) ciao belè новости לק ראת ﺎﻠﺠﻤﻋﺓ 人大aèéàòçù"); //let's test the beauty of utf8
-                       sprintf(mesg_test,":) ciao belè èéàòìù"); 
+                       sprintf(mesg_test,":) ciao belè новости לק ראת ﺎﻠﺠﻤﻋﺓ 人大aèéàòçù"); //let's test the beauty of utf8
+                       //sprintf(mesg_test,":) ciao belè èéàòìù"); 
                        //text=mesg_test;
 
                        utf8_to_iso_8859_1(tech_pvt, text, strlen(text), smscommand, sizeof(smscommand));
index 24298d51f0695d3fa6a0c10c703c7728ac727657..77c0ef0d3710d561b2263397f426becf1b39346c 100644 (file)
@@ -1120,8 +1120,13 @@ static switch_status_t load_config(int reload_type)
        DEBUGA_GSMOPEN("Windows CODEPAGE Output =%d\n", GSMOPEN_P_LOG, GetConsoleOutputCP());
        //let's hope to have utf8 in console now, you need to use Lucida Console charset for the command prompt to show unicode
 #endif// WIN32
-       DEBUGA_GSMOPEN("Charset Output Test %s\n", GSMOPEN_P_LOG, "èéòàùç°§^£");
-       DEBUGA_GSMOPEN("Charset Output Test %s\n", GSMOPEN_P_LOG, "Согласие в различных регионах страны.");
+       NOTICA("GSMOPEN Charset Output Test 0 %s\n", GSMOPEN_P_LOG, "èéòàù");
+       NOTICA("GSMOPEN Charset Output Test 1 %s\n", GSMOPEN_P_LOG, "ç°§^£");
+       NOTICA("GSMOPEN Charset Output Test 2 %s\n", GSMOPEN_P_LOG, "новости");
+       NOTICA("GSMOPEN Charset Output Test 3 %s\n", GSMOPEN_P_LOG, "ﺎﻠﺠﻤﻋﺓ");
+       NOTICA("GSMOPEN Charset Output Test 4 %s\n", GSMOPEN_P_LOG, "ראת");
+       NOTICA("GSMOPEN Charset Output Test 5 %s\n", GSMOPEN_P_LOG, "לק");
+       NOTICA("GSMOPEN Charset Output Test 6 %s\n", GSMOPEN_P_LOG, "人大");
 
        switch_mutex_init(&globals.mutex, SWITCH_MUTEX_NESTED, gsmopen_module_pool);
        if (!(xml = switch_xml_open_cfg(cf, &cfg, NULL))) {