summaryrefslogtreecommitdiff
path: root/win
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-05-20 03:51:26 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-05-20 03:51:26 +0000
commitde57b89e968a30481df2e3a05db9611d4b4dd1b3 (patch)
tree4021adb218b0718f196a24cab702200136ba1109 /win
parent68213cd3e77f669da034da3c266c7ae085126eb9 (diff)
Update from burlex, thanks
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@7057 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'win')
-rw-r--r--win/configure.cpp32
1 files changed, 16 insertions, 16 deletions
diff --git a/win/configure.cpp b/win/configure.cpp
index 91ffe76f2..890872fdd 100644
--- a/win/configure.cpp
+++ b/win/configure.cpp
@@ -3,6 +3,7 @@
#include <windows.h>
#include <stdio.h>
#include <string>
+#include <time.h>
#include "colours.h"
using namespace std;
@@ -17,10 +18,7 @@ bool iswinxp()
OSVERSIONINFO vi;
vi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
GetVersionEx(&vi);
- if(vi.dwMajorVersion > 5)
- return true;
-
- if(vi.dwMajorVersion >= 5 && vi.dwMinorVersion >= 1)
+ if(vi.dwMajorVersion >= 5)
return true;
return false;
@@ -218,7 +216,7 @@ void Run()
// detect windows
if(iswinxp())
{
- printf_c("You are running Windows XP or above, and IOCP support is most likely available.\n"
+ printf_c("You are running Windows 2000 or above, and IOCP support is most likely available.\n"
"This removes the socket number limitation of select and is much more efficent.\n"
"If you are unsure, answer yes.\n\n");
@@ -376,9 +374,9 @@ void WriteCompileCommands()
FILE * f = fopen("..\\src\\commands-release.mak", "w");
#endif
- fprintf(f, "# Generated at SOMETIME\n");
- fprintf(f, "!include <win32.mak>\n\n");
- fprintf(f, "all: ");
+ time_t t = time(NULL);
+ fprintf(f, "# Generated at %s\n", ctime(&t));
+ fprintf(f, "all: makedir ");
// dump modules.. first time :)
for(int i = 0; i < command_count; ++i)
@@ -386,11 +384,12 @@ void WriteCompileCommands()
fprintf(f, "\n.cpp.obj:\n");
#ifdef _DEBUG
- fprintf(f, " $(cc) /nologo /LD /Od /I \".\" /I \"../include\" /I \"../include/modes\" /I \"../include/commands\" /I \"../win\" /D \"WIN32\" /D \"_DEBUG\" /D \"_CONSOLE\" /D \"_MBCS\" /D \"DLL_BUILD\" /Gm /EHsc /GS /RTC1 /MTd /Fo\"Debug/\" /Fd\"Debug/vc70.pdb\" /W3 /Wp64 /Zi /TP $*.cpp ..\\win\\inspircd_memory_functions.cpp /link ..\\bin\\debug\\bin\\inspircd.lib /OUT:\"$*.so\"\n\n");
+ fprintf(f, " cl /nologo /LD /Od /I \".\" /I \"../include\" /I \"../include/modes\" /I \"../include/commands\" /I \"../win\" /D \"WIN32\" /D \"_DEBUG\" /D \"_CONSOLE\" /D \"_MBCS\" /D \"DLL_BUILD\" /Gm /EHsc /GS /RTC1 /MTd /Fo\"Debug/\" /Fd\"Debug/vc70.pdb\" /W3 /Wp64 /Zi /TP $*.cpp ..\\win\\inspircd_memory_functions.cpp /link ..\\bin\\debug\\bin\\inspircd.lib /OUT:\"..\\bin\\debug\\lib\\$*.so\" /PDB:\"..\\bin\\debug\\lib\\$*.pdb\" /IMPLIB:\"..\\bin\\debug\\lib\\$*.lib\"\n\n");
#else
- fprintf(f, " $(cc) /nologo /LD /Od /I \".\" /I \"../include\" /I \"../include/modes\" /I \"../include/commands\" /I \"../win\" /D \"WIN32\" /D \"_CONSOLE\" /D \"_MBCS\" /D \"DLL_BUILD\" /EHsc /GS /MT /Fo\"Release/\" /Fd\"Release/vc70.pdb\" /W3 /Wp64 /Zi /TP $*.cpp ..\\win\\inspircd_memory_functions.cpp /link ..\\bin\\release\\bin\\inspircd.lib /OUT:\"$*.so\"\n\n");
+ fprintf(f, " cl /nologo /LD /Od /I \".\" /I \"../include\" /I \"../include/modes\" /I \"../include/commands\" /I \"../win\" /D \"WIN32\" /D \"_CONSOLE\" /D \"_MBCS\" /D \"DLL_BUILD\" /EHsc /GS /MT /Fo\"Release/\" /Fd\"Release/vc70.pdb\" /W3 /Wp64 /Zi /TP $*.cpp ..\\win\\inspircd_memory_functions.cpp /link ..\\bin\\release\\bin\\inspircd.lib /OUT:\"..\\bin\\release\\lib\\$*.so\" /PDB:\"..\\bin\\release\\lib\\$*.pdb\" /IMPLIB:\"..\\bin\\release\\lib\\$*.lib\"\n\n");
#endif
+ fprintf(f, "makedir:\n if not exist debug mkdir debug\n\n");
// dump modules.. again the second and last time :)
for(int i = 0; i < command_count; ++i)
@@ -431,9 +430,9 @@ void WriteCompileModules()
FILE * f = fopen("..\\src\\modules\\modules-release.mak", "w");
#endif
- fprintf(f, "# Generated at SOMETIME\n");
- fprintf(f, "!include <win32.mak>\n\n");
- fprintf(f, "all: ");
+ time_t t = time(NULL);
+ fprintf(f, "# Generated at %s\n", ctime(&t));
+ fprintf(f, "all: makedir ");
// dump modules.. first time :)
for(int i = 0; i < module_count; ++i)
@@ -441,11 +440,12 @@ void WriteCompileModules()
fprintf(f, "\n.cpp.obj:\n");
#ifdef _DEBUG
- fprintf(f, " $(cc) /nologo /LD /Od /I \".\" /I \"../../include\" /I \"../../include/modes\" /I \"../../include/modules\" /I \"../../win\" /D \"WIN32\" /D \"_DEBUG\" /D \"_CONSOLE\" /D \"_MBCS\" /D \"DLL_BUILD\" /Gm /EHsc /GS /RTC1 /MTd /Fo\"Debug/\" /Fd\"Debug/vc70.pdb\" /W3 /Wp64 /Zi /TP $*.cpp ..\\..\\win\\inspircd_memory_functions.cpp /link ..\\..\\bin\\debug\\bin\\inspircd.lib ws2_32.lib /OUT:\"$*.so\"\n\n");
+ fprintf(f, " cl /nologo /LD /Od /I \".\" /I \"../../include\" /I \"../../include/modes\" /I \"../../include/modules\" /I \"../../win\" /D \"WIN32\" /D \"_DEBUG\" /D \"_CONSOLE\" /D \"_MBCS\" /D \"DLL_BUILD\" /Gm /EHsc /GS /RTC1 /MTd /Fo\"Debug/\" /Fd\"Debug/vc70.pdb\" /W3 /Wp64 /Zi /TP $*.cpp ..\\..\\win\\inspircd_memory_functions.cpp /link ..\\..\\bin\\debug\\bin\\inspircd.lib ws2_32.lib /OUT:\"..\\..\\bin\\debug\\modules\\$*.so\" /PDB:\"..\\..\\bin\\debug\\modules\\$*.pdb\" /IMPLIB:\"..\\..\\bin\\debug\\modules\\$*.lib\"\n\n");
#else
- fprintf(f, " $(cc) /nologo /LD /Od /I \".\" /I \"../../include\" /I \"../../include/modes\" /I \"../../include/modules\" /I \"../../win\" /D \"WIN32\" /D \"_CONSOLE\" /D \"_MBCS\" /D \"DLL_BUILD\" /EHsc /GS /MT /Fo\"Release/\" /Fd\"Release/vc70.pdb\" /W3 /Wp64 /Zi /TP $*.cpp ..\\..\\win\\inspircd_memory_functions.cpp /link ..\\..\\bin\\release\\bin\\inspircd.lib ws2_32.lib /OUT:\"$*.so\"\n\n");
+ fprintf(f, " cl /nologo /LD /Od /I \".\" /I \"../../include\" /I \"../../include/modes\" /I \"../../include/modules\" /I \"../../win\" /D \"WIN32\" /D \"_CONSOLE\" /D \"_MBCS\" /D \"DLL_BUILD\" /EHsc /GS /MT /Fo\"Release/\" /Fd\"Release/vc70.pdb\" /W3 /Wp64 /Zi /TP $*.cpp ..\\..\\win\\inspircd_memory_functions.cpp /link ..\\..\\bin\\release\\bin\\inspircd.lib ws2_32.lib /OUT:\"..\\..\\bin\\release\\modules\\$*.so\" /PDB:\"..\\..\\bin\\release\\modules\\$*.pdb\" /IMPLIB:\"..\\..\\bin\\release\\modules\\$*.lib\"\n\n");
#endif
-
+
+ fprintf(f, "makedir:\n if not exist debug mkdir debug\n\n");
// dump modules.. again the second and last time :)
for(int i = 0; i < module_count; ++i)