1 | /* |
---|
2 | This is part of the OTF library. Copyright by ZIH, TU Dresden 2005-2008. |
---|
3 | Authors: Andreas Knuepfer, Holger Brunst, Ronny Brendel, Thomas Kriebitzsch |
---|
4 | */ |
---|
5 | |
---|
6 | /** |
---|
7 | * @file OTF_inttypes_unix.h |
---|
8 | * |
---|
9 | * @brief Deals with all data type related issues. |
---|
10 | * |
---|
11 | * \ingroup misc |
---|
12 | */ |
---|
13 | |
---|
14 | |
---|
15 | #ifndef OTF_INTTYPES_UNIX_H |
---|
16 | #define OTF_INTTYPES_UNIX_H |
---|
17 | |
---|
18 | #define OTF_HAVE_STDINT_H 1 |
---|
19 | #define OTF_HAVE_INTTYPES_H 1 |
---|
20 | #define OTF_SIZEOF_LONG 8 |
---|
21 | |
---|
22 | #ifdef __sgi |
---|
23 | # undef OTF_HAVE_STDINT_H |
---|
24 | # define OTF_HAVE_STDINT_H 0 |
---|
25 | #endif |
---|
26 | |
---|
27 | #if OTF_HAVE_STDINT_H |
---|
28 | # include <stdint.h> |
---|
29 | #elif OTF_HAVE_INTTYPES_H |
---|
30 | # include <inttypes.h> |
---|
31 | #else /* OTF_HAVE_STDINT_H || OTF_HAVE_INTTYPES_H */ |
---|
32 | |
---|
33 | typedef signed char int8_t; |
---|
34 | typedef signed short int int16_t; |
---|
35 | typedef signed int int32_t; |
---|
36 | # if OTF_SIZEOF_LONG == 8 |
---|
37 | typedef signed long int int64_t; |
---|
38 | # else /* OTF_SIZEOF_LONG */ |
---|
39 | typedef signed long long int int64_t; |
---|
40 | # endif /* OTF_SIZEOF_LONG */ |
---|
41 | |
---|
42 | typedef unsigned char uint8_t; |
---|
43 | typedef unsigned short int uint16_t; |
---|
44 | typedef unsigned int uint32_t; |
---|
45 | # if OTF_SIZEOF_LONG == 8 |
---|
46 | typedef unsigned long int uint64_t; |
---|
47 | # else /* OTF_SIZEOF_LONG */ |
---|
48 | typedef unsigned long long int uint64_t; |
---|
49 | # endif /* OTF_SIZEOF_LONG */ |
---|
50 | |
---|
51 | #endif /* OTF_HAVE_INTTYPES_H || OTF_HAVE_STDINT_H */ |
---|
52 | |
---|
53 | #endif /* OTF_INTTYPES_UNIX_H */ |
---|