Android 4.3 emulator screen stay black and qemu: could not load initrd 'ramdisk.img'

本文介绍了一位开发者在自编译Android 4.3源代码后遇到的模拟器启动问题。具体表现为模拟器屏幕始终为黑色且ADB设备显示离线。通过更换内核配置解决了黑屏问题,但仍存在加载ramdisk.img失败的情况。文中提供了详细的解决步骤和命令行参数。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

After building the 4.3 source code, I try to run the emulator with self-compiled system.img, userdata.img and ramdisk.img, but the emulator's screen stays black and adb devices shows offline, no output.

Try to use "kernel-qemu-armv7" instead of "kernel-qemu", solve the balck screen.

But there is still "qemu: could not load initrd 'ramdisk.img', after trying several times follow the guide on internet:

1. chmod 777 -R * in ramdisk.img's path.

2. using full path in -ramdisk

below list my cmd:

/AOSP/out/host/linux-x86/bin/./emulator -kernel /AOSP/prebuilts/qemu-kernel/arm/kernel-qemu-armv7 -sysdir /AOSP/out/target/product/generic/ -system system.img -data userdata.img -ramdisk /AOSP/out/target/product/generic/ramdisk.img -skindir skins/ -skin HVGA -partition-size 768

the skins/ folder is copied from SDK path.


评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值