diff --git a/checkin_notes b/checkin_notes index d62405e3cd..bf315968ff 100644 --- a/checkin_notes +++ b/checkin_notes @@ -104,3 +104,18 @@ David 13 June 2006 worker/ Makefile worker.C + +David 13 June 2006 + - added Win project file for worker, + fixed names in project files, got stuff to compile + + uppercase/ + upper_case.C + win_build/ + samples.sln + sleeper.vcproj + worker.vcproj (new) + worker/ + worker.C + wrapper/ + wrapper.C diff --git a/uppercase/upper_case.C b/uppercase/upper_case.C index 6e89cdd583..e57b47c269 100755 --- a/uppercase/upper_case.C +++ b/uppercase/upper_case.C @@ -94,21 +94,6 @@ static void use_some_cpu() { } } -#ifdef _WIN32 - -extern int main(int argc, char** argv); - -int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR Args, int WinMode) { - LPSTR command_line; - char* argv[100]; - int argc; - - command_line = GetCommandLine(); - argc = parse_command_line( command_line, argv ); - return main(argc, argv); -} -#endif - void worker() { int c, nchars = 0, retval; double fsize; @@ -271,4 +256,16 @@ int main(int argc, char **argv) { #endif } +#ifdef _WIN32 +int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR Args, int WinMode) { + LPSTR command_line; + char* argv[100]; + int argc; + + command_line = GetCommandLine(); + argc = parse_command_line( command_line, argv ); + return main(argc, argv); +} +#endif + const char *BOINC_RCSID_33ac47a071 = "$Id$"; diff --git a/win_build/samples.sln b/win_build/samples.sln index 70d55af8b5..0a04268341 100644 --- a/win_build/samples.sln +++ b/win_build/samples.sln @@ -40,6 +40,11 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "sleeper", "sleeper.vcproj", {E8F6BD7E-461A-4733-B7D8-37B09A099ED8} = {E8F6BD7E-461A-4733-B7D8-37B09A099ED8} EndProjectSection EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "worker", "worker.vcproj", "{8281D898-0E64-44EB-8356-4F0336F19A35}" + ProjectSection(ProjectDependencies) = postProject + {E8F6BD7E-461A-4733-B7D8-37B09A099ED8} = {E8F6BD7E-461A-4733-B7D8-37B09A099ED8} + EndProjectSection +EndProject Global GlobalSection(SolutionConfiguration) = preSolution Debug = Debug @@ -78,6 +83,10 @@ Global {8281D898-0E64-44EB-8356-4F0336F19A35}.Debug.Build.0 = Debug|Win32 {8281D898-0E64-44EB-8356-4F0336F19A35}.Release.ActiveCfg = Release|Win32 {8281D898-0E64-44EB-8356-4F0336F19A35}.Release.Build.0 = Release|Win32 + {8281D898-0E64-44EB-8356-4F0336F19A35}.Debug.ActiveCfg = Debug|Win32 + {8281D898-0E64-44EB-8356-4F0336F19A35}.Debug.Build.0 = Debug|Win32 + {8281D898-0E64-44EB-8356-4F0336F19A35}.Release.ActiveCfg = Release|Win32 + {8281D898-0E64-44EB-8356-4F0336F19A35}.Release.Build.0 = Release|Win32 EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution EndGlobalSection diff --git a/win_build/sleeper.vcproj b/win_build/sleeper.vcproj index 466ac85fdf..c2be64fcc3 100644 --- a/win_build/sleeper.vcproj +++ b/win_build/sleeper.vcproj @@ -51,7 +51,7 @@ IgnoreAllDefaultLibraries="TRUE" DelayLoadDLLs="" GenerateDebugInformation="TRUE" - ProgramDatabaseFile="Release/uppercase_5.10_windows_intelx86.pdb" + ProgramDatabaseFile="Release/sleeper_5.10_windows_intelx86.pdb" SubSystem="2" TargetMachine="1"/> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/win_build/wrapper.vcproj b/win_build/wrapper.vcproj index 96ad64aedc..3eebc04054 100644 --- a/win_build/wrapper.vcproj +++ b/win_build/wrapper.vcproj @@ -45,13 +45,13 @@ #include +#include "util.h" -int main() { +int main(int, char**) { FILE* in = fopen("in", "r"); FILE* out = fopen("out", "w"); char buf[256]; @@ -42,3 +43,15 @@ int main() { fputs("done!\n", out); fclose(out); } + +#ifdef _WIN32 +int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR Args, int WinMode) { + LPSTR command_line; + char* argv[100]; + int argc; + + command_line = GetCommandLine(); + argc = parse_command_line( command_line, argv ); + return main(argc, argv); +} +#endif diff --git a/wrapper/wrapper.C b/wrapper/wrapper.C index d6fd6e25ed..68cd4d5dfc 100644 --- a/wrapper/wrapper.C +++ b/wrapper/wrapper.C @@ -45,6 +45,7 @@ #include #include #ifdef _WIN32 +#include "boinc_win.h" #else #include #include