aboutsummaryrefslogtreecommitdiff
path: root/include/platform.h
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2006-02-21 06:44:43 +0000
committerRob Landley <rob@landley.net>2006-02-21 06:44:43 +0000
commit5cf7c2df668d25c41a05670edd08558226f0bfdf (patch)
tree3c3a7b2aa31dd4105f15f435a5894c91c941686e /include/platform.h
parenta7e3d0520856db27744b4a33e786123d44bf5b2a (diff)
downloadbusybox-5cf7c2df668d25c41a05670edd08558226f0bfdf.tar.gz
Patch from Devin Bayer to split up hash_fd.c into md5.c and sha1.c. (I tweaked
md5_sha1_sum.c to convert some #ifdef CONFIG to if(ENABLE).)
Diffstat (limited to 'include/platform.h')
-rw-r--r--include/platform.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/include/platform.h b/include/platform.h
index 68c7abbc6..b19621af1 100644
--- a/include/platform.h
+++ b/include/platform.h
@@ -78,4 +78,19 @@
# endif
#endif
+/* ---- Endian Detection ------------------------------------ */
+#ifndef __APPLE__
+ #include <byteswap.h>
+ #include <endian.h>
+#endif
+
+#ifdef __BIG_ENDIAN__
+ #define BB_BIG_ENDIAN 1
+#elif __BYTE_ORDER == __BIG_ENDIAN
+ #define BB_BIG_ENDIAN 1
+#else
+ #define BB_BIG_ENDIAN 0
+#endif
+
+
#endif /* platform.h */