浏览代码

workaround for androud compilation due to no activity, fixes #507

Stasik0 9 年之前
父节点
当前提交
8400be7771
共有 1 个文件被更改,包括 1 次插入2 次删除
  1. 1 2
      include/ua_config.h.in

+ 1 - 2
include/ua_config.h.in

@@ -46,8 +46,7 @@
 // UA_NON_LITTLEENDIAN_ARCHITECTURE disables memcpying integer arrays directly
 // UA_NON_LITTLEENDIAN_ARCHITECTURE disables memcpying integer arrays directly
 // onto the message buffer. UA_MIXED_ENDIAN enables special encoding for floats
 // onto the message buffer. UA_MIXED_ENDIAN enables special encoding for floats
 // and doubles. Otherwise, they are endianness-switched similar to integers.
 // and doubles. Otherwise, they are endianness-switched similar to integers.
-
-#if defined(__LITTLE_ENDIAN__) || defined(_WIN32) || (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+#if defined(__LITTLE_ENDIAN__) || defined(_WIN32) || (!defined(__ANDROID__) && BYTE_ORDER == ORDER_LITTLE_ENDIAN)
 # define htole16(x) (x)
 # define htole16(x) (x)
 # define htole32(x) (x)
 # define htole32(x) (x)
 # define htole64(x) (x)
 # define htole64(x) (x)