I've changed things a bit and resubmitted patch. Now there will be less ifdefs. I'm not sure which "data types" are you talking about, since I'll need per-byte surface access in any case, and It doesn't look like it can be wrapped into endianness-independant datatype.
Maybe you could use bitmasks to access the single bytes