mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-04-17 17:22:21 +00:00
gsmopen: gsmlib compile on windows with gsmlib, new solution for gsmlib, mod_gsmopen compiles again on linux (with gsmlib)
This commit is contained in:
parent
1f9c34cce4
commit
38874956fa
@ -46,7 +46,7 @@
|
|||||||
AdditionalIncludeDirectories="../vcproject,..,."
|
AdditionalIncludeDirectories="../vcproject,..,."
|
||||||
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;HAVE_CONFIG_H"
|
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;HAVE_CONFIG_H"
|
||||||
StringPooling="true"
|
StringPooling="true"
|
||||||
RuntimeLibrary="0"
|
RuntimeLibrary="2"
|
||||||
EnableFunctionLevelLinking="true"
|
EnableFunctionLevelLinking="true"
|
||||||
RuntimeTypeInfo="true"
|
RuntimeTypeInfo="true"
|
||||||
PrecompiledHeaderFile=".\Release/gsmlib.pch"
|
PrecompiledHeaderFile=".\Release/gsmlib.pch"
|
||||||
@ -123,7 +123,7 @@
|
|||||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;HAVE_CONFIG_H"
|
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;HAVE_CONFIG_H"
|
||||||
MinimalRebuild="true"
|
MinimalRebuild="true"
|
||||||
BasicRuntimeChecks="3"
|
BasicRuntimeChecks="3"
|
||||||
RuntimeLibrary="1"
|
RuntimeLibrary="3"
|
||||||
RuntimeTypeInfo="true"
|
RuntimeTypeInfo="true"
|
||||||
PrecompiledHeaderFile=".\Debug/gsmlib.pch"
|
PrecompiledHeaderFile=".\Debug/gsmlib.pch"
|
||||||
AssemblerListingLocation=".\Debug/"
|
AssemblerListingLocation=".\Debug/"
|
||||||
@ -148,6 +148,8 @@
|
|||||||
Name="VCLibrarianTool"
|
Name="VCLibrarianTool"
|
||||||
OutputFile=".\Debug\gsmlib.lib"
|
OutputFile=".\Debug\gsmlib.lib"
|
||||||
SuppressStartupBanner="true"
|
SuppressStartupBanner="true"
|
||||||
|
IgnoreAllDefaultLibraries="false"
|
||||||
|
IgnoreDefaultLibraryNames=""
|
||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCALinkTool"
|
Name="VCALinkTool"
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
#ifdef WIN32
|
#ifdef WIN32
|
||||||
#include "win_iconv.c"
|
#include "win_iconv.c"
|
||||||
#endif// WIN32
|
#endif// WIN32
|
||||||
#undef WANT_GSMLIB
|
#define WANT_GSMLIB
|
||||||
|
|
||||||
#ifdef WANT_GSMLIB
|
#ifdef WANT_GSMLIB
|
||||||
#include <gsmlib/gsm_sms.h>
|
#include <gsmlib/gsm_sms.h>
|
||||||
@ -2321,7 +2321,11 @@ int ucs2_to_utf8(private_t *tech_pvt, char *ucs2_in, char *utf8_out, size_t outb
|
|||||||
DEBUGA_GSMOPEN("1 ciao in=%s, inleft=%d, out=%s, outleft=%d, converted=%s, utf8_out=%s\n",
|
DEBUGA_GSMOPEN("1 ciao in=%s, inleft=%d, out=%s, outleft=%d, converted=%s, utf8_out=%s\n",
|
||||||
GSMOPEN_P_LOG, inbuf, (int) inbytesleft, outbuf, (int) outbytesleft, converted, utf8_out);
|
GSMOPEN_P_LOG, inbuf, (int) inbytesleft, outbuf, (int) outbytesleft, converted, utf8_out);
|
||||||
|
|
||||||
|
#ifdef WIN32
|
||||||
iconv_res = iconv(iconv_format, (const char **)&inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
iconv_res = iconv(iconv_format, (const char **)&inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
||||||
|
#else// WIN32
|
||||||
|
iconv_res = iconv(iconv_format, &inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
||||||
|
#endif// WIN32
|
||||||
if (iconv_res == (size_t) -1) {
|
if (iconv_res == (size_t) -1) {
|
||||||
DEBUGA_GSMOPEN("2 ciao in=%s, inleft=%d, out=%s, outleft=%d, converted=%s, utf8_out=%s\n",
|
DEBUGA_GSMOPEN("2 ciao in=%s, inleft=%d, out=%s, outleft=%d, converted=%s, utf8_out=%s\n",
|
||||||
GSMOPEN_P_LOG, inbuf, (int) inbytesleft, outbuf, (int) outbytesleft, converted, utf8_out);
|
GSMOPEN_P_LOG, inbuf, (int) inbytesleft, outbuf, (int) outbytesleft, converted, utf8_out);
|
||||||
@ -2358,7 +2362,11 @@ int utf8_to_iso_8859_1(private_t *tech_pvt, char *utf8_in, size_t inbytesleft, c
|
|||||||
|
|
||||||
DEBUGA_GSMOPEN("in=%s, inleft=%d, out=%s, outleft=%d, utf8_in=%s, iso_8859_1_out=%s\n",
|
DEBUGA_GSMOPEN("in=%s, inleft=%d, out=%s, outleft=%d, utf8_in=%s, iso_8859_1_out=%s\n",
|
||||||
GSMOPEN_P_LOG, inbuf, (int) inbytesleft, outbuf, (int) outbytesleft, utf8_in, iso_8859_1_out);
|
GSMOPEN_P_LOG, inbuf, (int) inbytesleft, outbuf, (int) outbytesleft, utf8_in, iso_8859_1_out);
|
||||||
|
#ifdef WIN32
|
||||||
iconv_res = iconv(iconv_format, (const char **)&inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
iconv_res = iconv(iconv_format, (const char **)&inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
||||||
|
#else// WIN32
|
||||||
|
iconv_res = iconv(iconv_format, &inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
||||||
|
#endif// WIN32
|
||||||
if (iconv_res == (size_t) -1) {
|
if (iconv_res == (size_t) -1) {
|
||||||
ERRORA("error: %s %d\n", GSMOPEN_P_LOG, strerror(errno), errno);
|
ERRORA("error: %s %d\n", GSMOPEN_P_LOG, strerror(errno), errno);
|
||||||
return -1;
|
return -1;
|
||||||
@ -2409,7 +2417,11 @@ int iso_8859_1_to_utf8(private_t *tech_pvt, char *iso_8859_1_in, char *utf8_out,
|
|||||||
}
|
}
|
||||||
|
|
||||||
inbytesleft = strlen(iso_8859_1_in) * 2;
|
inbytesleft = strlen(iso_8859_1_in) * 2;
|
||||||
|
#ifdef WIN32
|
||||||
iconv_res = iconv(iconv_format, (const char **)&inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
iconv_res = iconv(iconv_format, (const char **)&inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
||||||
|
#else// WIN32
|
||||||
|
iconv_res = iconv(iconv_format, &inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
||||||
|
#endif// WIN32
|
||||||
if (iconv_res == (size_t) -1) {
|
if (iconv_res == (size_t) -1) {
|
||||||
DEBUGA_GSMOPEN("ciao in=%s, inleft=%d, out=%s, outleft=%d, utf8_out=%s\n",
|
DEBUGA_GSMOPEN("ciao in=%s, inleft=%d, out=%s, outleft=%d, utf8_out=%s\n",
|
||||||
GSMOPEN_P_LOG, inbuf, (int) inbytesleft, outbuf, (int) outbytesleft, utf8_out);
|
GSMOPEN_P_LOG, inbuf, (int) inbytesleft, outbuf, (int) outbytesleft, utf8_out);
|
||||||
@ -2453,7 +2465,11 @@ int utf8_to_ucs2(private_t *tech_pvt, char *utf8_in, size_t inbytesleft, char *u
|
|||||||
|
|
||||||
DEBUGA_GSMOPEN("in=%s, inleft=%d, out=%s, outleft=%d, utf8_in=%s, converted=%s\n",
|
DEBUGA_GSMOPEN("in=%s, inleft=%d, out=%s, outleft=%d, utf8_in=%s, converted=%s\n",
|
||||||
GSMOPEN_P_LOG, inbuf, (int) inbytesleft, outbuf, (int) outbytesleft, utf8_in, converted);
|
GSMOPEN_P_LOG, inbuf, (int) inbytesleft, outbuf, (int) outbytesleft, utf8_in, converted);
|
||||||
|
#ifdef WIN32
|
||||||
iconv_res = iconv(iconv_format, (const char **)&inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
iconv_res = iconv(iconv_format, (const char **)&inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
||||||
|
#else// WIN32
|
||||||
|
iconv_res = iconv(iconv_format, &inbuf, &inbytesleft, &outbuf, &outbytesleft);
|
||||||
|
#endif// WIN32
|
||||||
if (iconv_res == (size_t) -1) {
|
if (iconv_res == (size_t) -1) {
|
||||||
ERRORA("error: %s %d\n", GSMOPEN_P_LOG, strerror(errno), errno);
|
ERRORA("error: %s %d\n", GSMOPEN_P_LOG, strerror(errno), errno);
|
||||||
return -1;
|
return -1;
|
||||||
|
@ -39,7 +39,7 @@
|
|||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCCLCompilerTool"
|
Name="VCCLCompilerTool"
|
||||||
AdditionalIncludeDirectories=""libctb-0.16\include";"$(InputDir)..\..\..\..\libs\spandsp\src\msvc";"$(InputDir)..\..\..\..\libs\spandsp\src";"$(InputDir)..\..\..\..\libs\tiff-3.8.2\libtiff""
|
AdditionalIncludeDirectories=""gsmlib\gsmlib-1.10-patched-13ubuntu";"libctb-0.16\include";"$(InputDir)..\..\..\..\libs\spandsp\src\msvc";"$(InputDir)..\..\..\..\libs\spandsp\src";"$(InputDir)..\..\..\..\libs\tiff-3.8.2\libtiff""
|
||||||
PreprocessorDefinitions="NO_ALSA"
|
PreprocessorDefinitions="NO_ALSA"
|
||||||
UsePrecompiledHeader="0"
|
UsePrecompiledHeader="0"
|
||||||
WarningLevel="4"
|
WarningLevel="4"
|
||||||
@ -56,9 +56,9 @@
|
|||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalOptions=" ctbd-0.16.lib "..\..\..\..\w32\library\debug\freeswitchcore.lib" "..\..\..\..\libs\libteletone\Debug\libteletone.lib" ksuser.lib "..\..\..\..\libs\win32\apr\debug\libapr-1.lib"
rpcrt4.lib "..\..\..\..\debug\libtiff.lib" "..\..\..\..\libs\spandsp\src\debug\spandsp.lib""
|
AdditionalOptions="gsmlib.lib ctbd-0.16.lib "..\..\..\..\w32\library\debug\freeswitchcore.lib" "..\..\..\..\libs\libteletone\Debug\libteletone.lib" ksuser.lib "..\..\..\..\libs\win32\apr\debug\libapr-1.lib"
rpcrt4.lib "..\..\..\..\debug\libtiff.lib" "..\..\..\..\libs\spandsp\src\debug\spandsp.lib""
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
AdditionalLibraryDirectories=""libctb-0.16\lib""
|
AdditionalLibraryDirectories=""gsmlib\gsmlib-1.10-patched-13ubuntu\win32\Debug";"libctb-0.16\lib""
|
||||||
RandomizedBaseAddress="1"
|
RandomizedBaseAddress="1"
|
||||||
DataExecutionPrevention="0"
|
DataExecutionPrevention="0"
|
||||||
/>
|
/>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user