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

使用清华镜像下载Android源码

2015-12-26 20:07 399 查看
1.  创建bin路径
macbookpro-2d30:~ xxx$ mkdir bin
PATH=~/bin:$PATH
2.  从清华镜像下载repo文件
macbookpro-2d30:bin xxx$ git clone git://aosp.tuna.tsinghua.edu.cn/android/git-repo.git
从git-repo文件下载repo文件拷贝到bin目录
macbookpro-2d30:bin xxx$ cp git-repo/repo ~/bin/
macbookpro-2d30:bin xxx$ chmod a+x repo
3.  打开repo文件,修改REPO_URL为:
macbookpro-2d30:bin xxx$ vim repo
REPO_URL = 'git://aosp.tuna.tsinghua.edu.cn/android/git-repo'
4.  进入自定义的android源码路径:
repo init -u git://aosp.tuna.tsinghua.edu.cn/android/platform/manifest,即可。
5.  repo sync -c -j4


清华镜像使用帮助:https://mirrors.tuna.tsinghua.edu.cn/help/#AOSP

中科大镜像使用帮助:https://lug.ustc.edu.cn/wiki/mirrors/help/aosp

Android官方使用帮助:http://source.android.com/source/requirements.html(要翻墙)
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: