summaryrefslogtreecommitdiff
path: root/apps/plugins/doom/doomtype.h
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2010-05-29 08:12:39 +0000
committerMichael Sevakis <jethead71@rockbox.org>2010-05-29 08:12:39 +0000
commit9c6e217f29bb0a76ec153574a3d493b020e5fb60 (patch)
treeb38acde6c091b7f8b0e3205645f9d232f19eeabb /apps/plugins/doom/doomtype.h
parent6980c1e9988a7c959876ad77b760e042272a9ec2 (diff)
downloadrockbox-9c6e217f29bb0a76ec153574a3d493b020e5fb60.tar.gz
rockbox-9c6e217f29bb0a76ec153574a3d493b020e5fb60.zip
Doom plugin: In anticipation of moving to the EABI toolchain, because of its assumptions about enums being sized as ints, convert enum typdefs to int or unsigned depending upon whether they have negative values in the enumeration. This should effectively preserve the manner in which it is compiled under the old toolchain and avoids having to closely inspect and possibly change many places in the code.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26368 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/doom/doomtype.h')
-rw-r--r--apps/plugins/doom/doomtype.h16
1 files changed, 4 insertions, 12 deletions
diff --git a/apps/plugins/doom/doomtype.h b/apps/plugins/doom/doomtype.h
index 59b33758da..22e3ec6009 100644
--- a/apps/plugins/doom/doomtype.h
+++ b/apps/plugins/doom/doomtype.h
@@ -33,18 +33,9 @@
33#define __DOOMTYPE__ 33#define __DOOMTYPE__
34#include "rockmacros.h" 34#include "rockmacros.h"
35 35
36#ifndef __BYTEBOOL__
37#define __BYTEBOOL__
38// Fixed to use builtin bool type with C++. 36// Fixed to use builtin bool type with C++.
39#ifdef __cplusplus 37typedef unsigned int boolean;
40typedef bool boolean;
41#else
42//typedef enum {false, true} boolean;
43//#define boolean bool
44typedef enum _boolean { FALSE, TRUE } boolean;
45#endif
46typedef unsigned char byte; 38typedef unsigned char byte;
47#endif
48 39
49typedef signed long long int_64_t; 40typedef signed long long int_64_t;
50typedef unsigned long long uint_64_t; 41typedef unsigned long long uint_64_t;
@@ -63,7 +54,7 @@ typedef unsigned long long uint_64_t;
63#define MINLONG ((long)0x80000000) 54#define MINLONG ((long)0x80000000)
64 55
65/* cph - move compatibility levels here so we can use them in d_server.c */ 56/* cph - move compatibility levels here so we can use them in d_server.c */
66typedef enum { 57enum {
67 doom_12_compatibility, /* Behave like early doom versions */ 58 doom_12_compatibility, /* Behave like early doom versions */
68 doom_demo_compatibility, /* As compatible as possible for 59 doom_demo_compatibility, /* As compatible as possible for
69 * playing original Doom demos */ 60 * playing original Doom demos */
@@ -80,6 +71,7 @@ typedef enum {
80 /* Aliases follow */ 71 /* Aliases follow */
81 boom_compatibility = boom_201_compatibility, /* Alias used by G_Compatibility */ 72 boom_compatibility = boom_201_compatibility, /* Alias used by G_Compatibility */
82 best_compatibility = prboom_3_compatibility, 73 best_compatibility = prboom_3_compatibility,
83} complevel_t; 74};
75typedef unsigned complevel_t;
84 76
85#endif 77#endif