3 This provides the endian conversion functions form endian.h on Windows, Linux,
4 *BSD, and Mac OS X. You still need to use `-std=gnu99` instead of `-std=c99`
5 for gcc. The functions might actually be macros. Functions: htobe16, htole16,
6 be16toh, le16toh, htobe32, htole32, be32toh, le32toh, htobe64, htole64,
9 The implementation was written by Mathias Panzenböck and published in this
14 Install with [clib(1)]:
17 clib install mikepb/endian.h
26 uint32_t endian32(const uint32_t i) {
35 [clib]: https://github.com/clibs/clib
36 [gist]: https://gist.github.com/panzi/6856583