Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Server Code Submissions

Reply
 
Thread Tools Display Modes
  #1  
Old 10-01-2008, 08:47 AM
erde
Sarnak
 
Join Date: Sep 2006
Location: Germany
Posts: 82
Default VS2008 Compile Fix

A little compile fix for VS2008

Quote:
Index: common/debug.cpp
================================================== =================
--- common/debug.cpp (Revision 27)
+++ common/debug.cpp (Arbeitskopie)
@@ -8,7 +8,15 @@
#include <process.h>

#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#else
Index: common/EMuShareMem.cpp
================================================== =================
--- common/EMuShareMem.cpp (Revision 27)
+++ common/EMuShareMem.cpp (Arbeitskopie)
@@ -23,7 +23,13 @@

#ifdef WIN32
#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp

Index: common/MiscFunctions.cpp
================================================== =================
--- common/MiscFunctions.cpp (Revision 27)
+++ common/MiscFunctions.cpp (Arbeitskopie)
@@ -38,7 +38,13 @@
#include <windows.h>

#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#else
Index: common/packet_dump_file.cpp
================================================== =================
--- common/packet_dump_file.cpp (Revision 27)
+++ common/packet_dump_file.cpp (Arbeitskopie)
@@ -29,7 +29,11 @@

#ifdef WIN32
#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#else
Index: common/SharedLibrary.cpp
================================================== =================
--- common/SharedLibrary.cpp (Revision 27)
+++ common/SharedLibrary.cpp (Arbeitskopie)
@@ -20,7 +20,13 @@

#ifdef WIN32
#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp

Index: common/TCPConnection.h
================================================== =================
--- common/TCPConnection.h (Revision 27)
+++ common/TCPConnection.h (Arbeitskopie)
@@ -24,7 +24,11 @@

#ifdef WIN32
#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp

Index: common/types.h
================================================== =================
--- common/types.h (Revision 27)
+++ common/types.h (Arbeitskopie)
@@ -61,7 +61,11 @@

#ifdef WIN32
#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
typedef void ThreadReturnType;
Index: world/client.cpp
================================================== =================
--- world/client.cpp (Revision 27)
+++ world/client.cpp (Arbeitskopie)
@@ -18,7 +18,9 @@
#include <windows.h>
#include <winsock.h>
#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#else
Index: world/console.cpp
================================================== =================
--- world/console.cpp (Revision 27)
+++ world/console.cpp (Arbeitskopie)
@@ -44,7 +44,9 @@

#ifdef WIN32
#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#endif
Index: world/LoginServer.cpp
================================================== =================
--- world/LoginServer.cpp (Revision 27)
+++ world/LoginServer.cpp (Arbeitskopie)
@@ -31,7 +31,9 @@
#include <winsock.h>

#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#else // Pyro: fix for linux
Index: world/net.cpp
================================================== =================
--- world/net.cpp (Revision 27)
+++ world/net.cpp (Arbeitskopie)
@@ -46,7 +46,9 @@
#ifdef WIN32
#include <process.h>
#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#include <conio.h>
Index: zone/beacon.cpp
================================================== =================
--- zone/beacon.cpp (Revision 27)
+++ zone/beacon.cpp (Arbeitskopie)
@@ -26,7 +26,9 @@
#include "../common/debug.h"
#ifdef WIN32
#define snprintf _snprintf
-#define vsnprintf _vsnprintf
+#if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#endif
Index: zone/client.cpp
================================================== =================
--- zone/client.cpp (Revision 27)
+++ zone/client.cpp (Arbeitskopie)
@@ -29,7 +29,9 @@
// Disgrace: for windows compile
#ifdef WIN32
#define snprintf _snprintf
-#define vsnprintf _vsnprintf
+#if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#else
Index: zone/client_packet.cpp
================================================== =================
--- zone/client_packet.cpp (Revision 27)
+++ zone/client_packet.cpp (Arbeitskopie)
@@ -30,7 +30,9 @@

