loci: fix byte order check

Reviewer: @kenchiang

__ORDER_BIG_ENDIAN was not defined. This version uses the macros from the GCC 
docs.