From 9fc57894abeca9383e6120239f9561d7589f439d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Henrik=20Rydg=C3=A5rd?= Date: Thu, 25 Jul 2013 19:21:43 +0200 Subject: [PATCH] Mac build fix (weird, BIG_ENDIAN really shouldn't be defined) --- Common/CommonTypes.h | 11 +++++++++++ Core/Font/PGF.h | 3 ++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/Common/CommonTypes.h b/Common/CommonTypes.h index 80d3a07fd6..9a62b398b0 100644 --- a/Common/CommonTypes.h +++ b/Common/CommonTypes.h @@ -28,6 +28,17 @@ #endif #endif + +// Seriously, WTF? +#ifdef __APPLE__ +#ifdef BIG_ENDIAN +#undef BIG_ENDIAN +#endif +#ifdef __BIG_ENDIAN__ +#undef __BIG_ENDIAN__ +#endif +#endif + #ifdef _WIN32 typedef unsigned __int8 u8; diff --git a/Core/Font/PGF.h b/Core/Font/PGF.h index 3a94bbfd8c..5924f5b1b1 100644 --- a/Core/Font/PGF.h +++ b/Core/Font/PGF.h @@ -108,7 +108,8 @@ struct Glyph { u32 ptr; }; -#if !defined(BIG_ENDIAN) && !defined(__BIG_ENDIAN__) +// Bizarre that we need __APPLE__ here. +#if defined(__APPLE__) || !defined(BIG_ENDIAN) && !defined(__BIG_ENDIAN__) typedef FontPixelFormat FontPixelFormat_le; #else error FIX ME