网鼎杯比赛一条安卓脱壳题目,临时部署环境,遇到各种问题,发现国内没有相关帖子,就单独做一篇出来。
AS 中部署虚拟机镜像选择的是不带 google-api
。
安装后在文件夹内只有 kernel-qemu 内核。
直接启动就会报错:
Emulator: emulator: ERROR: This AVD's configuration is missing a kernel file! Please ensure the file "kernel-ranchu" is in the same location as your system image.
从 AS 开发手册中查询到,模拟器默认启动的是 kernel-ranchu 。如果需要使用其他内核需要手动启动,并指定 kernel 。
emulator -avd <AVD_NAME> -kernel kernel-qemu
kernerl-ranchu 是一个新款虚拟机的内核文件。当你下载的系统镜像带有 google-api 的标签是就会有这个内核文件。