编译android源码四(常见错误)

本文介绍了如何解决Android模拟器启动时遇到的问题,包括系统分区大小调整警告和SDL初始化失败等错误。提供了调整分区大小、安装必要的库文件及正确设置DISPLAY变量的方法。

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

运行如下命令:

$ emulator

1.错误信息: emulator: WARNING: system partition size adjusted to match image file (205 MB > 200 MB)

解决方法: emulator -partition-size 300


2. 错误信息:  SDL init failure, reason is: No available video device

2.1 安装 libsdl1.2debian:i386.

  • I added the site http://archive.canonical.com/ to the list of repositories.

  • I updated the apt-get.

  • I installed the libsdl1.2debian:i386.

sudo apt-add-repository "deb http://archive.canonical.com/ $(lsb_release -sc) partner"    
sudo apt-get update    
sudo apt-get install libsdl1.2debian:i386

问题原址: http://stackoverflow.com/questions/12709719/sdl-init-failure-reason-is-no-available-video-device-in-ubuntu-12-04-lts

2.2安装
sudo apt-get install ia322stdc++6b32

问题原址:http://stackoverflow.com/questions/4841908/sdl-init-failure-reason-is-no-available-video-device

用2.1 或者2.2 的方法试试。  

本人的就是试过上面所有的方法成功了


出现上面错误的原因,有可能是:

from Android emulator on a Unix/Linux platform, this typically indicates your shell's DISPLAY variable is not pointing to the correct X11 Display. Try launching the Android emulator as shown below. You may add your own parameters as needed as long the DISPLAY=:0 is there.
问题原址
http://babilonline.blogspot.tw/2012/06/android-emulator-gives-sdl-init-failure.html


解决方法:  DISPLAY=:0 emulator 


3.错误信息: emulator: WARNING: system partition size adjusted to match image file (205 MB > 200 MB)

SDL init failure, reason is: No available video device

解决方法: DISPLAY=:0 emulator -partition-size 300



评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值