summaryrefslogtreecommitdiff
path: root/stdafx.h
diff options
context:
space:
mode:
authorDarkvater <darkvater@openttd.org>2005-10-02 22:39:56 +0000
committerDarkvater <darkvater@openttd.org>2005-10-02 22:39:56 +0000
commita3d40a29fc10e67c4a1b7cbd7fd519da030167af (patch)
tree5bcc6532a22928d167bf464a1c93f8aafbefa0f6 /stdafx.h
parente8fac6c6cb2a19a15b57c9629b0f69de37acecd2 (diff)
downloadopenttd-a3d40a29fc10e67c4a1b7cbd7fd519da030167af.tar.xz
(svn r3008) [ 1247535 ] Native Support for Win64 (compile&run only) (michi_cc)
Fix warning in graph_gui.c with const problem
Diffstat (limited to 'stdafx.h')
-rw-r--r--stdafx.h13
1 files changed, 12 insertions, 1 deletions
diff --git a/stdafx.h b/stdafx.h
index bc2b4c243..1a5498188 100644
--- a/stdafx.h
+++ b/stdafx.h
@@ -121,14 +121,25 @@
# define NOT_REACHED() _assume(0)
# endif
int CDECL snprintf(char *str, size_t size, const char *format, ...);
+#if _MSC_VER < 1400
int CDECL vsnprintf(char *str, size_t size, const char *format, va_list ap);
+#endif
# undef TTD_ALIGNMENT_4
# undef TTD_ALIGNMENT_2
# define GCC_PACK
#endif
+// Needed for old PlatformSDK versions (e.g. VC6)
+#if defined(WIN32) && !defined(_WIN64) && !defined(WIN64)
+# ifndef _W64
+# define _W64
+# endif
+typedef _W64 int INT_PTR, *PINT_PTR;
+typedef _W64 unsigned int UINT_PTR, *PUINT_PTR;
+#endif
+
// Windows has always LITTLE_ENDIAN
-#if defined(WIN32) || defined(__OS2__)
+#if defined(WIN32) || defined(__OS2__) || defined(WIN64)
#define TTD_LITTLE_ENDIAN
#else
// Else include endian[target/host].h, which has the endian-type, autodetected by the Makefile