home *** CD-ROM | disk | FTP | other *** search
/ RISCWORLD 7 / RISCWORLD_VOL7.iso / Software / Issue2 / SDL.ARC / !unixlib / source / clib / machine / h / endian next >
Encoding:
Text File  |  2004-09-05  |  1.0 KB  |  34 lines

  1. /****************************************************************************
  2.  *
  3.  * $Source: /usr/local/cvsroot/gccsdk/unixlib/source/clib/machine/endian.h,v $
  4.  * $Date: 2001/01/29 15:10:19 $
  5.  * $Revision: 1.2 $
  6.  * $State: Exp $
  7.  * $Author: admin $
  8.  *
  9.  ***************************************************************************/
  10.  
  11. #ifndef    __ENDIAN_H
  12. #define    __ENDIAN_H    1
  13.  
  14. /* Definitions for byte order, according to significance of bytes, from low
  15.    addresses to high addresses.  The value is what you get by putting '4'
  16.    in the most significant byte, '3' in the second most significant byte,
  17.    '2' in the second least significant byte, and '1' in the least
  18.    significant byte.  */
  19.  
  20. #define    __LITTLE_ENDIAN    1234
  21. #define    __BIG_ENDIAN    4321
  22. #define    __PDP_ENDIAN    3412
  23.  
  24. /* Byte order for RISC OS is little endian.  */
  25. #define __BYTE_ORDER __LITTLE_ENDIAN
  26.  
  27. /* For compatibility with BSD.  */
  28. #define    LITTLE_ENDIAN    __LITTLE_ENDIAN
  29. #define    BIG_ENDIAN    __BIG_ENDIAN
  30. #define    PDP_ENDIAN    __PDP_ENDIAN
  31. #define    BYTE_ORDER    __BYTE_ORDER
  32.  
  33. #endif
  34.