Download Google Android4.4 source on Ubuntu

Source: Internet
Author: User

Install Cygwin under Windows, you can also download the Android source code via Cygwin in Windows through the download steps in this article.


Here are the steps to download Google Android4.4 source under Ubuntu:
1. Install Curl and Git
sudo apt-get Install Curl
sudo apt-get install Git-core

2 Installing Repo
A) set up the repo installation directory and configure environment variables
$ mkdir ~/bin
$ Path=~/bin: $PATH
b) Get Repo tool
$ Curl Https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo
Question: The above is the Google-made repo get address, but the acquisition may fail.
Solution: Online users have given the alternative to obtain the address, such as error can be replaced by the following address:
Curl "Http://php.webtutor.pl/en/wp-content/uploads/2011/09/repo" > ~/bin/repo (I am using this, available)
Then change the permissions:
$ chmod a+x ~/bin/repo

3 Create and enter the source download directory
$ mkdir working_directory
$ CD Working_directory

4 Initializing source Repo
If the current code is downloaded, then:
Repo Init-u https://android.googlesource.com/platform/manifest
To download the code for a specific Android-mature version of the branch, add the-b parameter, such as the currently newly released Android 4.4 branch code:
Repo Init-u https://android.googlesource.com/platform/manifest-b ANDROID-4.4.1_R1
Commands such as smooth execution, the period will require input unsername and email, directly enter their own custom user name and email.

5 Synchronizing full source code
$ repo Sync
Issue: The command may be error-related during execution:
Fatal: '. /platform/abi/cpp.git ' does not appear to be a git repository
Fatal:the remote end hung up unexpectedly
Error:cannot Fetch Platform/abi/cpp
Workaround:
Go to working_directory, show hidden files, see. Repo directory and open manifest.xml, find the Fetch attribute and modify it to:
Fetch= "git://android.git.linaro.org

The Repo Sync command is generally not a one-time success during execution, may be timed out in the middle or there are other failures, and the previous record is cached by simply performing repo sync again.

Reference Document: http://blog.csdn.net/droidpioneer/article/details/24738353

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.