#ifdef WIN32
#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#else
Index: zone/client_process.cpp
================================================== =================
--- zone/client_process.cpp (Revision 27)
+++ zone/client_process.cpp (Arbeitskopie)
@@ -32,7 +32,9 @@
#include <windows.h>
#include <winsock.h>
#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#else
Index: zone/entity.cpp
================================================== =================
--- zone/entity.cpp (Revision 27)
+++ zone/entity.cpp (Arbeitskopie)
@@ -49,7 +49,9 @@

#ifdef WIN32
#define snprintf _snprintf
-#define vsnprintf _vsnprintf
+#if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#endif
Index: zone/net.cpp
================================================== =================
--- zone/net.cpp (Revision 27)
+++ zone/net.cpp (Arbeitskopie)
@@ -36,7 +36,9 @@
#ifdef WIN32
#include <conio.h>
#define snprintf _snprintf
-#define vsnprintf _vsnprintf
+#if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#endif
Index: zone/petitions.cpp
================================================== =================
--- zone/petitions.cpp (Revision 27)
+++ zone/petitions.cpp (Arbeitskopie)
@@ -29,7 +29,9 @@

#ifdef WIN32
#define snprintf _snprintf
-#define vsnprintf _vsnprintf
+#if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#endif
Index: zone/PlayerCorpse.cpp
================================================== =================
--- zone/PlayerCorpse.cpp (Revision 27)
+++ zone/PlayerCorpse.cpp (Arbeitskopie)
@@ -28,7 +28,9 @@
using namespace std;
#ifdef WIN32
#define snprintf _snprintf
-#define vsnprintf _vsnprintf
+#if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#endif
Index: zone/tribute.cpp
================================================== =================
--- zone/tribute.cpp (Revision 27)
+++ zone/tribute.cpp (Arbeitskopie)
@@ -32,7 +32,9 @@
#include <process.h>

#define snprintf _snprintf
-#define vsnprintf _vsnprintf
+#if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#else
Index: zone/worldserver.cpp
================================================== =================
--- zone/worldserver.cpp (Revision 27)
+++ zone/worldserver.cpp (Arbeitskopie)
@@ -30,7 +30,9 @@
#include <process.h>

#define snprintf _snprintf
- #define vsnprintf _vsnprintf
+ #if (_MSC_VER < 1500)
+ #define vsnprintf _vsnprintf
+ #endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#endif
__________________
"Yes, the artwork is awful. I am an engineer, not an artist " - David H. Eberly
Reply With Quote
  #2  
Old 10-01-2008, 09:47 AM
Derision
Developer
 
Join Date: Feb 2004
Location: UK
Posts: 1,540
Default

Thanks.

I'm happy to commit this to SVN later on today. Whenever I do a test compile on Windows (I only have VS 2008 Express on Windows), I just do a global remove of all the #define vsnprintf, but this is obviously the best way to do things.

I can do a test compile on VS 2008 and Linux, but I'll need somebody else to check-it out and confirm it compiles OK on previous versions of Visual C++ (not that it shouldn't).

I'll post back later once it's comitted.
Reply With Quote
  #3  
Old 10-01-2008, 09:58 AM
cavedude's Avatar
cavedude
The PEQ Dude
 
Join Date: Apr 2003
Location: -
Posts: 1,988
Default

I'll test it out on VS 2005.
Reply With Quote
  #4  
Old 10-01-2008, 10:20 AM
erde
Sarnak
 
Join Date: Sep 2006
Location: Germany
Posts: 82
Default

I am on VS2008 and Linux AMD x64

I ll try to help as much as i can
__________________
"Yes, the artwork is awful. I am an engineer, not an artist " - David H. Eberly
Reply With Quote
  #5  
Old 10-01-2008, 01:48 PM
Derision
Developer
 
Join Date: Feb 2004
Location: UK
Posts: 1,540
Default

Committed in Revision 28.
Reply With Quote
  #6  
Old 10-01-2008, 06:49 PM
cavedude's Avatar
cavedude
The PEQ Dude
 
Join Date: Apr 2003
Location: -
Posts: 1,988
Default

Compiles with VS 2005 and Linux 32bit just fine.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 12:34 PM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3