vrshoot
view libs/ogg/os_types.h @ 1:e7ca128b8713
looks nice :)
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Sun, 02 Feb 2014 00:35:22 +0200 |
parents | |
children |
line source
1 /********************************************************************
2 * *
3 * THIS FILE IS PART OF THE OggVorbis SOFTWARE CODEC SOURCE CODE. *
4 * USE, DISTRIBUTION AND REPRODUCTION OF THIS LIBRARY SOURCE IS *
5 * GOVERNED BY A BSD-STYLE SOURCE LICENSE INCLUDED WITH THIS SOURCE *
6 * IN 'COPYING'. PLEASE READ THESE TERMS BEFORE DISTRIBUTING. *
7 * *
8 * THE OggVorbis SOURCE CODE IS (C) COPYRIGHT 1994-2002 *
9 * by the Xiph.Org Foundation http://www.xiph.org/ *
10 * *
11 ********************************************************************
13 function: #ifdef jail to whip a few platforms into the UNIX ideal.
14 last mod: $Id: os_types.h 17712 2010-12-03 17:10:02Z xiphmont $
16 ********************************************************************/
17 #ifndef _OS_TYPES_H
18 #define _OS_TYPES_H
20 /* make it easy on the folks that want to compile the libs with a
21 different malloc than stdlib */
22 #define _ogg_malloc malloc
23 #define _ogg_calloc calloc
24 #define _ogg_realloc realloc
25 #define _ogg_free free
27 #if defined(_WIN32)
29 # if defined(__CYGWIN__)
30 # include <stdint.h>
31 typedef int16_t ogg_int16_t;
32 typedef uint16_t ogg_uint16_t;
33 typedef int32_t ogg_int32_t;
34 typedef uint32_t ogg_uint32_t;
35 typedef int64_t ogg_int64_t;
36 typedef uint64_t ogg_uint64_t;
37 # elif defined(__MINGW32__)
38 # include <sys/types.h>
39 typedef short ogg_int16_t;
40 typedef unsigned short ogg_uint16_t;
41 typedef int ogg_int32_t;
42 typedef unsigned int ogg_uint32_t;
43 typedef long long ogg_int64_t;
44 typedef unsigned long long ogg_uint64_t;
45 # elif defined(__MWERKS__)
46 typedef long long ogg_int64_t;
47 typedef int ogg_int32_t;
48 typedef unsigned int ogg_uint32_t;
49 typedef short ogg_int16_t;
50 typedef unsigned short ogg_uint16_t;
51 # else
52 /* MSVC/Borland */
53 typedef __int64 ogg_int64_t;
54 typedef __int32 ogg_int32_t;
55 typedef unsigned __int32 ogg_uint32_t;
56 typedef __int16 ogg_int16_t;
57 typedef unsigned __int16 ogg_uint16_t;
58 # endif
60 #elif defined(__MACOS__)
62 # include <sys/types.h>
63 typedef SInt16 ogg_int16_t;
64 typedef UInt16 ogg_uint16_t;
65 typedef SInt32 ogg_int32_t;
66 typedef UInt32 ogg_uint32_t;
67 typedef SInt64 ogg_int64_t;
69 #elif (defined(__APPLE__) && defined(__MACH__)) /* MacOS X Framework build */
71 # include <inttypes.h>
72 typedef int16_t ogg_int16_t;
73 typedef uint16_t ogg_uint16_t;
74 typedef int32_t ogg_int32_t;
75 typedef uint32_t ogg_uint32_t;
76 typedef int64_t ogg_int64_t;
78 #elif defined(__HAIKU__)
80 /* Haiku */
81 # include <sys/types.h>
82 typedef short ogg_int16_t;
83 typedef unsigned short ogg_uint16_t;
84 typedef int ogg_int32_t;
85 typedef unsigned int ogg_uint32_t;
86 typedef long long ogg_int64_t;
88 #elif defined(__BEOS__)
90 /* Be */
91 # include <inttypes.h>
92 typedef int16_t ogg_int16_t;
93 typedef uint16_t ogg_uint16_t;
94 typedef int32_t ogg_int32_t;
95 typedef uint32_t ogg_uint32_t;
96 typedef int64_t ogg_int64_t;
98 #elif defined (__EMX__)
100 /* OS/2 GCC */
101 typedef short ogg_int16_t;
102 typedef unsigned short ogg_uint16_t;
103 typedef int ogg_int32_t;
104 typedef unsigned int ogg_uint32_t;
105 typedef long long ogg_int64_t;
107 #elif defined (DJGPP)
109 /* DJGPP */
110 typedef short ogg_int16_t;
111 typedef int ogg_int32_t;
112 typedef unsigned int ogg_uint32_t;
113 typedef long long ogg_int64_t;
115 #elif defined(R5900)
117 /* PS2 EE */
118 typedef long ogg_int64_t;
119 typedef int ogg_int32_t;
120 typedef unsigned ogg_uint32_t;
121 typedef short ogg_int16_t;
123 #elif defined(__SYMBIAN32__)
125 /* Symbian GCC */
126 typedef signed short ogg_int16_t;
127 typedef unsigned short ogg_uint16_t;
128 typedef signed int ogg_int32_t;
129 typedef unsigned int ogg_uint32_t;
130 typedef long long int ogg_int64_t;
132 #elif defined(__TMS320C6X__)
134 /* TI C64x compiler */
135 typedef signed short ogg_int16_t;
136 typedef unsigned short ogg_uint16_t;
137 typedef signed int ogg_int32_t;
138 typedef unsigned int ogg_uint32_t;
139 typedef long long int ogg_int64_t;
141 #else
143 # include <ogg/config_types.h>
145 #endif
147 #endif /* _OS_TYPES_H */