configure: add ACX_HEADER_ENDIAN macro and cleanup headers