home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
crypl200.zip
/
ENDIAN.C
< prev
next >
Wrap
Text File
|
1996-10-11
|
518b
|
19 lines
/* This is a lowest-common-denominator program which should compile under
the default cc on any system, no matter how primitite (even the SunOS
one - note the use of 1970's-vintage octal escapes). This is necessary
because it's compiled before we can try and select a decent compiler via
the makefile */
#include <stdio.h>
#include <stdlib.h>
int main()
{
if( *( long * ) "\200\0\0\0\0\0\0\0" < 0 )
printf( "-DBIG_ENDIAN" );
else
printf( "-DLITTLE_ENDIAN" );
return( 0 );
}