From c13e46c982133482f32352c5a845978a5f076116 Mon Sep 17 00:00:00 2001 From: Steve Bennett Date: Tue, 4 Oct 2011 10:50:47 +1000 Subject: microblaze can be either big or little endian Signed-off-by: Steve Bennett Signed-off-by: Bernhard Reutner-Fischer --- libc/sysdeps/linux/microblaze/bits/endian.h | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'libc/sysdeps/linux/microblaze') diff --git a/libc/sysdeps/linux/microblaze/bits/endian.h b/libc/sysdeps/linux/microblaze/bits/endian.h index 8a4f6efcc..56fcd5dd9 100644 --- a/libc/sysdeps/linux/microblaze/bits/endian.h +++ b/libc/sysdeps/linux/microblaze/bits/endian.h @@ -17,4 +17,11 @@ # error "Never use directly; include instead." #endif -#define __BYTE_ORDER __BIG_ENDIAN +/* Note: Toolchain supplies _BIG_ENDIAN or _LITTLE_ENDIAN */ +#if defined(_BIG_ENDIAN) +# define __BYTE_ORDER __BIG_ENDIAN +#elif defined(_LITTLE_ENDIAN) +# define __BYTE_ORDER __LITTLE_ENDIAN +#else +# error "Endianness is unknown" +#endif -- cgit v1.2.3