您的位置:首页 > 移动开发 > Android开发

Ubuntu15.10 编译 Android5.0 源码

2015-12-17 22:06 417 查看
最近无事,编译了一下android 5.0的源码。

首先,感谢前人的栽树,主要是参考了http://blog.csdn.net/chouretang/article/details/43769839这篇文章,在此谢过。本文使用的是Ubuntu15.10 。

不过中间还是遇到了一些问题,列举如下:

1、原文中


3.安装编译依赖的软件

要修改为以下的,原文应该是作者编辑问题,有多余的空格导致错误。

sudo apt-get install git gnupg flex bison gperf build-essential zip curl libc6-dev libncurses5-dev:i386 x11proto-core-dev libx11-dev:i386 libreadline6-dev:i386 libgl1-mesa-dri:i386 libgl1-mesa-dev g++-multilib tofrodos python-markdown libxml2-utils xsltproc
zlib1g-dev:i386 dpkg-dev

2、编译过程中可能会遇到以下错误,使用make update-api进行编译即可

******************************
You have tried to change the API from what has been previously approved.

To make these errors go away, you have two choices:

1) You can add "@hide" javadoc comments to the methods, etc. listed in the

errors above.

2) You can update current.txt by executing the following command:

make update-api

To submit the revised current.txt to the main Android repository,

you will need approval.

******************************

3、编译模拟器



选择版本



4、启动模拟器

参考http://jingyan.baidu.com/article/86112f13549b44273797872c.html 即可

发一张成功的截图

内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: