Better iOS version detection script.