ZNDS智能电视网 推荐当贝市场

TV应用下载 / 资源分享区

软件下载 | 游戏 | 讨论 | 电视计算器

综合交流 / 评测 / 活动区

交流区 | 测硬件 | 网站活动 | Z币中心

新手入门 / 进阶 / 社区互助

新手 | 你问我答 | 免费刷机救砖 | ROM固件

查看: 61172|回复: 1
上一主题 下一主题
[源码]

Android源码下载

[复制链接]
跳转到指定楼层
楼主
发表于 2013-8-28 16:30 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式 | 未知
5
1、先安装curl、git工具。
   
2、创建一个放android源码的目录。   
$ mkdir ~/Android_src   
$ mkdir ~/bin   
3、下载repo   
$ cd ~/bin   
$ curl http://android.git.kernel.org/repo > ~/bin/repo   
$ chmod a+x ~/bin/repo   
4、将repo工具所在的路径加入环境变量里PATH(/etc/environment/)中。   
或是在使用repo工具时,手动指定repo路径。   
$ cd ~/Android_src   
$ ~/bin/repo init -u git://android.git.kernel.org/platform/manifest.git   
注:可加 -b 指定所要下的版本,如不加则默认为最新版本。   
5、同步代码   
$~/bin/repo sync   
注:这过程比较慢长,一较要2~3个小时(主要由风速决定)   
   
如感觉上述麻烦,可新建如下脚本,只要运行如下脚本一切ok!!!   
#!/bin/sh   
  2 ########################################   
  # Create ~/Android_src directory   
  # Create ~/bin directory   
  ########################################   
sudo ln -snf /bin/bash /bin/sh   
if [ -z $(which curl ) ] ; then   
    sudo apt-get -y --force-yes --reinstall install curl   
fi   
if [ -z $(which git-core ) ] ; then   
    sudo apt-get -y --force-yes --reinstall install git-core   
fi   
test -d ~/bin || mkdir ~/bin   
   
test -e ~/bin/repo || curl http://android.git.kernel.org/repo > ~/bin/repo   
test -x ~/bin/repo || chmod a+x ~/bin/repo   
   
test -d ~/Android_src || mkdir ~/Android_src   
cd ~/Android_src   
~/bin/repo init -u git://android.git.kernel.org/platform/manifest.git   
~/bin/repo sync   
   

上一篇:深入学习android之AlarmManager
下一篇:Android2.2系统中自带的图片资源 J-P

相关帖子

沙发
发表于 2018-10-19 07:51 | 只看该作者 | 来自湖北
谢谢分亭
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Archiver|新帖|标签|软件|Sitemap|ZNDS智能电视网 ( 苏ICP备2023012627号 )

网络信息服务信用承诺书 | 增值电信业务经营许可证:苏B2-20221768 丨 苏公网安备 32011402011373号

GMT+8, 2025-4-25 19:51 , Processed in 0.062617 second(s), 15 queries , Redis On.

Powered by Discuz!

监督举报:report#znds.com (请将#替换为@)

© 2007-2025 ZNDS.Com

快速回复 返回顶部 返回列表