windows下使用repo下载安卓源码
網上找了一些方法 都是比較早期的 過時的方法。
后來總結一下 結合官網linux下的方法 成功在windows下下載了安卓4.2.2
http://source.android.com/source/downloading.html
現在總結如下:
1.安裝Cygwin
下載 Cygwin ,然后就是一路的下一步(注意:如果第一次安裝,你需要選install from internet
然后就是選安裝位置,還有臨時文件的位置和連接網絡的設置,這些都默認就可以.關鍵的一步是選擇要安裝的庫和程序,以下這幾個是要安裝的:
Net -> curl
Devel -> git,git-completion,git-gui,gitk
Libs -> libreadline6,libiconv2
Editors -> vim
Python -> python
如果不好找,你可以在上面的Search上搜索.
感謝witxjp https://android.googlesource.com/tools/repo
2.安裝 Repo
打開cygwin,兩句命令搞定repo工具(https不行的話 換http)
$ curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > /bin/repo
$ chmod a+x /bin/repo
3.初始化 Repo client
我的是在D盤建立一個文件夾AndroidSource
$ cd d:/AndroidSource
$ repo init -u https://android.googlesource.com/platform/manifest
同樣https不行的話 換成http
然后提示需要輸入gmail姓名和賬號
Your Name
Your Email
輸入后按y確認
最后確認在賬號中顏色的顯示
black red green yellow blue magenta cyan white
bold
任選一個 確定,搞定。
4.確定下載安卓源碼的分支 版本
$ repo init -u https://android.googlesource.com/platform/manifest -b android-4.2.2_r1.2
同樣有一個顏色提醒
$ Enable color display in this user account (y/N)? y
就會提示完成了initialize
$ repo has been initialized in /cygdrive/d/neon/AndroidSource
5.同步源碼
$ repo sync
以下就看網速啦
總結
以上是生活随笔為你收集整理的windows下使用repo下载安卓源码的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 图灵奖得主(一)
- 下一篇: linux使用apache发布静态htm