summaryrefslogtreecommitdiffstats
path: root/openbsc/src/libtrau
diff options
context:
space:
mode:
authorTobias Engel <t-openbsc@tobias.org>2012-10-24 17:53:50 +0200
committerHarald Welte <laforge@gnumonks.org>2012-10-27 10:09:21 +0200
commitaff20717e4a15599a30396f5a38aa42f0ce8d779 (patch)
treeba93ca7f3302d26a220d39281557ff72222f6536 /openbsc/src/libtrau
parent511f9c3e4a0a7ebb6294d6a2e4ac29dbcdad818c (diff)
Set byte order defines when compiled on OSX
Byte order defines have a DARWIN prefix on OSX so the values openbsc expects are set from their Darwin counterparts when compiled on OSX.
Diffstat (limited to 'openbsc/src/libtrau')
-rw-r--r--openbsc/src/libtrau/rtp_proxy.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/openbsc/src/libtrau/rtp_proxy.c b/openbsc/src/libtrau/rtp_proxy.c
index 3d34ac6..f7c5a4f 100644
--- a/openbsc/src/libtrau/rtp_proxy.c
+++ b/openbsc/src/libtrau/rtp_proxy.c
@@ -42,7 +42,13 @@
#include <limits.h>
#ifndef __BYTE_ORDER
-#error "__BYTE_ORDER should be defined by someone"
+# ifdef __APPLE__
+# define __BYTE_ORDER __DARWIN_BYTE_ORDER
+# define __LITTLE_ENDIAN __DARWIN_LITTLE_ENDIAN
+# define __BIG_ENDIAN __DARWIN_BIG_ENDIAN
+# else
+# error "__BYTE_ORDER should be defined by someone"
+# endif
#endif
static LLIST_HEAD(rtp_sockets);