forked from Mirrorlandia_minetest/minetest
Add macos/freebsd missing endian.h include and add win endianness info
This commit is contained in:
parent
1735c20549
commit
848b050a56
@ -26,7 +26,17 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
#if HAVE_ENDIAN_H
|
#if HAVE_ENDIAN_H
|
||||||
#include <endian.h>
|
#ifdef _WIN32
|
||||||
|
#define __BYTE_ORDER 0
|
||||||
|
#define __LITTLE_ENDIAN 0
|
||||||
|
#define __BIG_ENDIAN 1
|
||||||
|
#elif defined(__MACH__) && defined(__APPLE__)
|
||||||
|
#include <machine/endian.h>
|
||||||
|
#elif defined(__FreeBSD__)
|
||||||
|
#include <sys/endian.h>
|
||||||
|
#else
|
||||||
|
#include <endian.h>
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
#include <string.h> // for memcpy
|
#include <string.h> // for memcpy
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
Loading…
Reference in New Issue
Block a user