ps2sdk  1.1
A collection of Open Source libraries used for developing applications on Sony's PlayStation 2® (PS2).
cc.h
Go to the documentation of this file.
1 #ifndef __CC_H__
2 #define __CC_H__
3 
4 #include <errno.h>
5 #include <stddef.h>
6 
7 typedef unsigned char u8_t;
8 typedef signed char s8_t;
9 typedef unsigned short int u16_t;
10 typedef signed short int s16_t;
11 typedef unsigned int u32_t;
12 typedef signed int s32_t;
13 
14 typedef u32_t mem_ptr_t;
15 
16 #define PACK_STRUCT_FIELD(x) x __attribute((packed))
17 #define PACK_STRUCT_STRUCT __attribute((packed))
18 /* Used for struct fields of u8_t,
19  * where some compilers warn that packing is not necessary */
20 #define PACK_STRUCT_FLD_8(x) x
21 /* Used for struct fields of that are packed structs themself,
22  * where some compilers warn that packing is not necessary */
23 #define PACK_STRUCT_FLD_S(x) x
24 #define PACK_STRUCT_BEGIN
25 #define PACK_STRUCT_END
26 
27 #ifdef DEBUG
28 #define LWIP_PLATFORM_DIAG(args) printf args
29 #define LWIP_PLATFORM_ASSERT(args) printf args
30 #else
31 #define LWIP_PLATFORM_DIAG(args)
32 #define LWIP_PLATFORM_ASSERT(args)
33 #endif
34 
35 /* Define (sn)printf formatters for these lwIP types */
36 #define U8_F "hu"
37 #define S8_F "hd"
38 #define X8_F "hx"
39 #define U16_F "hu"
40 #define S16_F "hd"
41 #define X16_F "hx"
42 #define U32_F "u"
43 #define S32_F "d"
44 #define X32_F "x"
45 #define SZT_F "uz"
46 
47 #define LWIP_NO_STDINT_H 1 //stdint.h does not exist.
48 #define LWIP_NO_INTTYPES_H 1 //inttypes.h does not exist.
49 
50 #define lwip_htons(x) PP_HTONS(x)
51 #define lwip_htonl(x) PP_HTONL(x)
52 
53 #endif /* __CC_H__ */
unsigned int u32_t
Definition: cc.h:11
signed short int s16_t
Definition: cc.h:10
u32_t mem_ptr_t
Definition: cc.h:14
signed char s8_t
Definition: cc.h:8
unsigned char u8_t
Definition: cc.h:7
signed int s32_t
Definition: cc.h:12
unsigned short int u16_t
Definition: cc.h:9