... | ... |
@@ -3,6 +3,11 @@ Microsoft Visual Studio Solution File, Format Version 10.00 |
3 | 3 |
# Visual C++ Express 2008 |
4 | 4 |
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libclamav", "libclamav.vcproj", "{3AD5B16C-340A-40AC-96AD-6017B941A316}" |
5 | 5 |
EndProject |
6 |
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "clamscan", "clamscan.vcproj", "{F79E7CA7-E49D-479E-8D68-0EA9CB585575}" |
|
7 |
+ ProjectSection(ProjectDependencies) = postProject |
|
8 |
+ {3AD5B16C-340A-40AC-96AD-6017B941A316} = {3AD5B16C-340A-40AC-96AD-6017B941A316} |
|
9 |
+ EndProjectSection |
|
10 |
+EndProject |
|
6 | 11 |
Global |
7 | 12 |
GlobalSection(SolutionConfigurationPlatforms) = preSolution |
8 | 13 |
Debug|Win32 = Debug|Win32 |
... | ... |
@@ -13,6 +18,10 @@ Global |
13 | 13 |
{3AD5B16C-340A-40AC-96AD-6017B941A316}.Debug|Win32.Build.0 = Debug|Win32 |
14 | 14 |
{3AD5B16C-340A-40AC-96AD-6017B941A316}.Release|Win32.ActiveCfg = Release|Win32 |
15 | 15 |
{3AD5B16C-340A-40AC-96AD-6017B941A316}.Release|Win32.Build.0 = Release|Win32 |
16 |
+ {F79E7CA7-E49D-479E-8D68-0EA9CB585575}.Debug|Win32.ActiveCfg = Debug|Win32 |
|
17 |
+ {F79E7CA7-E49D-479E-8D68-0EA9CB585575}.Debug|Win32.Build.0 = Debug|Win32 |
|
18 |
+ {F79E7CA7-E49D-479E-8D68-0EA9CB585575}.Release|Win32.ActiveCfg = Release|Win32 |
|
19 |
+ {F79E7CA7-E49D-479E-8D68-0EA9CB585575}.Release|Win32.Build.0 = Release|Win32 |
|
16 | 20 |
EndGlobalSection |
17 | 21 |
GlobalSection(SolutionProperties) = preSolution |
18 | 22 |
HideSolutionNode = FALSE |
19 | 23 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,239 @@ |
0 |
+<?xml version="1.0" encoding="Windows-1252"?> |
|
1 |
+<VisualStudioProject |
|
2 |
+ ProjectType="Visual C++" |
|
3 |
+ Version="9,00" |
|
4 |
+ Name="clamscan" |
|
5 |
+ ProjectGUID="{F79E7CA7-E49D-479E-8D68-0EA9CB585575}" |
|
6 |
+ RootNamespace="clamscan" |
|
7 |
+ Keyword="Win32Proj" |
|
8 |
+ TargetFrameworkVersion="196613" |
|
9 |
+ > |
|
10 |
+ <Platforms> |
|
11 |
+ <Platform |
|
12 |
+ Name="Win32" |
|
13 |
+ /> |
|
14 |
+ </Platforms> |
|
15 |
+ <ToolFiles> |
|
16 |
+ </ToolFiles> |
|
17 |
+ <Configurations> |
|
18 |
+ <Configuration |
|
19 |
+ Name="Debug|Win32" |
|
20 |
+ OutputDirectory="$(SolutionDir)$(ConfigurationName)" |
|
21 |
+ IntermediateDirectory="$(SolutionDir)build\$(ProjectName)\$(ConfigurationName)" |
|
22 |
+ ConfigurationType="1" |
|
23 |
+ CharacterSet="2" |
|
24 |
+ > |
|
25 |
+ <Tool |
|
26 |
+ Name="VCPreBuildEventTool" |
|
27 |
+ /> |
|
28 |
+ <Tool |
|
29 |
+ Name="VCCustomBuildTool" |
|
30 |
+ /> |
|
31 |
+ <Tool |
|
32 |
+ Name="VCXMLDataGeneratorTool" |
|
33 |
+ /> |
|
34 |
+ <Tool |
|
35 |
+ Name="VCWebServiceProxyGeneratorTool" |
|
36 |
+ /> |
|
37 |
+ <Tool |
|
38 |
+ Name="VCMIDLTool" |
|
39 |
+ /> |
|
40 |
+ <Tool |
|
41 |
+ Name="VCCLCompilerTool" |
|
42 |
+ Optimization="0" |
|
43 |
+ AdditionalIncludeDirectories=""$(SolutionDir)";"$(SolutionDir)..\libclamav";"$(SolutionDir)compat";"$(SolutionDir)3rdparty\zlib";"$(SolutionDir)3rdparty\pthreads";"$(SolutionDir)3rdparty\bzip2";"$(SolutionDir).."" |
|
44 |
+ PreprocessorDefinitions="WIN32_LEAN_AND_MEAN;HAVE_CONFIG_H" |
|
45 |
+ MinimalRebuild="true" |
|
46 |
+ BasicRuntimeChecks="3" |
|
47 |
+ RuntimeLibrary="3" |
|
48 |
+ UsePrecompiledHeader="0" |
|
49 |
+ WarningLevel="3" |
|
50 |
+ DebugInformationFormat="4" |
|
51 |
+ CompileAs="1" |
|
52 |
+ DisableSpecificWarnings="4996;4244;4018;4090;4333;4101;4146" |
|
53 |
+ /> |
|
54 |
+ <Tool |
|
55 |
+ Name="VCManagedResourceCompilerTool" |
|
56 |
+ /> |
|
57 |
+ <Tool |
|
58 |
+ Name="VCResourceCompilerTool" |
|
59 |
+ /> |
|
60 |
+ <Tool |
|
61 |
+ Name="VCPreLinkEventTool" |
|
62 |
+ /> |
|
63 |
+ <Tool |
|
64 |
+ Name="VCLinkerTool" |
|
65 |
+ LinkIncremental="2" |
|
66 |
+ GenerateDebugInformation="true" |
|
67 |
+ SubSystem="1" |
|
68 |
+ TargetMachine="1" |
|
69 |
+ /> |
|
70 |
+ <Tool |
|
71 |
+ Name="VCALinkTool" |
|
72 |
+ /> |
|
73 |
+ <Tool |
|
74 |
+ Name="VCManifestTool" |
|
75 |
+ /> |
|
76 |
+ <Tool |
|
77 |
+ Name="VCXDCMakeTool" |
|
78 |
+ /> |
|
79 |
+ <Tool |
|
80 |
+ Name="VCBscMakeTool" |
|
81 |
+ /> |
|
82 |
+ <Tool |
|
83 |
+ Name="VCFxCopTool" |
|
84 |
+ /> |
|
85 |
+ <Tool |
|
86 |
+ Name="VCAppVerifierTool" |
|
87 |
+ /> |
|
88 |
+ <Tool |
|
89 |
+ Name="VCPostBuildEventTool" |
|
90 |
+ /> |
|
91 |
+ </Configuration> |
|
92 |
+ <Configuration |
|
93 |
+ Name="Release|Win32" |
|
94 |
+ OutputDirectory="$(SolutionDir)$(ConfigurationName)" |
|
95 |
+ IntermediateDirectory="$(SolutionDir)build\$(ProjectName)\$(ConfigurationName)" |
|
96 |
+ ConfigurationType="1" |
|
97 |
+ CharacterSet="2" |
|
98 |
+ WholeProgramOptimization="1" |
|
99 |
+ > |
|
100 |
+ <Tool |
|
101 |
+ Name="VCPreBuildEventTool" |
|
102 |
+ /> |
|
103 |
+ <Tool |
|
104 |
+ Name="VCCustomBuildTool" |
|
105 |
+ /> |
|
106 |
+ <Tool |
|
107 |
+ Name="VCXMLDataGeneratorTool" |
|
108 |
+ /> |
|
109 |
+ <Tool |
|
110 |
+ Name="VCWebServiceProxyGeneratorTool" |
|
111 |
+ /> |
|
112 |
+ <Tool |
|
113 |
+ Name="VCMIDLTool" |
|
114 |
+ /> |
|
115 |
+ <Tool |
|
116 |
+ Name="VCCLCompilerTool" |
|
117 |
+ Optimization="2" |
|
118 |
+ EnableIntrinsicFunctions="true" |
|
119 |
+ AdditionalIncludeDirectories=""$(SolutionDir)";"$(SolutionDir)..\libclamav";"$(SolutionDir)compat";"$(SolutionDir)3rdparty\zlib";"$(SolutionDir)3rdparty\pthreads";"$(SolutionDir)3rdparty\bzip2";"$(SolutionDir).."" |
|
120 |
+ PreprocessorDefinitions="WIN32_LEAN_AND_MEAN;HAVE_CONFIG_H" |
|
121 |
+ RuntimeLibrary="2" |
|
122 |
+ EnableFunctionLevelLinking="true" |
|
123 |
+ UsePrecompiledHeader="0" |
|
124 |
+ WarningLevel="3" |
|
125 |
+ DebugInformationFormat="3" |
|
126 |
+ CompileAs="1" |
|
127 |
+ DisableSpecificWarnings="4996;4244;4018;4090;4333;4101;4146" |
|
128 |
+ /> |
|
129 |
+ <Tool |
|
130 |
+ Name="VCManagedResourceCompilerTool" |
|
131 |
+ /> |
|
132 |
+ <Tool |
|
133 |
+ Name="VCResourceCompilerTool" |
|
134 |
+ /> |
|
135 |
+ <Tool |
|
136 |
+ Name="VCPreLinkEventTool" |
|
137 |
+ /> |
|
138 |
+ <Tool |
|
139 |
+ Name="VCLinkerTool" |
|
140 |
+ LinkIncremental="1" |
|
141 |
+ GenerateDebugInformation="true" |
|
142 |
+ SubSystem="1" |
|
143 |
+ OptimizeReferences="2" |
|
144 |
+ EnableCOMDATFolding="2" |
|
145 |
+ TargetMachine="1" |
|
146 |
+ /> |
|
147 |
+ <Tool |
|
148 |
+ Name="VCALinkTool" |
|
149 |
+ /> |
|
150 |
+ <Tool |
|
151 |
+ Name="VCManifestTool" |
|
152 |
+ /> |
|
153 |
+ <Tool |
|
154 |
+ Name="VCXDCMakeTool" |
|
155 |
+ /> |
|
156 |
+ <Tool |
|
157 |
+ Name="VCBscMakeTool" |
|
158 |
+ /> |
|
159 |
+ <Tool |
|
160 |
+ Name="VCFxCopTool" |
|
161 |
+ /> |
|
162 |
+ <Tool |
|
163 |
+ Name="VCAppVerifierTool" |
|
164 |
+ /> |
|
165 |
+ <Tool |
|
166 |
+ Name="VCPostBuildEventTool" |
|
167 |
+ /> |
|
168 |
+ </Configuration> |
|
169 |
+ </Configurations> |
|
170 |
+ <References> |
|
171 |
+ </References> |
|
172 |
+ <Files> |
|
173 |
+ <Filter |
|
174 |
+ Name="Source Files" |
|
175 |
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx" |
|
176 |
+ UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}" |
|
177 |
+ > |
|
178 |
+ <File |
|
179 |
+ RelativePath="..\clamscan\clamscan.c" |
|
180 |
+ > |
|
181 |
+ </File> |
|
182 |
+ <File |
|
183 |
+ RelativePath="..\clamscan\manager.c" |
|
184 |
+ > |
|
185 |
+ </File> |
|
186 |
+ <File |
|
187 |
+ RelativePath="..\clamscan\others.c" |
|
188 |
+ > |
|
189 |
+ </File> |
|
190 |
+ <Filter |
|
191 |
+ Name="shared" |
|
192 |
+ > |
|
193 |
+ <File |
|
194 |
+ RelativePath="..\shared\actions.c" |
|
195 |
+ > |
|
196 |
+ </File> |
|
197 |
+ <File |
|
198 |
+ RelativePath="..\shared\getopt.c" |
|
199 |
+ > |
|
200 |
+ </File> |
|
201 |
+ <File |
|
202 |
+ RelativePath="..\shared\misc.c" |
|
203 |
+ > |
|
204 |
+ </File> |
|
205 |
+ <File |
|
206 |
+ RelativePath="..\shared\optparser.c" |
|
207 |
+ > |
|
208 |
+ </File> |
|
209 |
+ <File |
|
210 |
+ RelativePath="..\shared\output.c" |
|
211 |
+ > |
|
212 |
+ </File> |
|
213 |
+ </Filter> |
|
214 |
+ <Filter |
|
215 |
+ Name="compat" |
|
216 |
+ > |
|
217 |
+ <File |
|
218 |
+ RelativePath=".\compat\libgen.c" |
|
219 |
+ > |
|
220 |
+ </File> |
|
221 |
+ </Filter> |
|
222 |
+ </Filter> |
|
223 |
+ <Filter |
|
224 |
+ Name="Header Files" |
|
225 |
+ Filter="h;hpp;hxx;hm;inl;inc;xsd" |
|
226 |
+ UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}" |
|
227 |
+ > |
|
228 |
+ </Filter> |
|
229 |
+ <Filter |
|
230 |
+ Name="Resource Files" |
|
231 |
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav" |
|
232 |
+ UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}" |
|
233 |
+ > |
|
234 |
+ </Filter> |
|
235 |
+ </Files> |
|
236 |
+ <Globals> |
|
237 |
+ </Globals> |
|
238 |
+</VisualStudioProject> |
61 | 62 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,153 @@ |
0 |
+/* |
|
1 |
+ * Copyright (C) 2009 Sourcefire, Inc. |
|
2 |
+ * |
|
3 |
+ * Authors: aCaB <acab@clamav.net> |
|
4 |
+ * |
|
5 |
+ * This program is free software; you can redistribute it and/or modify |
|
6 |
+ * it under the terms of the GNU General Public License version 2 as |
|
7 |
+ * published by the Free Software Foundation. |
|
8 |
+ * |
|
9 |
+ * This program is distributed in the hope that it will be useful, |
|
10 |
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
11 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
12 |
+ * GNU General Public License for more details. |
|
13 |
+ * |
|
14 |
+ * You should have received a copy of the GNU General Public License |
|
15 |
+ * along with this program; if not, write to the Free Software |
|
16 |
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, |
|
17 |
+ * MA 02110-1301, USA. |
|
18 |
+ */ |
|
19 |
+ |
|
20 |
+#include <string.h> |
|
21 |
+#include "libgen.h" |
|
22 |
+ |
|
23 |
+/* |
|
24 |
+Note: an exact implementation of is not really possible, but this is good enough for us |
|
25 |
+ |
|
26 |
+*path* *dirname* *basename* |
|
27 |
+ |
|
28 |
+"C:" "C:" "" |
|
29 |
+"C:\" "C:" "" |
|
30 |
+"C:\\" "C:" "" |
|
31 |
+"C:file" "C:file" "" |
|
32 |
+"C:file\" "C:file" "" |
|
33 |
+"C:\file" "C:" "file" |
|
34 |
+"C:\file\" "C:" "file" |
|
35 |
+"C:\path\file" "C:\path" "file" |
|
36 |
+"C:\path\file\" "C:\path" "file" |
|
37 |
+ |
|
38 |
+"\\net" "\\net" "" |
|
39 |
+"\\net\" "\\net" "" |
|
40 |
+"\\net\share" "\\net" "share" |
|
41 |
+"\\net\share\" "\\net" "share" |
|
42 |
+"\\net\share\file" "\\net\share" "file" |
|
43 |
+"\\net\share\file\" "\\net\share" "file" |
|
44 |
+"\\net\share\path\file" "\\net\share\path" "file" |
|
45 |
+"\\net\share\path\file\" "\\net\share\path" "file" |
|
46 |
+ |
|
47 |
+"\\?\C:" "\\?\C:" "" |
|
48 |
+"\\?\C:\" "\\?\C:" "" |
|
49 |
+"\\?\C:\\" "\\?\C:" "" |
|
50 |
+"\\?\C:\file" "\\?\C:" "file" |
|
51 |
+"\\?\C:\file\" "\\?\C:" "file" |
|
52 |
+"\\?\C:\path\file" "\\?\C:\path" "file" |
|
53 |
+"\\?\C:\path\file\" "\\?\C:\path" "file" |
|
54 |
+ |
|
55 |
+"\" "" "" |
|
56 |
+"\\" "" "" |
|
57 |
+"\file" "" "file" |
|
58 |
+"\file\" "" "file" |
|
59 |
+"\path\file" "\path" "file" |
|
60 |
+"\path\file\" "\path" "file" |
|
61 |
+ |
|
62 |
+"." "." "" |
|
63 |
+".\" "." "" |
|
64 |
+".." ".." "" |
|
65 |
+"..\" ".." "" |
|
66 |
+"file" "." "file" |
|
67 |
+"file\" "." "file" |
|
68 |
+"path\file" "path" "file" |
|
69 |
+"path\file\" "path" "file" |
|
70 |
+ |
|
71 |
+"\\.\PhysicalDrive0" "\\.\PhysicalDrive0" "" |
|
72 |
+"\\.\PhysicalDrive0\other" "\\.\PhysicalDrive0" "other" |
|
73 |
+ |
|
74 |
+"" "." "" |
|
75 |
+NULL "." "" |
|
76 |
+ |
|
77 |
+ |
|
78 |
+Hopefully I didn't miss anything... |
|
79 |
+ |
|
80 |
+*/ |
|
81 |
+ |
|
82 |
+ |
|
83 |
+static void splitpath(char *path, char **dir, char **base) { |
|
84 |
+ char *startpath, *endpath; |
|
85 |
+ int len; |
|
86 |
+ if(!path || !(len = strlen(path))) { |
|
87 |
+ *dir = "."; |
|
88 |
+ *base = ""; |
|
89 |
+ return; |
|
90 |
+ } |
|
91 |
+ |
|
92 |
+ endpath = &path[len-1]; |
|
93 |
+ while(endpath >= path && *endpath == '\\') { |
|
94 |
+ *endpath = '\0'; |
|
95 |
+ endpath--; |
|
96 |
+ } |
|
97 |
+ if(endpath < path) { |
|
98 |
+ *dir = ""; |
|
99 |
+ *base = ""; |
|
100 |
+ return; |
|
101 |
+ } |
|
102 |
+ len = endpath-path + 1; |
|
103 |
+ if(len > 2 && path[0] == '\\' && path[1] == '\\') { |
|
104 |
+ if(len > 4 && (path[2] == '.' || path[2] == '?') && path[3] == '\\') |
|
105 |
+ startpath = strchr(path + 4, '\\'); |
|
106 |
+ else |
|
107 |
+ startpath = strchr(path + 2, '\\'); |
|
108 |
+ |
|
109 |
+ if(!startpath) { |
|
110 |
+ *dir = path; |
|
111 |
+ *base = ""; |
|
112 |
+ return; |
|
113 |
+ } |
|
114 |
+ startpath ++; |
|
115 |
+ } else startpath = path; |
|
116 |
+ endpath = strrchr(startpath, '\\'); |
|
117 |
+ if(!endpath) { |
|
118 |
+ if(startpath == path) { |
|
119 |
+ if(!strcmp(path, ".") || !strcmp(path, "..") || (len >= 2 && ((*path >= 'a' && *path <= 'z') || (*path >= 'A' && *path <= 'Z')) && path[1] == ':')) { |
|
120 |
+ *dir = path; |
|
121 |
+ *base = ""; |
|
122 |
+ return; |
|
123 |
+ } |
|
124 |
+ *dir = "."; |
|
125 |
+ *base = path; |
|
126 |
+ return; |
|
127 |
+ } |
|
128 |
+ *base = startpath; |
|
129 |
+ endpath = startpath - 1; |
|
130 |
+ startpath = path; |
|
131 |
+ } else { |
|
132 |
+ *base = endpath + 1; |
|
133 |
+ } |
|
134 |
+ *dir = path; |
|
135 |
+ |
|
136 |
+ while(endpath >= startpath && *endpath == '\\') { |
|
137 |
+ *endpath = '\0'; |
|
138 |
+ endpath--; |
|
139 |
+ } |
|
140 |
+} |
|
141 |
+ |
|
142 |
+char *dirname(char *path) { |
|
143 |
+ char *dir, *base; |
|
144 |
+ splitpath(path, &dir, &base); |
|
145 |
+ return dir; |
|
146 |
+} |
|
147 |
+ |
|
148 |
+char *basename(char *path) { |
|
149 |
+ char *dir, *base; |
|
150 |
+ splitpath(path, &dir, &base); |
|
151 |
+ return base; |
|
152 |
+} |
0 | 153 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,31 @@ |
0 |
+/* |
|
1 |
+ * Copyright (C) 2009 Sourcefire, Inc. |
|
2 |
+ * |
|
3 |
+ * Authors: aCaB <acab@clamav.net> |
|
4 |
+ * |
|
5 |
+ * This program is free software; you can redistribute it and/or modify |
|
6 |
+ * it under the terms of the GNU General Public License version 2 as |
|
7 |
+ * published by the Free Software Foundation. |
|
8 |
+ * |
|
9 |
+ * This program is distributed in the hope that it will be useful, |
|
10 |
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
11 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
12 |
+ * GNU General Public License for more details. |
|
13 |
+ * |
|
14 |
+ * You should have received a copy of the GNU General Public License |
|
15 |
+ * along with this program; if not, write to the Free Software |
|
16 |
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, |
|
17 |
+ * MA 02110-1301, USA. |
|
18 |
+ */ |
|
19 |
+ |
|
20 |
+#ifndef __LIBGEN_H |
|
21 |
+#define __LIBGEN_H |
|
22 |
+ |
|
23 |
+#if HAVE_CONFIG_H |
|
24 |
+#include "clamav-config.h" |
|
25 |
+#endif |
|
26 |
+ |
|
27 |
+char *dirname(char *path); |
|
28 |
+char *basename(char *path); |
|
29 |
+ |
|
30 |
+#endif /* __LIBGEN_H */ |
|
0 | 31 |
\ No newline at end of file |
1 | 32 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,38 @@ |
0 |
+LIBRARY libclamav |
|
1 |
+; cl_stuff - should be exported as is |
|
2 |
+EXPORTS cl_debug |
|
3 |
+EXPORTS cl_load |
|
4 |
+EXPORTS cl_engine_compile |
|
5 |
+EXPORTS cl_engine_set_num |
|
6 |
+EXPORTS cl_engine_set_str |
|
7 |
+EXPORTS cl_engine_free |
|
8 |
+EXPORTS cl_engine_new |
|
9 |
+EXPORTS cl_strerror |
|
10 |
+EXPORTS cl_init |
|
11 |
+EXPORTS cl_retdbdir |
|
12 |
+EXPORTS cl_scandesc |
|
13 |
+EXPORTS cl_scanfile |
|
14 |
+EXPORTS cl_cvdfree |
|
15 |
+EXPORTS cl_cvdhead |
|
16 |
+ |
|
17 |
+; cli_stuff - should be mangled or exported by ordinal only |
|
18 |
+EXPORTS cli_gentemp |
|
19 |
+EXPORTS cli_gettmpdir |
|
20 |
+EXPORTS cli_regcomp |
|
21 |
+EXPORTS cli_regexec |
|
22 |
+EXPORTS cli_regfree |
|
23 |
+EXPORTS cli_ctime |
|
24 |
+ |
|
25 |
+; shared stuff - to be either double compiled into the tools or treated like cli_xxx |
|
26 |
+EXPORTS gettimeofday |
|
27 |
+EXPORTS opendir |
|
28 |
+EXPORTS readdir |
|
29 |
+EXPORTS closedir |
|
30 |
+EXPORTS snprintf |
|
31 |
+ |
|
32 |
+; winsock - bridging for now |
|
33 |
+EXPORTS htonl |
|
34 |
+EXPORTS htons |
|
35 |
+EXPORTS send |
|
36 |
+EXPORTS select |
|
37 |
+EXPORTS gethostbyname |
... | ... |
@@ -19,7 +19,7 @@ |
19 | 19 |
<Configuration |
20 | 20 |
Name="Debug|Win32" |
21 | 21 |
OutputDirectory="$(SolutionDir)$(ConfigurationName)" |
22 |
- IntermediateDirectory="build\$(ProjectName)\$(ConfigurationName)" |
|
22 |
+ IntermediateDirectory="$(SolutionDir)build\$(ProjectName)\$(ConfigurationName)" |
|
23 | 23 |
ConfigurationType="2" |
24 | 24 |
CharacterSet="2" |
25 | 25 |
> |
... | ... |
@@ -41,7 +41,7 @@ |
41 | 41 |
<Tool |
42 | 42 |
Name="VCCLCompilerTool" |
43 | 43 |
Optimization="0" |
44 |
- AdditionalIncludeDirectories=""$(SolutionDir)";"$(SolutionDir)..\libclamav";"$(SolutionDir)\compat";"$(SolutionDir)\3rdparty\zlib";"$(SolutionDir)\3rdparty\pthreads";"$(SolutionDir)\3rdparty\bzip2";"$(SolutionDir).."" |
|
44 |
+ AdditionalIncludeDirectories=""$(SolutionDir)";"$(SolutionDir)..\libclamav";"$(SolutionDir)compat";"$(SolutionDir)3rdparty\zlib";"$(SolutionDir)3rdparty\pthreads";"$(SolutionDir)3rdparty\bzip2";"$(SolutionDir).."" |
|
45 | 45 |
PreprocessorDefinitions="WIN32_LEAN_AND_MEAN;HAVE_CONFIG_H" |
46 | 46 |
MinimalRebuild="true" |
47 | 47 |
BasicRuntimeChecks="3" |
... | ... |
@@ -66,6 +66,7 @@ |
66 | 66 |
AdditionalDependencies="ws2_32.lib" |
67 | 67 |
LinkIncremental="2" |
68 | 68 |
IgnoreAllDefaultLibraries="false" |
69 |
+ ModuleDefinitionFile="$(SolutionDir)libclamav.def" |
|
69 | 70 |
GenerateDebugInformation="true" |
70 | 71 |
SubSystem="2" |
71 | 72 |
TargetMachine="1" |
... | ... |
@@ -95,7 +96,7 @@ |
95 | 95 |
<Configuration |
96 | 96 |
Name="Release|Win32" |
97 | 97 |
OutputDirectory="$(SolutionDir)$(ConfigurationName)" |
98 |
- IntermediateDirectory="build\$(ProjectName)\$(ConfigurationName)" |
|
98 |
+ IntermediateDirectory="$(SolutionDir)build\$(ProjectName)\$(ConfigurationName)" |
|
99 | 99 |
ConfigurationType="2" |
100 | 100 |
CharacterSet="2" |
101 | 101 |
WholeProgramOptimization="1" |
... | ... |
@@ -119,7 +120,7 @@ |
119 | 119 |
Name="VCCLCompilerTool" |
120 | 120 |
Optimization="2" |
121 | 121 |
EnableIntrinsicFunctions="true" |
122 |
- AdditionalIncludeDirectories=""$(SolutionDir)";"$(SolutionDir)..\libclamav";"$(SolutionDir)\compat";"$(SolutionDir)\3rdparty\zlib";"$(SolutionDir)\3rdparty\pthreads";"$(SolutionDir)\3rdparty\bzip2";"$(SolutionDir).."" |
|
122 |
+ AdditionalIncludeDirectories=""$(SolutionDir)";"$(SolutionDir)..\libclamav";"$(SolutionDir)compat";"$(SolutionDir)3rdparty\zlib";"$(SolutionDir)3rdparty\pthreads";"$(SolutionDir)3rdparty\bzip2";"$(SolutionDir).."" |
|
123 | 123 |
PreprocessorDefinitions="WIN32_LEAN_AND_MEAN;HAVE_CONFIG_H" |
124 | 124 |
RuntimeLibrary="2" |
125 | 125 |
EnableFunctionLevelLinking="true" |
... | ... |
@@ -144,6 +145,7 @@ |
144 | 144 |
AdditionalDependencies="ws2_32.lib" |
145 | 145 |
LinkIncremental="1" |
146 | 146 |
IgnoreAllDefaultLibraries="false" |
147 |
+ ModuleDefinitionFile="$(SolutionDir)libclamav.def" |
|
147 | 148 |
GenerateDebugInformation="true" |
148 | 149 |
SubSystem="2" |
149 | 150 |
OptimizeReferences="2" |
... | ... |
@@ -793,6 +795,10 @@ |
793 | 793 |
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav" |
794 | 794 |
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}" |
795 | 795 |
> |
796 |
+ <File |
|
797 |
+ RelativePath=".\libclamav.def" |
|
798 |
+ > |
|
799 |
+ </File> |
|
796 | 800 |
</Filter> |
797 | 801 |
</Files> |
798 | 802 |
<Globals> |
... | ... |
@@ -8,14 +8,20 @@ |
8 | 8 |
#include <io.h> |
9 | 9 |
#include <direct.h> |
10 | 10 |
|
11 |
+#include "gettimeofday.h" |
|
11 | 12 |
#include "snprintf.h" |
12 | 13 |
|
13 | 14 |
typedef int ssize_t; |
15 |
+typedef unsigned short mode_t; |
|
14 | 16 |
#define strcasecmp lstrcmpi |
15 | 17 |
#define strncasecmp strnicmp |
16 | 18 |
#define mkdir(path, mode) mkdir(path) |
17 | 19 |
#define lstat stat |
18 | 20 |
|
21 |
+/* FIXME: need to wrap all win32 and winsock functions and map |
|
22 |
+ (WSA)GetLastError to errno */ |
|
23 |
+#define EWOULDBLOCK 31337 |
|
24 |
+ |
|
19 | 25 |
#define PATH_MAX 32767 |
20 | 26 |
|
21 | 27 |
#define S_IRUSR S_IREAD |