Renamed module zlib to zlibcompress to avoid library name clashes.

Moved zlib API define to the VC++ project file.
Added zlib compression to the Windows installer.

git-svn-id: http://voip.null.ro/svn/yate@3441 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
paulc 2010-07-16 14:08:01 +00:00
parent 4c339d0254
commit ad8556f230
6 changed files with 29 additions and 27 deletions

View File

@ -133,7 +133,7 @@ PROGS := $(PROGS) openssl.yate
endif endif
ifneq (@HAVE_ZLIB@,no) ifneq (@HAVE_ZLIB@,no)
PROGS := $(PROGS) zlib.yate PROGS := $(PROGS) zlibcompress.yate
endif endif
ifeq (@HAVE_COREDUMPER@,yes) ifeq (@HAVE_COREDUMPER@,yes)
@ -325,8 +325,8 @@ server/sipfeatures.yate: ../libs/yxml/libyatexml.a
server/sipfeatures.yate: LOCALFLAGS = -I@top_srcdir@/libs/yxml server/sipfeatures.yate: LOCALFLAGS = -I@top_srcdir@/libs/yxml
server/sipfeatures.yate: LOCALLIBS = -L../libs/yxml -lyatexml server/sipfeatures.yate: LOCALLIBS = -L../libs/yxml -lyatexml
zlib.yate: LOCALFLAGS = @ZLIB_INC@ zlibcompress.yate: LOCALFLAGS = @ZLIB_INC@
zlib.yate: LOCALLIBS = @ZLIB_LIB@ zlibcompress.yate: LOCALLIBS = @ZLIB_LIB@
../libyatesig.so ../libs/ysig/libyatesig.a: ../libyatesig.so ../libs/ysig/libyatesig.a:
$(MAKE) -C ../libs/ysig $(MAKE) -C ../libs/ysig

View File

@ -1,5 +1,5 @@
/** /**
* zlib.cpp * zlibcompress.cpp
* This file is part of the YATE Project http://YATE.null.ro * This file is part of the YATE Project http://YATE.null.ro
* *
* ZLib support * ZLib support
@ -24,9 +24,7 @@
#include <yatephone.h> #include <yatephone.h>
#include <string.h> #include <string.h>
#ifdef _WINDOWS
#define ZLIB_WINAPI
#endif
#include <zlib.h> #include <zlib.h>
using namespace TelEngine; using namespace TelEngine;
@ -386,7 +384,7 @@ bool ZLibComp::init(bool comp, bool decomp, const NamedList& params)
* ZLibModule * ZLibModule
*/ */
ZLibModule::ZLibModule() ZLibModule::ZLibModule()
: Module("zlib","misc",true) : Module("zlibcompress","misc",true)
{ {
Output("Loaded module ZLib - using zlib library version %s",zlibVersion()); Output("Loaded module ZLib - using zlib library version %s",zlibVersion());
} }
@ -401,7 +399,7 @@ void ZLibModule::initialize()
static bool first = true; static bool first = true;
Output("Initializing module ZLib"); Output("Initializing module ZLib");
Configuration cfg(Engine::configFile("zlib")); Configuration cfg(Engine::configFile("zlibcompress"));
NamedList dummy(""); NamedList dummy("");
NamedList* gen = cfg.getSection("general"); NamedList* gen = cfg.getSection("general");
if (!gen) if (!gen)

View File

@ -482,7 +482,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_sigtransport", "_sigtransp
{254C6F00-6DE5-44A6-AD44-ACABA8912381} = {254C6F00-6DE5-44A6-AD44-ACABA8912381} {254C6F00-6DE5-44A6-AD44-ACABA8912381} = {254C6F00-6DE5-44A6-AD44-ACABA8912381}
EndProjectSection EndProjectSection
EndProject EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_zlib", "_zlib.vcproj", "{AB81DDE2-2AE9-C12C-9FAC-753E10B5C790}" Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_zlibcompress", "_zlibcompress.vcproj", "{AB81DDE2-2AE9-C12C-9FAC-753E10B5C790}"
ProjectSection(ProjectDependencies) = postProject ProjectSection(ProjectDependencies) = postProject
{254C6F00-6DE5-44A6-AD44-ACABA8912381} = {254C6F00-6DE5-44A6-AD44-ACABA8912381} {254C6F00-6DE5-44A6-AD44-ACABA8912381} = {254C6F00-6DE5-44A6-AD44-ACABA8912381}
EndProjectSection EndProjectSection

