More tweaks to OS determination stuff.

This commit is contained in:
Adam Ierymenko 2016-03-28 12:26:49 -07:00
parent 8035afae87
commit 1a5e7cb0cb

View file

@ -59,6 +59,7 @@
#ifndef __BSD__ #ifndef __BSD__
#define __BSD__ #define __BSD__
#endif #endif
#include <machine/endian.h>
#endif #endif
// Defined this macro to disable "type punning" on a number of targets that // Defined this macro to disable "type punning" on a number of targets that
@ -103,9 +104,8 @@
#include <Windows.h> #include <Windows.h>
#endif #endif
// Assume these are little-endian. PPC is not supported for OSX, and ARM // Assume little endian if not defined
// runs in little-endian mode for these OS families. #if (defined(__APPLE__) || defined(__WINDOWS__)) && (!defined(__BYTE_ORDER))
#if defined(__APPLE__) || defined(__WINDOWS__)
#undef __BYTE_ORDER #undef __BYTE_ORDER
#undef __LITTLE_ENDIAN #undef __LITTLE_ENDIAN
#undef __BIG_ENDIAN #undef __BIG_ENDIAN