Check for SYS/GL during library init. Reason is that
[AROS.git] / workbench / network / common / include / endian.h
blob6adf6a7af4dd6ff08f800c11e629e43c483a606a
1 #ifndef _ENDIAN_H_
2 #define _ENDIAN_H_
4 /*
5 Copyright © 2003-2011, The AROS Development Team. All rights reserved.
6 $Id$
7 */
9 /*
10 BSD systems like to see BYTE_ORDER and friends.
12 FreeBSD 5 in its pedantic namespace also has versions with underscores
13 to make it easier to port stuff, create them as well.
16 #include <aros/system.h>
18 #if defined(_BIG_ENDIAN)
19 # undef _BIG_ENDIAN
20 #endif
22 #define _LITTLE_ENDIAN 1234
23 #define _BIG_ENDIAN 4321
24 #define _PDP_ENDIAN 3412
26 #if AROS_BIG_ENDIAN
27 # define _BYTE_ORDER _BIG_ENDIAN
28 #else
29 # define _BYTE_ORDER _LITTLE_ENDIAN
30 #endif
32 #if __BSD_VISIBLE
33 # define LITTLE_ENDIAN _LITTLE_ENDIAN
34 # define BIG_ENDIAN _BIG_ENDIAN
35 # define PDP_ENDIAN _PDP_ENDIAN
36 # define BYTE_ORDER _BYTE_ORDER
37 #endif
39 #endif /* _ENDIAN_H_ */