View File

@ -2,9 +2,9 @@
<VisualStudioProject <VisualStudioProject
ProjectType="Visual C++" ProjectType="Visual C++"
Version="8.00" Version="8.00"
Name="_zlib" Name="_zlibcompress"
ProjectGUID="{AB81DDE2-2AE9-C12C-9FAC-753E10B5C790}" ProjectGUID="{AB81DDE2-2AE9-C12C-9FAC-753E10B5C790}"
RootNamespace="_zlib" RootNamespace="_zlibcompress"
> >
<Platforms> <Platforms>
<Platform <Platform
@ -42,7 +42,7 @@
MkTypLibCompatible="true" MkTypLibCompatible="true"
SuppressStartupBanner="true" SuppressStartupBanner="true"
TargetEnvironment="1" TargetEnvironment="1"
TypeLibraryName=".\Release/_zlib.tlb" TypeLibraryName=".\Release/_zlibcompress.tlb"
HeaderFileName="" HeaderFileName=""
/> />
<Tool <Tool
@ -50,11 +50,11 @@
Optimization="2" Optimization="2"
InlineFunctionExpansion="1" InlineFunctionExpansion="1"
AdditionalIncludeDirectories=".,.." AdditionalIncludeDirectories=".,.."
PreprocessorDefinitions="NDEBUG;WIN32;_WINDOWS;_USRDLL" PreprocessorDefinitions="NDEBUG;WIN32;_WINDOWS;_USRDLL,ZLIB_WINAPI"
StringPooling="true" StringPooling="true"
RuntimeLibrary="2" RuntimeLibrary="2"
EnableFunctionLevelLinking="true" EnableFunctionLevelLinking="true"
PrecompiledHeaderFile=".\Release\modules/_zlib.pch" PrecompiledHeaderFile=".\Release\modules/_zlibcompress.pch"
AssemblerListingLocation=".\Release\modules/" AssemblerListingLocation=".\Release\modules/"
ObjectFile=".\Release\modules/" ObjectFile=".\Release\modules/"
ProgramDataBaseFileName=".\Release\modules/" ProgramDataBaseFileName=".\Release\modules/"
@ -76,11 +76,11 @@
Name="VCLinkerTool" Name="VCLinkerTool"
IgnoreImportLibrary="true" IgnoreImportLibrary="true"
AdditionalDependencies="zlibstat.lib" AdditionalDependencies="zlibstat.lib"
OutputFile="Release/zlib.yate" OutputFile="Release/zlibcompress.yate"
LinkIncremental="1" LinkIncremental="1"
SuppressStartupBanner="true" SuppressStartupBanner="true"
ProgramDatabaseFile=".\Release/zlib.pdb" ProgramDatabaseFile=".\Release/zlibcompress.pdb"
ImportLibrary=".\Release/zlib.lib" ImportLibrary=".\Release/zlibcompress.lib"
TargetMachine="1" TargetMachine="1"
/> />
<Tool <Tool
@ -95,7 +95,7 @@
<Tool <Tool
Name="VCBscMakeTool" Name="VCBscMakeTool"
SuppressStartupBanner="true" SuppressStartupBanner="true"
OutputFile=".\Release/_zlib.bsc" OutputFile=".\Release/_zlibcompress.bsc"
/> />
<Tool <Tool
Name="VCFxCopTool" Name="VCFxCopTool"
@ -138,18 +138,18 @@
MkTypLibCompatible="true" MkTypLibCompatible="true"
SuppressStartupBanner="true" SuppressStartupBanner="true"
TargetEnvironment="1" TargetEnvironment="1"
TypeLibraryName=".\Debug/_zlib.tlb" TypeLibraryName=".\Debug/_zlibcompress.tlb"
HeaderFileName="" HeaderFileName=""
/> />
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories=".,.." AdditionalIncludeDirectories=".,.."
PreprocessorDefinitions="_DEBUG;WIN32;_WINDOWS;_USRDLL" PreprocessorDefinitions="_DEBUG;WIN32;_WINDOWS;_USRDLL,ZLIB_WINAPI"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
RuntimeLibrary="3" RuntimeLibrary="3"
PrecompiledHeaderFile=".\Debug\modules/_zlib.pch" PrecompiledHeaderFile=".\Debug\modules/_zlibcompress.pch"
AssemblerListingLocation=".\Debug\modules/" AssemblerListingLocation=".\Debug\modules/"
ObjectFile=".\Debug\modules/" ObjectFile=".\Debug\modules/"
ProgramDataBaseFileName=".\Debug\modules/" ProgramDataBaseFileName=".\Debug\modules/"
@ -172,12 +172,12 @@
Name="VCLinkerTool" Name="VCLinkerTool"
IgnoreImportLibrary="true" IgnoreImportLibrary="true"
AdditionalDependencies="zlibstat.lib" AdditionalDependencies="zlibstat.lib"
OutputFile="Debug/zlib.yate" OutputFile="Debug/zlibcompress.yate"
LinkIncremental="1" LinkIncremental="1"
SuppressStartupBanner="true" SuppressStartupBanner="true"
GenerateDebugInformation="true" GenerateDebugInformation="true"
ProgramDatabaseFile=".\Debug/zlib.pdb" ProgramDatabaseFile=".\Debug/zlibcompress.pdb"
ImportLibrary=".\Debug/zlib.lib" ImportLibrary=".\Debug/zlibcompress.lib"
TargetMachine="1" TargetMachine="1"
/> />
<Tool <Tool
@ -192,7 +192,7 @@
<Tool <Tool
Name="VCBscMakeTool" Name="VCBscMakeTool"
SuppressStartupBanner="true" SuppressStartupBanner="true"
OutputFile=".\Debug/_zlib.bsc" OutputFile=".\Debug/_zlibcompress.bsc"
/> />
<Tool <Tool
Name="VCFxCopTool" Name="VCFxCopTool"
@ -216,7 +216,7 @@
Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
> >
<File <File
RelativePath="..\modules\zlib.cpp" RelativePath="..\modules\zlibcompress.cpp"
> >
</File> </File>
</Filter> </Filter>

