Tweaks again for win32 build

git-svn-id: file:///home/mbr/svn/fwknop/trunk@98 510a4753-2344-4c79-9c09-4d669213fbeb
This commit is contained in:
Damien Stuart
2009-06-07 17:27:12 +00:00
parent 5811d1107b
commit 2fee69dc33
5 changed files with 162 additions and 2 deletions
+1 -1
View File
@@ -184,7 +184,7 @@ main(int argc, char **argv)
res = send_spa_packet(ctx, &options);
if(res < 0)
{
perror("send_spa_packet");
fprintf(stderr, "[*] send_spa_packet: packet not sent.");
return(1);
}
else
+13 -1
View File
@@ -83,7 +83,11 @@ send_spa_packet_udp(char *spa_data, int sd_len, struct sockaddr_in *saddr,
res, sd_len);
}
#ifdef WIN32
closesocket(sock);
#else
close(sock);
#endif
return(res);
}
@@ -108,7 +112,11 @@ send_spa_packet_tcp(char *spa_data, int sd_len, struct sockaddr_in *saddr,
if(res < 0)
{
perror("[*] send_spa_packet_tcp: connect: ");
close(sock);
#ifdef WIN32
closesocket(sock);
#else
close(sock);
#endif
return(-1);
}
@@ -124,7 +132,11 @@ send_spa_packet_tcp(char *spa_data, int sd_len, struct sockaddr_in *saddr,
res, sd_len);
}
#ifdef WIN32
closesocket(sock);
#else
close(sock);
#endif
return(res);
}
+80
View File
@@ -331,6 +331,86 @@
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release-full-static|Win32"
OutputDirectory="$(SolutionDir)$(ConfigurationName)"
IntermediateDirectory="$(ConfigurationName)"
ConfigurationType="1"
CharacterSet="1"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="2"
EnableIntrinsicFunctions="true"
AdditionalIncludeDirectories=".;../fko;../src"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;HAVE_CONFIG_H;_CRT_SECURE_NO_WARNINGS"
ExceptionHandling="0"
RuntimeLibrary="0"
EnableFunctionLevelLinking="true"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="0"
CompileAs="1"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
AdditionalDependencies=" libfko.lib ws2_32.lib"
OutputFile="$(OutDir)\fwknop.exe"
LinkIncremental="1"
AdditionalLibraryDirectories="$(OutDir)"
GenerateDebugInformation="false"
SubSystem="1"
OptimizeReferences="2"
EnableCOMDATFolding="2"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
+5
View File
@@ -13,6 +13,7 @@ Global
Debug|Win32 = Debug|Win32
Debug-static|Win32 = Debug-static|Win32
Release|Win32 = Release|Win32
Release-full-static|Win32 = Release-full-static|Win32
Release-static|Win32 = Release-static|Win32
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
@@ -22,6 +23,8 @@ Global
{133BC195-4877-481D-9F56-9F1BEBAD21F0}.Debug-static|Win32.Build.0 = Debug-static|Win32
{133BC195-4877-481D-9F56-9F1BEBAD21F0}.Release|Win32.ActiveCfg = Release|Win32
{133BC195-4877-481D-9F56-9F1BEBAD21F0}.Release|Win32.Build.0 = Release|Win32
{133BC195-4877-481D-9F56-9F1BEBAD21F0}.Release-full-static|Win32.ActiveCfg = Release-full-static|Win32
{133BC195-4877-481D-9F56-9F1BEBAD21F0}.Release-full-static|Win32.Build.0 = Release-full-static|Win32
{133BC195-4877-481D-9F56-9F1BEBAD21F0}.Release-static|Win32.ActiveCfg = Release-static|Win32
{133BC195-4877-481D-9F56-9F1BEBAD21F0}.Release-static|Win32.Build.0 = Release-static|Win32
{D8AFA02D-14BF-42F4-97DE-EF4924D046D6}.Debug|Win32.ActiveCfg = Debug|Win32
@@ -30,6 +33,8 @@ Global
{D8AFA02D-14BF-42F4-97DE-EF4924D046D6}.Debug-static|Win32.Build.0 = Debug-static|Win32
{D8AFA02D-14BF-42F4-97DE-EF4924D046D6}.Release|Win32.ActiveCfg = Release|Win32
{D8AFA02D-14BF-42F4-97DE-EF4924D046D6}.Release|Win32.Build.0 = Release|Win32
{D8AFA02D-14BF-42F4-97DE-EF4924D046D6}.Release-full-static|Win32.ActiveCfg = Release-full-static|Win32
{D8AFA02D-14BF-42F4-97DE-EF4924D046D6}.Release-full-static|Win32.Build.0 = Release-full-static|Win32
{D8AFA02D-14BF-42F4-97DE-EF4924D046D6}.Release-static|Win32.ActiveCfg = Release-static|Win32
{D8AFA02D-14BF-42F4-97DE-EF4924D046D6}.Release-static|Win32.Build.0 = Release-static|Win32
EndGlobalSection
+63
View File
@@ -287,6 +287,69 @@
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release-full-static|Win32"
OutputDirectory="$(SolutionDir)$(ConfigurationName)"
IntermediateDirectory="$(ConfigurationName)"
ConfigurationType="4"
CharacterSet="1"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="2"
EnableIntrinsicFunctions="false"
AdditionalIncludeDirectories=".;..\fko;..\src"
PreprocessorDefinitions="WIN32;HAVE_CONFIG_H;_CRT_SECURE_NO_WARNINGS"
RuntimeLibrary="0"
EnableFunctionLevelLinking="true"
UsePrecompiledHeader="0"
WarningLevel="3"
CompileAs="1"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>