Ubuntu12.04 download Android source code

Source: Internet
Author: User
Tags gnupg

(The following command is used to log on to the root account. If a common user needs to add sudo before the command)

1. To build Java jdk1.6, see install java_jdk on Ubuntu.

2. Add a package

64-bit system:

Apt-Get install Git-core GnuPG flex bison gperf build-essential zip curl zlib1g-dev libc6-dev lib32ncurses5-dev ia32-libs x11proto-core-dev libx11-dev lib32readline5-dev lib32z-dev g ++-multilib mingw32 tofrodos Python-markdown libgl1-mesa-dev unzip tproc

32-bit system:

Apt-Get install Git-core GnuPG flex bison gperf build-essential zip curl zlib1g-dev libc6-dev libncurses5-dev x11proto-core-dev libx11-dev libreadline6-dev tofrodos Python-markdown libgl1-mesa-dev extends tproc

3. Download the repo script

Mkdir ~ /Develop # create a develop folder under the same directory

Mkdir ~ /Develop/download-Froyo # create the download-Froy folder in the develop directory

Cd ~ /Develop/download-Froyo # enter this directory

Curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo>./repo # download the repo script from the source site, the script is provided by Google to facilitate the download of the source code, through the script can download the entire set of source code

Chmod A + x repo # Set this script to Executable

4. initialize a repo Client

./Repo init-u https://android.googlesource.com/platform/manifest # execute the repo init operation to get the latestSource codeList

./Repo init-u https://android.googlesource.com/platform/manifest-B android-4.0.1_r1 # Then use-B to determine which branch to download

During the download process, you need to enter the name and email, and then select y for confirmation.

Finally, the system prompts that repo Initialization is complete in the directory where it is located. Here we can also see that there is a hidden file. repo/in the current directory with some initialization information.

4.CodeSynchronization

./Repo sync

Related Article

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.