Support using swapxx() and bswap_xx() for byteswaps in rbendian.h
- patch suggested by Massa in http://forums.rockbox.org/index.php/topic,51618.msg238760.html#msg238760 Change-Id: Iba93ff53119db00a18d944d52bc8b1c5fe593fc9
This commit is contained in:
parent
793c0411be
commit
ed6526404f
|
@ -79,10 +79,18 @@
|
|||
#define __swap16_os(x) __bswap_16(x)
|
||||
#define __swap32_os(x) __bswap_32(x)
|
||||
#define __swap64_os(x) __bswap_64(x)
|
||||
#elif defined (bswap_16)
|
||||
#define __swap16_os(x) bswap_16(x)
|
||||
#define __swap32_os(x) bswap_32(x)
|
||||
#define __swap64_os(x) bswap_64(x)
|
||||
#elif defined (__swap16)
|
||||
#define __swap16_os(x) __swap16(x)
|
||||
#define __swap32_os(x) __swap32(x)
|
||||
#define __swap64_os(x) __swap64(x)
|
||||
#elif defined (swap16)
|
||||
#define __swap16_os(x) swap16(x)
|
||||
#define __swap32_os(x) swap32(x)
|
||||
#define __swap64_os(x) swap64(x)
|
||||
#elif defined (__MINGW32__) || (CONFIG_PLATFORM & PLATFORM_MAEMO)
|
||||
/* kinda hacky but works */
|
||||
#define __swap16_os(x) SWAP16_CONST(x)
|
||||
|
|
Loading…
Reference in New Issue