mirror of
https://github.com/GOSTSec/sgminer
synced 2025-01-24 05:24:23 +00:00
Add le16toh defines for platforms that may be missing it.
This commit is contained in:
parent
a6e0b6ed39
commit
b475355b08
2
miner.h
2
miner.h
@ -159,6 +159,7 @@ static inline int fsync (int fd)
|
||||
#ifndef htobe32
|
||||
# if __BYTE_ORDER == __LITTLE_ENDIAN
|
||||
# define htole16(x) (x)
|
||||
# define le16toh(x) (x)
|
||||
# define htole32(x) (x)
|
||||
# define htole64(x) (x)
|
||||
# define le32toh(x) (x)
|
||||
@ -169,6 +170,7 @@ static inline int fsync (int fd)
|
||||
# define htobe64(x) bswap_64(x)
|
||||
# elif __BYTE_ORDER == __BIG_ENDIAN
|
||||
# define htole16(x) bswap_16(x)
|
||||
# define le16toh(x) bswap_16(x)
|
||||
# define htole32(x) bswap_32(x)
|
||||
# define le32toh(x) bswap_32(x)
|
||||
# define le64toh(x) bswap_64(x)
|
||||
|
Loading…
x
Reference in New Issue
Block a user