diff --git a/storage/rocksdb/rdb_buff.h b/storage/rocksdb/rdb_buff.h index 31094739469f..9f9ad93aa6a3 100644 --- a/storage/rocksdb/rdb_buff.h +++ b/storage/rocksdb/rdb_buff.h @@ -21,6 +21,21 @@ #include #include +#ifdef __APPLE__ + +#include + +#define be16toh(x) OSSwapBigToHostInt16(x) +#define htobe16(x) OSSwapHostToBigInt16(x) + +#define be32toh(x) OSSwapBigToHostInt32(x) +#define htobe32(x) OSSwapHostToBigInt32(x) + +#define be64toh(x) OSSwapBigToHostInt64(x) +#define htobe64(x) OSSwapHostToBigInt64(x) + +#endif // __APPLE__ + /* MySQL header files */ /* MyRocks header files */