webmcp

view libraries/moonhash/byteorder.h @ 564:6141ab127861

Fixed handling of derived translation tables
author jbe
date Sun Mar 07 17:21:12 2021 +0100 (17 months ago)
parents fa902b26589f
children
line source
1 /* Defines LITTLE_ENDIAN_DETECTED if system follows little endian byte order
2 scheme. Does not define anything if endianess could not be determined. */
4 #if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__)
5 # include <sys/endian.h>
6 # if defined(_BYTE_ORDER) && defined(_LITTLE_ENDIAN)
7 # if _BYTE_ORDER == _LITTLE_ENDIAN
8 # define LITTLE_ENDIAN_DETECTED
9 # endif
10 # else
11 # warning Could not determine endianess on BSD platform, revert to fail safe.
12 # endif
13 #elif defined(__linux__)
14 # include <endian.h>
15 # if defined(__BYTE_ORDER) && defined(__LITTLE_ENDIAN)
16 # if __BYTE_ORDER == __LITTLE_ENDIAN
17 # define LITTLE_ENDIAN_DETECTED
18 # endif
19 # else
20 # warning Could not determine endianess on Linux platform, revert to fail safe.
21 # endif
22 #else
23 # warning Could not determine endianess, revert to fail safe.
24 #endif

Impressum / About Us