summaryrefslogtreecommitdiff
path: root/include/SDL_types.h
diff options
context:
space:
mode:
authorSam Lantinga <slouken@libsdl.org>2004-07-18 19:42:03 +0000
committerSam Lantinga <slouken@libsdl.org>2004-07-18 19:42:03 +0000
commitdcede8c8dba3d04917cc695993d377ac9cf7946e (patch)
tree1680923c3b9173b108fb7e641a934cba1f4a85a9 /include/SDL_types.h
parentafe2d5df2b3dfcef4e3e0a313b786e7cb374dc7b (diff)
downloadsdl-dcede8c8dba3d04917cc695993d377ac9cf7946e.tar.gz
Date: Mon, 28 Jun 2004 19:58:08 +0900
From: Hayashi Naoyuki Subject: SDL_types.h - fix for Tru64 MME The following two problems are fixed. 1. Type of Uint64 is "long long" in SDL_types.h, but is "long" in mmbasic.h(Tru64 UNIX MME header file). 2. Uint8, Uint16 and Uint32 are redefined if you compile a file including mmbasic.h and SDL_types.h.
Diffstat (limited to 'include/SDL_types.h')
-rw-r--r--include/SDL_types.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/include/SDL_types.h b/include/SDL_types.h
index 6e89e6c61..8fbfc1ddd 100644
--- a/include/SDL_types.h
+++ b/include/SDL_types.h
@@ -38,16 +38,26 @@ typedef enum {
SDL_FALSE = 0,
SDL_TRUE = 1
} SDL_bool;
+
+#ifdef H_MMBASIC /* mmbasic.h (Tru64 MME) */
+/* Some of the basic types are already defined in mmbasic.h */
+typedef signed char Sint8;
+typedef signed short Sint16;
+typedef signed int Sint32;
+#else
typedef unsigned char Uint8;
typedef signed char Sint8;
typedef unsigned short Uint16;
typedef signed short Sint16;
typedef unsigned int Uint32;
typedef signed int Sint32;
+#endif
/* Figure out how to support 64-bit datatypes */
#if !defined(__STRICT_ANSI__)
-#if defined(__GNUC__) || defined(__MWERKS__) || defined(__SUNPRO_C) || defined(__DECC)
+#ifdef H_MMBASIC /* mmbasic.h (Tru64 MME) */
+#define SDL_HAS_64BIT_TYPE long
+#elif defined(__GNUC__) || defined(__MWERKS__) || defined(__SUNPRO_C) || defined(__DECC)
#define SDL_HAS_64BIT_TYPE long long
#elif defined(_MSC_VER) /* VC++ */
#define SDL_HAS_64BIT_TYPE __int64