Skip to content

Commit 5eb8970

Browse files
committed
Update int-util.h
1 parent 6d2ca89 commit 5eb8970

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

crypto/int-util.h

+15
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,21 @@
1010
#include <string.h>
1111
#include <sys/param.h>
1212

13+
/*
14+
* Create GNU compatible endian macros. We use the values for __LITTLE_ENDIAN
15+
* and __BIG_ENDIAN based on endian.h.
16+
*/
17+
#ifdef __sun
18+
#include <sys/byteorder.h>
19+
#define LITTLE_ENDIAN 1234
20+
#define BIG_ENDIAN 4321
21+
#ifdef _LITTLE_ENDIAN
22+
#define BYTE_ORDER LITTLE_ENDIAN
23+
#else
24+
#define BYTE_ORDER BIG_ENDIAN
25+
#endif /* _LITTLE_ENDIAN */
26+
#endif /* __sun */
27+
1328
#if defined(_MSC_VER)
1429
#include <stdlib.h>
1530

0 commit comments

Comments
 (0)