Skip to content

Commit 2d008c9

Browse files
committed
fixed:build error and update read me
1 parent 1c7df2c commit 2d008c9

File tree

12 files changed

+436
-7
lines changed

12 files changed

+436
-7
lines changed

README.en.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ support systems:linux,macos,windows
3030

3131
#### Example Struct
3232
- InfoReport_APPExample information report example
33+
- MSGNotify_APPExample message notify example
34+
- TinyXML2_APPExample xml module example
3335

3436
## install
3537

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@
3131

3232
#### 例子结构
3333
- InfoReport_APPExample 报告模块例子
34+
- MSGNotify_APPExample 消息通知模块例子
35+
- TinyXML2_APPExample XML模块例子
3436

3537
## 安装教程
3638

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
#ifdef _MSC_BUILD
2+
#include <Windows.h>
3+
#include <tchar.h>
4+
#endif
5+
#include <stdio.h>
6+
#include <stdlib.h>
7+
#include <string.h>
8+
#include <thread>
9+
using namespace std;
10+
#include <XEngine_Include/XEngine_CommHdr.h>
11+
#include "../../XEngine_Module/XEngine_MSGNotify/MSGNotify_Define.h"
12+
#include "../../XEngine_Module/XEngine_MSGNotify/MSGNotify_Error.h"
13+
14+
#ifdef _MSC_BUILD
15+
#ifdef _DEBUG
16+
#ifdef _M_X64
17+
#pragma comment(lib,"../../x64/Debug/XEngine_MSGNotify.lib")
18+
#elif _M_ARM64
19+
#pragma comment(lib,"../../ARM64/Debug/XEngine_MSGNotify.lib")
20+
#elif _M_IX86
21+
#pragma comment(lib,"../../Debug/XEngine_MSGNotify.lib")
22+
#endif
23+
#else
24+
#ifdef _M_X64
25+
#pragma comment(lib,"../../x64/Release/XEngine_MSGNotify.lib")
26+
#elif _M_ARM64
27+
#pragma comment(lib,"../../ARM64/Release/XEngine_MSGNotify.lib")
28+
#elif _M_IX86
29+
#pragma comment(lib,"../../Release/XEngine_MSGNotify.lib")
30+
#endif
31+
#endif
32+
#endif
33+
34+
//Linux Macos::g++ -std=c++17 -Wall -g MSGNotify_APPExample.cpp -o MSGNotify_APPExample.exe -L ../../XEngine_Module/XEngine_MSGNotify -lXEngine_MSGNotify
35+
36+
37+
int main()
38+
{
39+
LPCXSTR lpszServiceAddr = _X("smtp://smtp.163.com");
40+
LPCXSTR lpszUser = _X("[email protected]");
41+
LPCXSTR lpszPass = _X("STZsBi3uuJvWsWL3");
42+
LPCXSTR lpszSendAddr = _X("[email protected]");
43+
LPCXSTR lpszSubject = _X("this is test");
44+
LPCXSTR lpszPayload = _X("email from test\r\nand test to 4444");
45+
if (!MSGNotify_EMail_Send(lpszServiceAddr, lpszUser, lpszPass, lpszSendAddr, lpszSubject, lpszPayload))
46+
{
47+
printf("MSGNotify_EMail_Send:%lX\n", MSGNotify_GetLastError());
48+
return -1;
49+
}
50+
printf("MSGNotify_EMail_Send:ok\n");
51+
return 1;
52+
}
Lines changed: 199 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,199 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<ItemGroup Label="ProjectConfigurations">
4+
<ProjectConfiguration Include="Debug|ARM64">
5+
<Configuration>Debug</Configuration>
6+
<Platform>ARM64</Platform>
7+
</ProjectConfiguration>
8+
<ProjectConfiguration Include="Debug|Win32">
9+
<Configuration>Debug</Configuration>
10+
<Platform>Win32</Platform>
11+
</ProjectConfiguration>
12+
<ProjectConfiguration Include="Release|ARM64">
13+
<Configuration>Release</Configuration>
14+
<Platform>ARM64</Platform>
15+
</ProjectConfiguration>
16+
<ProjectConfiguration Include="Release|Win32">
17+
<Configuration>Release</Configuration>
18+
<Platform>Win32</Platform>
19+
</ProjectConfiguration>
20+
<ProjectConfiguration Include="Debug|x64">
21+
<Configuration>Debug</Configuration>
22+
<Platform>x64</Platform>
23+
</ProjectConfiguration>
24+
<ProjectConfiguration Include="Release|x64">
25+
<Configuration>Release</Configuration>
26+
<Platform>x64</Platform>
27+
</ProjectConfiguration>
28+
</ItemGroup>
29+
<PropertyGroup Label="Globals">
30+
<VCProjectVersion>17.0</VCProjectVersion>
31+
<Keyword>Win32Proj</Keyword>
32+
<ProjectGuid>{e6bb33ef-2ff9-4b7c-822c-2f127e9cb066}</ProjectGuid>
33+
<RootNamespace>MSGNotifyAPPExample</RootNamespace>
34+
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
35+
</PropertyGroup>
36+
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
37+
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
38+
<ConfigurationType>Application</ConfigurationType>
39+
<UseDebugLibraries>true</UseDebugLibraries>
40+
<PlatformToolset>v143</PlatformToolset>
41+
<CharacterSet>Unicode</CharacterSet>
42+
</PropertyGroup>
43+
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
44+
<ConfigurationType>Application</ConfigurationType>
45+
<UseDebugLibraries>false</UseDebugLibraries>
46+
<PlatformToolset>v143</PlatformToolset>
47+
<WholeProgramOptimization>true</WholeProgramOptimization>
48+
<CharacterSet>Unicode</CharacterSet>
49+
</PropertyGroup>
50+
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
51+
<ConfigurationType>Application</ConfigurationType>
52+
<UseDebugLibraries>true</UseDebugLibraries>
53+
<PlatformToolset>v143</PlatformToolset>
54+
<CharacterSet>Unicode</CharacterSet>
55+
</PropertyGroup>
56+
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
57+
<ConfigurationType>Application</ConfigurationType>
58+
<UseDebugLibraries>true</UseDebugLibraries>
59+
<PlatformToolset>v143</PlatformToolset>
60+
<CharacterSet>Unicode</CharacterSet>
61+
</PropertyGroup>
62+
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
63+
<ConfigurationType>Application</ConfigurationType>
64+
<UseDebugLibraries>false</UseDebugLibraries>
65+
<PlatformToolset>v143</PlatformToolset>
66+
<WholeProgramOptimization>true</WholeProgramOptimization>
67+
<CharacterSet>Unicode</CharacterSet>
68+
</PropertyGroup>
69+
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
70+
<ConfigurationType>Application</ConfigurationType>
71+
<UseDebugLibraries>false</UseDebugLibraries>
72+
<PlatformToolset>v143</PlatformToolset>
73+
<WholeProgramOptimization>true</WholeProgramOptimization>
74+
<CharacterSet>Unicode</CharacterSet>
75+
</PropertyGroup>
76+
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
77+
<ImportGroup Label="ExtensionSettings">
78+
</ImportGroup>
79+
<ImportGroup Label="Shared">
80+
</ImportGroup>
81+
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
82+
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
83+
</ImportGroup>
84+
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
85+
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
86+
</ImportGroup>
87+
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
88+
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
89+
</ImportGroup>
90+
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
91+
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
92+
</ImportGroup>
93+
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
94+
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
95+
</ImportGroup>
96+
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
97+
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
98+
</ImportGroup>
99+
<PropertyGroup Label="UserMacros" />
100+
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
101+
<IncludePath>$(XEngine_Include);$(IncludePath)</IncludePath>
102+
</PropertyGroup>
103+
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
104+
<IncludePath>$(XEngine_Include);$(IncludePath)</IncludePath>
105+
</PropertyGroup>
106+
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
107+
<IncludePath>$(XEngine_Include);$(IncludePath)</IncludePath>
108+
</PropertyGroup>
109+
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
110+
<ClCompile>
111+
<WarningLevel>Level3</WarningLevel>
112+
<SDLCheck>true</SDLCheck>
113+
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
114+
<ConformanceMode>true</ConformanceMode>
115+
</ClCompile>
116+
<Link>
117+
<SubSystem>Console</SubSystem>
118+
<GenerateDebugInformation>true</GenerateDebugInformation>
119+
</Link>
120+
</ItemDefinitionGroup>
121+
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
122+
<ClCompile>
123+
<WarningLevel>Level3</WarningLevel>
124+
<FunctionLevelLinking>true</FunctionLevelLinking>
125+
<IntrinsicFunctions>true</IntrinsicFunctions>
126+
<SDLCheck>true</SDLCheck>
127+
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
128+
<ConformanceMode>true</ConformanceMode>
129+
</ClCompile>
130+
<Link>
131+
<SubSystem>Console</SubSystem>
132+
<EnableCOMDATFolding>true</EnableCOMDATFolding>
133+
<OptimizeReferences>true</OptimizeReferences>
134+
<GenerateDebugInformation>true</GenerateDebugInformation>
135+
</Link>
136+
</ItemDefinitionGroup>
137+
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
138+
<ClCompile>
139+
<WarningLevel>Level3</WarningLevel>
140+
<SDLCheck>true</SDLCheck>
141+
<PreprocessorDefinitions>_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
142+
<ConformanceMode>true</ConformanceMode>
143+
</ClCompile>
144+
<Link>
145+
<SubSystem>Console</SubSystem>
146+
<GenerateDebugInformation>true</GenerateDebugInformation>
147+
</Link>
148+
</ItemDefinitionGroup>
149+
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
150+
<ClCompile>
151+
<WarningLevel>Level3</WarningLevel>
152+
<SDLCheck>true</SDLCheck>
153+
<PreprocessorDefinitions>_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
154+
<ConformanceMode>true</ConformanceMode>
155+
</ClCompile>
156+
<Link>
157+
<SubSystem>Console</SubSystem>
158+
<GenerateDebugInformation>true</GenerateDebugInformation>
159+
</Link>
160+
</ItemDefinitionGroup>
161+
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
162+
<ClCompile>
163+
<WarningLevel>Level3</WarningLevel>
164+
<FunctionLevelLinking>true</FunctionLevelLinking>
165+
<IntrinsicFunctions>true</IntrinsicFunctions>
166+
<SDLCheck>true</SDLCheck>
167+
<PreprocessorDefinitions>NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
168+
<ConformanceMode>true</ConformanceMode>
169+
</ClCompile>
170+
<Link>
171+
<SubSystem>Console</SubSystem>
172+
<EnableCOMDATFolding>true</EnableCOMDATFolding>
173+
<OptimizeReferences>true</OptimizeReferences>
174+
<GenerateDebugInformation>true</GenerateDebugInformation>
175+
</Link>
176+
</ItemDefinitionGroup>
177+
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
178+
<ClCompile>
179+
<WarningLevel>Level3</WarningLevel>
180+
<FunctionLevelLinking>true</FunctionLevelLinking>
181+
<IntrinsicFunctions>true</IntrinsicFunctions>
182+
<SDLCheck>true</SDLCheck>
183+
<PreprocessorDefinitions>NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
184+
<ConformanceMode>true</ConformanceMode>
185+
</ClCompile>
186+
<Link>
187+
<SubSystem>Console</SubSystem>
188+
<EnableCOMDATFolding>true</EnableCOMDATFolding>
189+
<OptimizeReferences>true</OptimizeReferences>
190+
<GenerateDebugInformation>true</GenerateDebugInformation>
191+
</Link>
192+
</ItemDefinitionGroup>
193+
<ItemGroup>
194+
<ClCompile Include="MSGNotify_APPExample.cpp" />
195+
</ItemGroup>
196+
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
197+
<ImportGroup Label="ExtensionTargets">
198+
</ImportGroup>
199+
</Project>
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<ItemGroup>
4+
<Filter Include="源文件">
5+
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
6+
<Extensions>cpp;c;cc;cxx;c++;cppm;ixx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
7+
</Filter>
8+
<Filter Include="头文件">
9+
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
10+
<Extensions>h;hh;hpp;hxx;h++;hm;inl;inc;ipp;xsd</Extensions>
11+
</Filter>
12+
<Filter Include="资源文件">
13+
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
14+
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
15+
</Filter>
16+
</ItemGroup>
17+
<ItemGroup>
18+
<ClCompile Include="MSGNotify_APPExample.cpp">
19+
<Filter>源文件</Filter>
20+
</ClCompile>
21+
</ItemGroup>
22+
</Project>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<PropertyGroup />
4+
</Project>

0 commit comments

Comments
 (0)