android源码下载, 看了几篇博客,综合下成功了。
来源:互联网 发布:手机避开公司网络监控 编辑:程序博客网 时间:2024/06/04 20:07
没有板子就学android系统源码,于是乎首先需要从google的服务器上下载android系统源码。在网上找些博客跟着做,但是并没有照着一篇做就成功了。所以借前辈们的检验做个小总结,也许我这里可以别人用或许又有新的问题。
参考:1.http://blog.csdn.net/zeroboundary/article/details/17555183
2. http://blog.csdn.net/lengxibo/article/details/8299888
3. http://yukun.elastos.org/2013/06/22/%E8%A7%A3%E5%86%B3%E4%B8%8B%E8%BD%BDandroid%E4%BB%A3%E7%A0%81%E6%97%B6failed-connect-to-android-googlesource-com443%E5%8A%9E%E6%B3%95/
我的环境为ubuntu10.04, 64bit
1. 安装curl工具
$ sudo apt-get install curl
2. git工具的安装(按照如下方式安装最新版)
$ sudo apt-add-repository ppa:git-core/ppa
$ sudo apt-get update
$ sudo apt-get install git
3. repo工具的下载
google是这样告诉我们的:
$ curl http://git-repo.googlecode.com/files/repo-1.12 > ~/bin/repo
$ chmod a+x ~/bin/repo
4. repo init创建仓库
$ ./repo init -u https://android.googlesource.com/platform/manifest -b android-4.4.2_r1
5. 执行repo sync进行同步
$ ./repo sync
问题1:“A new repo command ( 1.18) is available.”
其实这个问题就是说你本地的repo版本不是1.18,比这个旧,在出现这个的时候,下面会有一个提示你怎么操作的,如:
... A new repo command ( 1.18) is available.
... You should upgrade soon:
cp /home/pn/android/.repo/repo/repo/home/pn/bin/repo
问题2:下载android代码时错误提示:error: Failed connect to android.googlesource.com:443
解决方法:编辑/etc/hosts文件
$ sudo vim /etc/hosts
在网上找到两种内容
a.增加下面内容,保存
173.194.72.82http://www.googlesource.com
173.194.72.82 android.googlesource.com
37.61.54.158 cache.pack.google.com
173.194.74.82 gerrit.googlesource.com
b. 增加如下内容,保存
74.125.71.82 www.googlesource.com
74.125.71.82 android.googlesource.com
203.208.46.172 cache.pack.google.com
59.24.3.173cache.pack.google.com
两个都可以试一下。
问题三:下载中出现此现象fatal: unable to access 'https://android.googlesource.com/platform/manifest-b/': Failed connect to android.googlesource.com:443; Operation now in progress
fatal: unable to access 'https://android.googlesource.com/platform/manifest-b/': Failed connect to android.googlesource.com:443; Operation now in progress
fatal: unable to access 'https://android.googlesource.com/platform/abi/cpp/': Failed connect to android.googlesource.com:443; Operation now in progress
fatal: unable to access 'https://android.googlesource.com/platform/art/': Failed connect to android.googlesource.com:443; Operation now in progress
fatal: unable to access 'https://android.googlesource.com/platform/bionic/': Failed connect to android.googlesource.com:443; Operation now in progress
fatal: unable to access 'https://android.googlesource.com/platform/bootable/bootloader/legacy/': Failed connect to android.googlesource.com:443; Operation now in progress
如解决最好,但是我一直等待,跳过这些可以执行,也许有人是不可以的。上面那种可以试试是否可以解决。
- android源码下载, 看了几篇博客,综合下成功了。
- 终于在Ubuntu下成功下载了Android源代码
- 看了几篇关于失败 成功 爱 的文章跟大家分享
- Genymotion下载成功了
- 看了博客之后
- 看了**的博客
- 看了下 ROR
- 下载了Chrome源码
- 今天看了Struts的源码,总结下。
- 下载了:图标连连看
- 源码之家博客正式创建.自我happy下了.
- 精品Android源码推荐,看了绝不后悔
- 看了博客,谢了csdn的第一篇博客
- 开始搞ANDROID了--Android源码下载和编译
- JavaScriptCore 看了几篇资料没空总结 有空再说
- 超链接指向中文文件下载成功了
- 开始写了几篇博客,距离大神还有多远?
- 博客连连看 服务器关闭了
- java获取MySql数据库的连接方式案例
- 判断应用程序是否是第一次运行
- 5.跟我学solr---QueryResponseWriter详解
- 十条不错的编程观点
- 怎么使vmare虚拟机退出全屏
- android源码下载, 看了几篇博客,综合下成功了。
- leetcode:Wildcard Matching
- 懒加载异常 处理方法
- JVM学习笔记2(class文件校验器)
- 指尖上的电商---(4).net开发solr
- 设置Android设备为自动获取IP
- ScrollView中嵌套ListView或ExpandableListView时显示不全的问题
- 前端工程师的修真秘籍(css、javascript和其它)
- 密码控件安全技术浅析及攻击实例