mirror of
https://github.com/YGGverse/xash3d-fwgs.git
synced 2025-01-11 07:37:52 +00:00
public: add definitions for PowerPC
This doesn't mean we have a port but at least it allows building for ppc64el
This commit is contained in:
parent
9977cb20c0
commit
777dd3a03c
@ -162,6 +162,10 @@ const char *Q_ArchitectureStringByID( const int arch, const uint abi, const int
|
||||
return "e2k";
|
||||
case ARCHITECTURE_JS:
|
||||
return "javascript";
|
||||
case ARCHITECTURE_PPC:
|
||||
return endianness == ENDIANNESS_LITTLE ?
|
||||
( is64 ? "ppc64el" : "ppcel" ):
|
||||
( is64 ? "ppc64" : "ppc" );
|
||||
case ARCHITECTURE_MIPS:
|
||||
return endianness == ENDIANNESS_LITTLE ?
|
||||
( is64 ? "mips64el" : "mipsel" ):
|
||||
|
@ -76,6 +76,7 @@ Then you can use another oneliner to query all variables:
|
||||
#undef XASH_NETBSD
|
||||
#undef XASH_OPENBSD
|
||||
#undef XASH_POSIX
|
||||
#undef XASH_PPC
|
||||
#undef XASH_RISCV
|
||||
#undef XASH_RISCV_DOUBLEFP
|
||||
#undef XASH_RISCV_SINGLEFP
|
||||
@ -195,6 +196,11 @@ Then you can use another oneliner to query all variables:
|
||||
#elif defined __e2k__
|
||||
#define XASH_64BIT 1
|
||||
#define XASH_E2K 1
|
||||
#elif defined __PPC__ || defined __powerpc__
|
||||
#define XASH_PPC 1
|
||||
#if defined __PPC64__ || defined __powerpc64__
|
||||
#define XASH_64BIT 1
|
||||
#endif
|
||||
#elif defined _M_ARM // msvc
|
||||
#define XASH_ARM 7
|
||||
#define XASH_ARM_HARDFP 1
|
||||
|
@ -89,6 +89,7 @@ GNU General Public License for more details.
|
||||
#define ARCHITECTURE_JS 6
|
||||
#define ARCHITECTURE_E2K 7
|
||||
#define ARCHITECTURE_RISCV 8
|
||||
#define ARCHITECTURE_PPC 9
|
||||
|
||||
#if XASH_AMD64
|
||||
#define XASH_ARCHITECTURE ARCHITECTURE_AMD64
|
||||
@ -104,6 +105,8 @@ GNU General Public License for more details.
|
||||
#define XASH_ARCHITECTURE ARCHITECTURE_E2K
|
||||
#elif XASH_RISCV
|
||||
#define XASH_ARCHITECTURE ARCHITECTURE_RISCV
|
||||
#elif XASH_PPC
|
||||
#define XASH_ARCHITECTURE ARCHITECTURE_PPC
|
||||
#else
|
||||
#error
|
||||
#endif
|
||||
|
@ -47,6 +47,12 @@ static struct
|
||||
{ ARCHITECTURE_MIPS, 0, ENDIANNESS_LITTLE, true, "mips64el" },
|
||||
{ ARCHITECTURE_MIPS, 0, ENDIANNESS_LITTLE, false, "mipsel" },
|
||||
|
||||
// all possible PowerPC names
|
||||
{ ARCHITECTURE_PPC, 0, ENDIANNESS_BIG, true, "ppc64" },
|
||||
{ ARCHITECTURE_PPC, 0, ENDIANNESS_BIG, false, "ppc" },
|
||||
{ ARCHITECTURE_PPC, 0, ENDIANNESS_LITTLE, true, "ppc64el" },
|
||||
{ ARCHITECTURE_PPC, 0, ENDIANNESS_LITTLE, false, "ppcel" },
|
||||
|
||||
// All ARM is little endian only (for now?)
|
||||
// Arm64 is always arm64, no matter the version (for now)
|
||||
// Arm64 don't care about hardfp bit
|
||||
|
Loading…
Reference in New Issue
Block a user