From: Tim-Philipp Müller Date: Thu, 10 Jan 2013 00:31:25 +0000 (+0000) Subject: bluez: use GLib defines to check for byte order X-Git-Tag: 1.19.3~507^2~14174 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e89c130f1efe7287b8fa16dd647c7524069d8868;p=platform%2Fupstream%2Fgstreamer.git bluez: use GLib defines to check for byte order --- diff --git a/sys/bluez/a2dp-codecs.h b/sys/bluez/a2dp-codecs.h index 3dc31cb..b836872 100644 --- a/sys/bluez/a2dp-codecs.h +++ b/sys/bluez/a2dp-codecs.h @@ -22,6 +22,11 @@ * */ +#ifndef __GST_BLUEZ_A2DP_CODECS_H_INCLUDED__ +#define __GST_BLUEZ_A2DP_CODECS_H_INCLUDED__ + +#include + #define A2DP_CODEC_SBC 0x00 #define A2DP_CODEC_MPEG12 0x01 #define A2DP_CODEC_MPEG24 0x02 @@ -85,7 +90,7 @@ #define MPEG_BIT_RATE_32000 0x0002 #define MPEG_BIT_RATE_FREE 0x0001 -#if __BYTE_ORDER == __LITTLE_ENDIAN +#if G_BYTE_ORDER == G_LITTLE_ENDIAN typedef struct { uint8_t channel_mode:4; @@ -107,7 +112,7 @@ typedef struct { uint16_t bitrate; } __attribute__ ((packed)) a2dp_mpeg_t; -#elif __BYTE_ORDER == __BIG_ENDIAN +#elif G_BYTE_ORDER == G_BIG_ENDIAN typedef struct { uint8_t frequency:4; @@ -137,3 +142,5 @@ typedef struct { uint8_t vendor_id[4]; uint8_t codec_id[2]; } __attribute__ ((packed)) a2dp_vendor_codec_t; + +#endif /* #define __GST_BLUEZ_A2DP_CODECS_H_INCLUDED__ */