From ce159e90bca94be3c9050fe467d497cfcbe759a8 Mon Sep 17 00:00:00 2001 From: Ladislav Zezula Date: Wed, 31 Mar 2021 08:23:16 +0200 Subject: * New platforms added * These are now considered to be Mac compatible --- src/StormPort.h | 122 ++++++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 118 insertions(+), 4 deletions(-) diff --git a/src/StormPort.h b/src/StormPort.h index 064e514..30d9e12 100644 --- a/src/StormPort.h +++ b/src/StormPort.h @@ -107,8 +107,7 @@ #endif //----------------------------------------------------------------------------- -// Defines for other platforms. Please, if you add a platform that is compatible -// with either Linux or Mac, define STORMLIB_LINUX or STORMLIB_MAC, respectively +// Defines for HAIKU platform #if !defined(STORMLIB_PLATFORM_DEFINED) && defined(__HAIKU__) @@ -137,7 +136,119 @@ #endif //----------------------------------------------------------------------------- -// Assumption: we are not on Windows nor Macintosh, so this must be linux *grin* +// Defines for AMIGA platform + +#if !defined(STORMLIB_PLATFORM_DEFINED) && defined(__AMIGA__) + + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + + #ifndef __BIG_ENDIAN__ + #define STORMLIB_LITTLE_ENDIAN + #endif + + #define STORMLIB_MAC // Use Mac compatible code + #define STORMLIB_AMIGA + #define STORMLIB_PLATFORM_DEFINED + +#endif + +//----------------------------------------------------------------------------- +// Defines for Switch platform + +#if !defined(STORMLIB_PLATFORM_DEFINED) && defined(__SWITCH__) + + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + + #ifndef __BIG_ENDIAN__ + #define STORMLIB_LITTLE_ENDIAN + #endif + + #define STORMLIB_MAC // Use Mac compatible code + #define STORMLIB_SWITCH + #define STORMLIB_PLATFORM_DEFINED + +#endif + +//----------------------------------------------------------------------------- +// Defines for 3DS platform + +#if !defined(STORMLIB_PLATFORM_DEFINED) && defined(__3DS__) + + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + + #define STORMLIB_LITTLE_ENDIAN + + #define STORMLIB_MAC // Use Mac compatible code + #define STORMLIB_CTR + #define STORMLIB_PLATFORM_DEFINED + +#endif + +//----------------------------------------------------------------------------- +// Defines for Vita platform + +#if !defined(STORMLIB_PLATFORM_DEFINED) && defined(__vita__) + + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + #include + + #ifndef __BIG_ENDIAN__ + #define STORMLIB_LITTLE_ENDIAN + #endif + + #define STORMLIB_MAC // Use Mac compatible code + #define STORMLIB_VITA + #define STORMLIB_PLATFORM_DEFINED + +#endif + +//----------------------------------------------------------------------------- +// Assumption: If the platform is not defined, this must be Linux *grin* #if !defined(STORMLIB_PLATFORM_DEFINED) @@ -156,7 +267,10 @@ #include #include - #define STORMLIB_LITTLE_ENDIAN + #ifndef __BIG_ENDIAN__ + #define STORMLIB_LITTLE_ENDIAN + #endif + #define STORMLIB_LINUX #define STORMLIB_PLATFORM_DEFINED -- cgit v1.2.3