Fix issues with arm64 and i386