Restructured components.

This commit is contained in:
Gunnar Beutner 2012-04-13 13:10:35 +02:00
parent 851d8e4d85
commit 9bfff6ddb7
20 changed files with 72 additions and 57 deletions

View File

@ -52,10 +52,10 @@ public:
int I2_EXPORT application_main(int argc, char **argv, icinga::Application *instance);
#define SET_START_CLASS(klass) \
int main(int argc, char **argv) { \
klass *instance = new klass(); \
return application_main(argc, argv, instance); \
#define IMPLEMENT_ENTRY_POINT(klass) \
int main(int argc, char **argv) { \
klass *instance = new klass(); \
return application_main(argc, argv, instance); \
}
#endif /* APPLICATION_H */

View File

@ -112,6 +112,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>_WINDLL;I2_BASE_BUILD;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>

View File

@ -66,6 +66,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>

5
components/Makefile.am Normal file
View File

@ -0,0 +1,5 @@
## Process this file with automake to produce Makefile.in
## Created by Anjuta
SUBDIRS = configfile \
configrpc

View File

@ -0,0 +1,17 @@
## Process this file with automake to produce Makefile.in
pkglib_LTLIBRARIES = \
configfile.la
configfile_la_SOURCES = \
configfile.cpp \
configfile.h \
i2-configfile.h
configfile_la_CXXFLAGS = -I${top_srcdir}/base \
-I${top_srcdir}/jsonrpc \
-I${top_srcdir}/cJSON
configfile_la_LDFLAGS = -module -version-info 0:0:0 -no-undefined
configfile_la_LIBADD = ${top_builddir}/base/libbase.la \
${top_builddir}/cJSON/libcJSON.la

View File

@ -15,7 +15,7 @@
</ItemGroup>
<ItemGroup>
<ClInclude Include="configfilecomponent.h" />
<ClInclude Include="i2-configfilecomponent.h" />
<ClInclude Include="i2-configfile.h" />
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{E58F1DA7-B723-412B-B2B7-7FF58E2A944E}</ProjectGuid>
@ -79,6 +79,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>

View File

@ -1,20 +1,20 @@
## Process this file with automake to produce Makefile.in
pkglib_LTLIBRARIES = \
configrpccomponent.la
configrpc.la
configrpccomponent_la_SOURCES = \
configrpc_la_SOURCES = \
configrpccomponent.cpp \
configrpccomponent.h \
i2-configrpccomponent.h
i2-configrpc.h
configrpccomponent_la_CXXFLAGS = -I${top_srcdir}/base \
configrpc_la_CXXFLAGS = -I${top_srcdir}/base \
-I${top_srcdir}/jsonrpc \
-I${top_srcdir}/cJSON \
-I${top_srcdir}/icinga
configrpccomponent_la_LDFLAGS = -module -version-info 0:0:0 -no-undefined -pthread
configrpccomponent_la_LIBADD = ${top_builddir}/base/libbase.la \
configrpc_la_LDFLAGS = -module -version-info 0:0:0 -no-undefined -pthread
configrpc_la_LIBADD = ${top_builddir}/base/libbase.la \
${top_builddir}/jsonrpc/libjsonrpc.la \
${top_builddir}/cJSON/libcJSON.la \
${top_builddir}/icinga/libicinga.la

View File

@ -15,7 +15,7 @@
</ItemGroup>
<ItemGroup>
<ClInclude Include="configrpccomponent.h" />
<ClInclude Include="i2-configrpccomponent.h" />
<ClInclude Include="i2-configrpc.h" />
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{697C6D7E-3109-484C-A7AF-384D28711610}</ProjectGuid>
@ -77,6 +77,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;CONFIGCOMPONENT_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>

View File

@ -1,5 +1,5 @@
#ifndef I2CONFIGCOMPONENT_H
#define I2CONFIGCOMPONENT_H
#ifndef I2CONFIGRPC_H
#define I2CONFIGRPC_H
#include <i2-base.h>
#include <i2-jsonrpc.h>
@ -7,4 +7,4 @@
#include "configrpccomponent.h"
#endif /* I2CONFIGCOMPONENT_H */
#endif /* I2CONFIGRPC_H */

View File

@ -1,17 +0,0 @@
## Process this file with automake to produce Makefile.in
pkglib_LTLIBRARIES = \
configfilecomponent.la
configfilecomponent_la_SOURCES = \
configfilecomponent.cpp \
configfilecomponent.h \
i2-configfilecomponent.h
configfilecomponent_la_CXXFLAGS = -I${top_srcdir}/base \
-I${top_srcdir}/jsonrpc \
-I${top_srcdir}/cJSON
configfilecomponent_la_LDFLAGS = -module -version-info 0:0:0 -no-undefined
configfilecomponent_la_LIBADD = ${top_builddir}/base/libbase.la \
${top_builddir}/cJSON/libcJSON.la

View File

@ -74,6 +74,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;I2_ICINGALAUNCHER_BUILD;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>

View File

@ -1,3 +1,5 @@
#include <i2-icinga.h>
SET_START_CLASS(icinga::IcingaApplication);
using namespace icinga;
IMPLEMENT_ENTRY_POINT(IcingaApplication);

View File

@ -9,27 +9,28 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jsonrpc", "jsonrpc\jsonrpc.
{9C92DA90-FD53-43A9-A244-90F2E8AF9677} = {9C92DA90-FD53-43A9-A244-90F2E8AF9677}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "configfilecomponent", "configfilecomponent\configfilecomponent.vcxproj", "{E58F1DA7-B723-412B-B2B7-7FF58E2A944E}"
ProjectSection(ProjectDependencies) = postProject
{66BED474-C33F-48F9-90BA-BBCFEDC006B8} = {66BED474-C33F-48F9-90BA-BBCFEDC006B8}
{9C92DA90-FD53-43A9-A244-90F2E8AF9677} = {9C92DA90-FD53-43A9-A244-90F2E8AF9677}
{8DD52FAC-ECEE-48C2-B266-E7C47ED485F8} = {8DD52FAC-ECEE-48C2-B266-E7C47ED485F8}
{C1FC77E1-04A4-481B-A78B-2F7AF489C2F8} = {C1FC77E1-04A4-481B-A78B-2F7AF489C2F8}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "configrpccomponent", "configrpccomponent\configrpccomponent.vcxproj", "{697C6D7E-3109-484C-A7AF-384D28711610}"
ProjectSection(ProjectDependencies) = postProject
{66BED474-C33F-48F9-90BA-BBCFEDC006B8} = {66BED474-C33F-48F9-90BA-BBCFEDC006B8}
{9C92DA90-FD53-43A9-A244-90F2E8AF9677} = {9C92DA90-FD53-43A9-A244-90F2E8AF9677}
{8DD52FAC-ECEE-48C2-B266-E7C47ED485F8} = {8DD52FAC-ECEE-48C2-B266-E7C47ED485F8}
{C1FC77E1-04A4-481B-A78B-2F7AF489C2F8} = {C1FC77E1-04A4-481B-A78B-2F7AF489C2F8}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "cJSON", "cJSON\cJSON.vcxproj", "{66BED474-C33F-48F9-90BA-BBCFEDC006B8}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "icinga", "icinga\icinga.vcxproj", "{C1FC77E1-04A4-481B-A78B-2F7AF489C2F8}"
ProjectSection(ProjectDependencies) = postProject
{9C92DA90-FD53-43A9-A244-90F2E8AF9677} = {9C92DA90-FD53-43A9-A244-90F2E8AF9677}
{8DD52FAC-ECEE-48C2-B266-E7C47ED485F8} = {8DD52FAC-ECEE-48C2-B266-E7C47ED485F8}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "icinga-app", "icinga-app\icinga-app.vcxproj", "{BE412865-FEBA-4259-AD41-58950D1F5432}"
ProjectSection(ProjectDependencies) = postProject
{C1FC77E1-04A4-481B-A78B-2F7AF489C2F8} = {C1FC77E1-04A4-481B-A78B-2F7AF489C2F8}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "configfile", "components\configfile\configfile.vcxproj", "{E58F1DA7-B723-412B-B2B7-7FF58E2A944E}"
ProjectSection(ProjectDependencies) = postProject
{C1FC77E1-04A4-481B-A78B-2F7AF489C2F8} = {C1FC77E1-04A4-481B-A78B-2F7AF489C2F8}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "configrpc", "components\configrpc\configrpc.vcxproj", "{697C6D7E-3109-484C-A7AF-384D28711610}"
ProjectSection(ProjectDependencies) = postProject
{C1FC77E1-04A4-481B-A78B-2F7AF489C2F8} = {C1FC77E1-04A4-481B-A78B-2F7AF489C2F8}
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@ -45,14 +46,6 @@ Global
{8DD52FAC-ECEE-48C2-B266-E7C47ED485F8}.Debug|Win32.Build.0 = Debug|Win32
{8DD52FAC-ECEE-48C2-B266-E7C47ED485F8}.Release|Win32.ActiveCfg = Release|Win32
{8DD52FAC-ECEE-48C2-B266-E7C47ED485F8}.Release|Win32.Build.0 = Release|Win32
{E58F1DA7-B723-412B-B2B7-7FF58E2A944E}.Debug|Win32.ActiveCfg = Debug|Win32
{E58F1DA7-B723-412B-B2B7-7FF58E2A944E}.Debug|Win32.Build.0 = Debug|Win32
{E58F1DA7-B723-412B-B2B7-7FF58E2A944E}.Release|Win32.ActiveCfg = Release|Win32
{E58F1DA7-B723-412B-B2B7-7FF58E2A944E}.Release|Win32.Build.0 = Release|Win32
{697C6D7E-3109-484C-A7AF-384D28711610}.Debug|Win32.ActiveCfg = Debug|Win32
{697C6D7E-3109-484C-A7AF-384D28711610}.Debug|Win32.Build.0 = Debug|Win32
{697C6D7E-3109-484C-A7AF-384D28711610}.Release|Win32.ActiveCfg = Release|Win32
{697C6D7E-3109-484C-A7AF-384D28711610}.Release|Win32.Build.0 = Release|Win32
{66BED474-C33F-48F9-90BA-BBCFEDC006B8}.Debug|Win32.ActiveCfg = Debug|Win32
{66BED474-C33F-48F9-90BA-BBCFEDC006B8}.Debug|Win32.Build.0 = Debug|Win32
{66BED474-C33F-48F9-90BA-BBCFEDC006B8}.Release|Win32.ActiveCfg = Release|Win32
@ -65,6 +58,14 @@ Global
{BE412865-FEBA-4259-AD41-58950D1F5432}.Debug|Win32.Build.0 = Debug|Win32
{BE412865-FEBA-4259-AD41-58950D1F5432}.Release|Win32.ActiveCfg = Release|Win32
{BE412865-FEBA-4259-AD41-58950D1F5432}.Release|Win32.Build.0 = Release|Win32
{E58F1DA7-B723-412B-B2B7-7FF58E2A944E}.Debug|Win32.ActiveCfg = Debug|Win32
{E58F1DA7-B723-412B-B2B7-7FF58E2A944E}.Debug|Win32.Build.0 = Debug|Win32
{E58F1DA7-B723-412B-B2B7-7FF58E2A944E}.Release|Win32.ActiveCfg = Release|Win32
{E58F1DA7-B723-412B-B2B7-7FF58E2A944E}.Release|Win32.Build.0 = Release|Win32
{697C6D7E-3109-484C-A7AF-384D28711610}.Debug|Win32.ActiveCfg = Debug|Win32
{697C6D7E-3109-484C-A7AF-384D28711610}.Debug|Win32.Build.0 = Debug|Win32
{697C6D7E-3109-484C-A7AF-384D28711610}.Release|Win32.ActiveCfg = Release|Win32
{697C6D7E-3109-484C-A7AF-384D28711610}.Release|Win32.Build.0 = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE

View File

@ -86,6 +86,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;I2_ICINGA_BUILD;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>

View File

@ -85,6 +85,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;I2_JSONRPC_BUILD;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>