* Removed dispatch.c from glapi-dispatching.o: GLDispatcher.cpp does

the job instead of dispatch.c.
* Fixed BYTE_ORDER support for BIG_ENDIAN targets (PPC).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30093 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Philippe Houdoin 2009-04-10 02:56:26 +00:00
parent 4623724398
commit 41976c3dc1
2 changed files with 13 additions and 11 deletions

View File

@ -352,7 +352,6 @@ if $(TARGET_ARCH) = x86 {
MergeObject <mesa>glapi-dispatching.o :
dispatch.c
glapi.c
glthread.c

View File

@ -142,17 +142,20 @@
* For now, only used by some DRI hardware drivers for color/texel packing.
*/
#if defined(BYTE_ORDER) && defined(BIG_ENDIAN) && BYTE_ORDER == BIG_ENDIAN
#if defined(__linux__)
#include <byteswap.h>
#define CPU_TO_LE32( x ) bswap_32( x )
#else /*__linux__*/
#include <sys/endian.h>
#define CPU_TO_LE32( x ) bswap32( x )
#endif /*__linux__*/
#define MESA_BIG_ENDIAN 1
#if defined(__linux__)
#include <byteswap.h>
#define CPU_TO_LE32( x ) bswap_32( x )
#elif defined(__BEOS__) || defined(__HAIKU__)
#include <ByteOrder.h>
#define CPU_TO_LE32( x ) B_HOST_TO_LENDIAN_INT32( x )
#else
#include <sys/endian.h>
#define CPU_TO_LE32( x ) bswap32( x )
#endif
#define MESA_BIG_ENDIAN 1
#else
#define CPU_TO_LE32( x ) ( x )
#define MESA_LITTLE_ENDIAN 1
#define CPU_TO_LE32( x ) ( x )
#define MESA_LITTLE_ENDIAN 1
#endif
#define LE32_TO_CPU( x ) CPU_TO_LE32( x )