Removed endian.h as boost dependency (by copying)