Backed out 2 changesets (bug 1881078, bug 1879806) for causing dt failures @ devtools...
[gecko.git] / gfx / qcms / qcmstypes.h
blob7f6c70f12c9772fd5184a5e2ccd8757c7ee14997
1 #ifndef QCMS_TYPES_H
2 #define QCMS_TYPES_H
4 #ifdef __cplusplus
5 extern "C" {
6 #endif
8 #if !defined(IS_LITTLE_ENDIAN) && !defined(IS_BIG_ENDIAN)
9 #if BYTE_ORDER == LITTLE_ENDIAN
10 #define IS_LITTLE_ENDIAN
11 #elif BYTE_ORDER == BIG_ENDIAN
12 #define IS_BIG_ENDIAN
13 #endif
15 /* all of the platforms that we use _MSC_VER on are little endian
16 * so this is sufficient for now */
17 #ifdef _MSC_VER
18 #define IS_LITTLE_ENDIAN
19 #endif
21 #ifdef __OS2__
22 #define IS_LITTLE_ENDIAN
23 #endif
24 #endif
26 #if !defined(IS_LITTLE_ENDIAN) && !defined(IS_BIG_ENDIAN)
27 #error Unknown endianess
28 #endif
30 #if defined (_SVR4) || defined (SVR4) || defined (__OpenBSD__) || defined (_sgi) || defined (__sun) || defined (sun) || defined (__digital__)
31 # include <inttypes.h>
32 #elif defined (_MSC_VER) && _MSC_VER < 1600
33 typedef __int8 int8_t;
34 typedef unsigned __int8 uint8_t;
35 typedef __int16 int16_t;
36 typedef unsigned __int16 uint16_t;
37 typedef __int32 int32_t;
38 typedef unsigned __int32 uint32_t;
39 typedef __int64 int64_t;
40 typedef unsigned __int64 uint64_t;
41 #ifdef _WIN64
42 typedef unsigned __int64 uintptr_t;
43 #else
44 typedef unsigned long uintptr_t;
45 #endif
47 #elif defined (_AIX)
48 # include <sys/inttypes.h>
49 #else
50 # include <stdint.h>
51 #endif
53 #include <stdbool.h>
55 #ifdef __cplusplus
57 #endif
59 #endif