Subject: Re: Correctly determining endianess
To: Martijn van Buul <firstname.lastname@example.org>
From: Dr. Lex Wennmacher <wennmach@geo.Uni-Koeln.DE>
Date: 04/12/2002 22:40:58
On Fri, Apr 12, 2002 at 10:07:19PM +0200, Martijn van Buul wrote:
> I'd like to do this in a neat way; any suggestions are would be welcome.
#if _BYTE_ORDER == _BIG_ENDIAN
If you need that in a Makefile, replace the #define in the snippet above with
a printf("BIG_ENDIAN\n"), or an exit(1) and check for the exit value.