On Fri, 2016-06-10 at 15:38 -0400, Joseph Brennan wrote: > Look out for big-endian and little-endian, too. That affects > databases. > This bit us once when we copied a berkeley db from solaris to linux. > Endian-ness is based on the cpu hardware, but apparently Macs and > most hardware used for Linux (like Intel) are both little-endian-- so > it is probably not the answer in this case. > Has to be an implementation difference in that case, e.g UTF-8 vs ASCII or somebody decided that using an int was wasteful and used a short instead.
> This is a nice test I found: > echo -n I | od -to2 | awk '{ print substr($2,6,1); exit}' > > 1 little-endian > 0 big-endian > Very nice indeed. Thanks for posting it. Martin