View File

@ -53,6 +53,8 @@ Name: "codecs\gsm"; Description: "GSM codec"; Types: full client server
Name: "codecs\ilbc"; Description: "iLBC codec"; Types: full client server Name: "codecs\ilbc"; Description: "iLBC codec"; Types: full client server
Name: "codecs\speex"; Description: "SPEEX codec"; Types: full client server Name: "codecs\speex"; Description: "SPEEX codec"; Types: full client server
Name: "codecs\speex\run"; Description: "SPEEX runtime libraries"; Types: full client server Name: "codecs\speex\run"; Description: "SPEEX runtime libraries"; Types: full client server
Name: "compress"; Description: "Data compression support"; Types: full client server
Name: "compress\zlib"; Description: "Zlib compression"; Types: full client server
Name: "external"; Description: "External interfaces"; Types: full server Name: "external"; Description: "External interfaces"; Types: full server
Name: "external\php"; Description: "PHP5 scripting"; Types: full server Name: "external\php"; Description: "PHP5 scripting"; Types: full server
Name: "debug"; Description: "Extra debugging support"; Types: full engine Name: "debug"; Description: "Extra debugging support"; Types: full engine
@ -132,6 +134,8 @@ Source: "Release\gsmcodec.yate"; DestDir: "{app}\modules"; Flags: replacesamever
Source: "Release\ilbccodec.yate"; DestDir: "{app}\modules"; Flags: replacesameversion; Components: codecs\ilbc Source: "Release\ilbccodec.yate"; DestDir: "{app}\modules"; Flags: replacesameversion; Components: codecs\ilbc
Source: "Release\speexcodec.yate"; DestDir: "{app}\modules"; Flags: replacesameversion; Components: codecs\speex Source: "Release\speexcodec.yate"; DestDir: "{app}\modules"; Flags: replacesameversion; Components: codecs\speex
Source: "Release\zlibcompress.yate"; DestDir: "{app}\modules"; Flags: replacesameversion; Components: compress\zlib
Source: "Release\server\mysqldb.yate"; DestDir: "{app}\modules\server"; Flags: replacesameversion; Components: database\my Source: "Release\server\mysqldb.yate"; DestDir: "{app}\modules\server"; Flags: replacesameversion; Components: database\my
Source: "Release\server\pgsqldb.yate"; DestDir: "{app}\modules\server"; Flags: replacesameversion; Components: database\pg Source: "Release\server\pgsqldb.yate"; DestDir: "{app}\modules\server"; Flags: replacesameversion; Components: database\pg