aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/platform.h32
1 files changed, 16 insertions, 16 deletions
diff --git a/include/platform.h b/include/platform.h
index 699de8f02..ea2983d30 100644
--- a/include/platform.h
+++ b/include/platform.h
@@ -44,28 +44,28 @@
44#endif 44#endif
45 45
46#ifndef ATTRIBUTE_UNUSED 46#ifndef ATTRIBUTE_UNUSED
47#define ATTRIBUTE_UNUSED __attribute__ ((__unused__)) 47# define ATTRIBUTE_UNUSED __attribute__ ((__unused__))
48#endif /* ATTRIBUTE_UNUSED */ 48#endif /* ATTRIBUTE_UNUSED */
49 49
50#ifndef ATTRIBUTE_NORETURN 50#ifndef ATTRIBUTE_NORETURN
51#define ATTRIBUTE_NORETURN __attribute__ ((__noreturn__)) 51# define ATTRIBUTE_NORETURN __attribute__ ((__noreturn__))
52#endif /* ATTRIBUTE_NORETURN */ 52#endif /* ATTRIBUTE_NORETURN */
53 53
54#ifndef ATTRIBUTE_PACKED 54#ifndef ATTRIBUTE_PACKED
55#define ATTRIBUTE_PACKED __attribute__ ((__packed__)) 55# define ATTRIBUTE_PACKED __attribute__ ((__packed__))
56#endif /* ATTRIBUTE_PACKED */ 56#endif /* ATTRIBUTE_PACKED */
57 57
58#ifndef ATTRIBUTE_ALIGNED 58#ifndef ATTRIBUTE_ALIGNED
59#define ATTRIBUTE_ALIGNED(m) __attribute__ ((__aligned__(m))) 59# define ATTRIBUTE_ALIGNED(m) __attribute__ ((__aligned__(m)))
60#endif /* ATTRIBUTE_ALIGNED */ 60#endif /* ATTRIBUTE_ALIGNED */
61 61
62/* -fwhole-program makes all symbols local. The attribute externally_visible 62/* -fwhole-program makes all symbols local. The attribute externally_visible
63 forces a symbol global. */ 63 forces a symbol global. */
64#ifndef ATTRIBUTE_EXTERNALLY_VISIBLE 64#ifndef ATTRIBUTE_EXTERNALLY_VISIBLE
65# if __GNUC_PREREQ (4,1) 65# if __GNUC_PREREQ (4,1)
66# define ATTRIBUTE_EXTERNALLY_VISIBLE __attribute__ ((__externally_visible__)) 66# define ATTRIBUTE_EXTERNALLY_VISIBLE __attribute__ ((__externally_visible__))
67# else 67# else
68# define ATTRIBUTE_EXTERNALLY_VISIBLE 68# define ATTRIBUTE_EXTERNALLY_VISIBLE
69# endif /* GNUC >= 4.1 */ 69# endif /* GNUC >= 4.1 */
70#endif /* ATTRIBUTE_EXTERNALLY_VISIBLE */ 70#endif /* ATTRIBUTE_EXTERNALLY_VISIBLE */
71 71
@@ -80,26 +80,26 @@
80 80
81/* ---- Endian Detection ------------------------------------ */ 81/* ---- Endian Detection ------------------------------------ */
82#ifndef __APPLE__ 82#ifndef __APPLE__
83 #include <byteswap.h> 83# include <byteswap.h>
84 #include <endian.h> 84# include <endian.h>
85#endif 85#endif
86 86
87#ifdef __BIG_ENDIAN__ 87#ifdef __BIG_ENDIAN__
88 #define BB_BIG_ENDIAN 1 88# define BB_BIG_ENDIAN 1
89 #define BB_LITTLE_ENDIAN 0 89# define BB_LITTLE_ENDIAN 0
90#elif __BYTE_ORDER == __BIG_ENDIAN 90#elif __BYTE_ORDER == __BIG_ENDIAN
91 #define BB_BIG_ENDIAN 1 91# define BB_BIG_ENDIAN 1
92 #define BB_LITTLE_ENDIAN 0 92# define BB_LITTLE_ENDIAN 0
93#else 93#else
94 #define BB_BIG_ENDIAN 0 94# define BB_BIG_ENDIAN 0
95 #define BB_LITTLE_ENDIAN 1 95# define BB_LITTLE_ENDIAN 1
96#endif 96#endif
97 97
98/* ---- Networking ------------------------------------------ */ 98/* ---- Networking ------------------------------------------ */
99#ifndef __APPLE__ 99#ifndef __APPLE__
100#include <arpa/inet.h> 100# include <arpa/inet.h>
101#else 101#else
102#include <netinet/in.h> 102# include <netinet/in.h>
103#endif 103#endif
104 104
105/* ---- miscellaneous --------------------------------------- */ 105/* ---- miscellaneous --------------------------------------- */