diff include/SDL_stdinc.h @ 2735:204be4fc2726

Final merge of Google Summer of Code 2008 work... Port SDL 1.3 to the Nintendo DS by Darren Alton, mentored by Sam Lantinga
author Sam Lantinga <slouken@libsdl.org>
date Wed, 27 Aug 2008 15:10:03 +0000
parents 6259afb046c5
children 99210400e8b9
line wrap: on
line diff
--- a/include/SDL_stdinc.h	Wed Aug 27 13:37:19 2008 +0000
+++ b/include/SDL_stdinc.h	Wed Aug 27 15:10:03 2008 +0000
@@ -147,8 +147,12 @@
 SDL_COMPILE_TIME_ASSERT(sint16, sizeof(Sint16) == 2);
 SDL_COMPILE_TIME_ASSERT(uint32, sizeof(Uint32) == 4);
 SDL_COMPILE_TIME_ASSERT(sint32, sizeof(Sint32) == 4);
+#ifndef __NINTENDODS__          /* TODO: figure out why the following happens:
+                                   include/SDL_stdinc.h:150: error: size of array 'SDL_dummy_uint64' is negative
+                                   include/SDL_stdinc.h:151: error: size of array 'SDL_dummy_sint64' is negative */
 SDL_COMPILE_TIME_ASSERT(uint64, sizeof(Uint64) == 8);
 SDL_COMPILE_TIME_ASSERT(sint64, sizeof(Sint64) == 8);
+#endif
 #endif /* DOXYGEN_SHOULD_IGNORE_THIS */
 
 /* Check to make sure enums are the size of ints, for structure packing.
@@ -162,12 +166,14 @@
 #endif
 
 #ifndef DOXYGEN_SHOULD_IGNORE_THIS
+#ifndef __NINTENDODS__          /* TODO: include/SDL_stdinc.h:174: error: size of array 'SDL_dummy_enum' is negative */
 typedef enum
 {
     DUMMY_ENUM_VALUE
 } SDL_DUMMY_ENUM;
 
 SDL_COMPILE_TIME_ASSERT(enum, sizeof(SDL_DUMMY_ENUM) == sizeof(int));
+#endif
 #endif /* DOXYGEN_SHOULD_IGNORE_THIS */
 
 #include "begin_code.h"
@@ -425,6 +431,9 @@
 #ifdef HAVE_WCSLEN
 #define SDL_wcslen      wcslen
 #else
+#if !defined(wchar_t) && defined(__NINTENDODS__)
+#define wchar_t short           /* TODO: figure out why libnds doesn't have this */
+#endif
 extern DECLSPEC size_t SDLCALL SDL_wcslen(const wchar_t * string);
 #endif