Closed jedavies-dev closed 2 years ago
Note this is in the miniutl project. But I couldn't open an issue there, so I am adding it here.
These four functions: loadwordbytereverse, storewordbytereverse, loaddoublewordbytereverse, storedoublewordbytereverse, are not defined. Can you advise if they are defined in one of your other libraries? Or are further changes required here?
It's compiler-dependent intrinsics. There macro for PS3 in minbase_endian.h and PS3 has CPU on PowerPC64, so you need to change macro in this header.
MiniUTL is a part of old Source SDK UTL which is got re-released under free license.
The part you're talking about is probably from PS3 or Xbox360, which were indeed big-endian.
As an example of porting Xash to big endian, we had some work on it in Old Engine branch. You can probably reuse these handy macros: https://github.com/FWGS/xash3d/blob/725fd84b5ba8d405979d63df7a906feb1bc87d51/engine/common/common.h#L103
Removed that functionality from MiniUTL, as it was completely unused.
I am working on porting xash3d to PowerPC systems. Modern PPC CPUs can run in either endian mode. Traditionally the preferred endianness was big-endian. Most 64-bit PPC distros today are little-endian though for compatibility reasons.
With some small changes, xash3d builds fine on powerpc64le (little-endian). However, it fails to build on powerpc64 (big-endian) with the following errors:
These four functions:
__loadwordbytereverse
,__storewordbytereverse
,__loaddoublewordbytereverse
,__storedoublewordbytereverse
, are not defined. Can you advise if they are defined in one of your other libraries? Or are further changes required here?