Red Rice 3 (ido) CyanogenMod12.1 compilation tutorial

Source: Internet
Author: User

Environment construction

1. Install the 64-bit Ubuntu system (physical installation, virtual machine installation can be)

Note: require the machine at least 4G of memory (virtual machine allocated at least 4G memory), hard disk at least 100G space (source 20g+, compiled after the entire directory about 60~70g)
Installation method please Baidu ~

2. Update the system to the latest version and enter it under terminal

    1. sudo apt-get update
    2. sudo apt-get upgrade

3. Install and compile required packages

    1. sudo apt-get install Bison build-essential Curl Flex git gnupg gperf libesd0-dev libncurses5-dev libsdl1.2-dev libwxgtk2.8 -dev libxml2 libxml2-utils lzop openjdk-7-jdk openjdk-7-jre pngcrush schedtool squashfs-tools xsltproc zip Zlib1g-dev g++- Multilib gcc-multilib Lib32ncurses5-dev Lib32readline-gplv2-dev Lib32z1-dev

4. Establishing the Repo command

    1. Mkdir-p ~/bin
    2. Curl Https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
    3. chmod a+x ~/bin/repo
    4. echo "Export path=~/bin: $PATH" >> ~/.BASHRC

Note that the second line to download from Google Repo applet, the domestic network you know, you can hang an agent on the browser to download the following address, copy to ~/bin/repo, and then execute the third and fourth lines of the command

    1. Https://storage.googleapis.com/git-repo-downloads/repo

Synchronous source
1. Create a new folder to store the source code, here take ~/android/cm as an example

    1. mkdir ~/android/cm
    2. CD ~/android/cm

2. Initializing the source directory

    1. Repo Init-u git://github.com/cyanogenmod/android.git-b cm-12.1

3. Add Red Meter 3 dedicated file directory

    1. mkdir ~/android/cm/.repo/local_manifests
    2. Gedit ~/android/cm/.repo/local_manifests/ido.xml

Copy the following contents into the

<?xml version="1.0"encoding="Utf-8"?><manifest> <project name="Ido-dev/android_device_xiaomi_ido"Path="Device/xiaomi/ido"revision="cm-12.1"Remote="GitHub"/> <project name="Ido-dev/proprietary_vendor_xiaomi"Path="Vendor/xiaomi"revision="cm-12.1"Remote="GitHub"/> <!--<project name="Ido-dev/android_kernel_xiaomi_ido"Path="Kernel/xiaomi/ido"revision="cm-12.1"Remote="GitHub"/>--<project name="Cyanogenmod/android_device_qcom_common"Path="Device/qcom/common"Remote="GitHub"/> <project name="Cyanogenmod/android_external_sony_boringssl-compat"Path="External/sony/boringssl-compat"Remote="GitHub"/> <project name="Cyanogenmod/android_external_stlport"Path="External/stlport"Remote="GitHub"/></manifest>

4. For the Domestic network environment processing (slightly own use VPN or SS, tutorial please Baidu)
5. Pull the replacement code (need to download about more than 10 g of content, take the time to refer to the respective speed)

    1. Repo Sync--no-clone-bundle

If the intermittent network, or error, re-repo sync a bit can continue ~
6. Get precompiled parts of the file

    1. CD ~/android/cm/vendor/cm
    2. ./get-prebuilts


Compile ROM
1. Initializing the compilation environment

    1. CD ~/android/cm
    2. . build/envsetup.sh
    3. Lunch Cm_ido-userdebug

2. Compile ROM (the virtual machine under My notebook takes about 2 hours, depending on PC performance)

    1. Mka Ido

Note: At the beginning of the compilation of the first appearance of the following lines is normal phenomenon, does not affect the ~

    1. Find: ' src ': No such file or directory
    2. Find: ' Phone/java ': No such file or directory
    3. Find: ' dummy ': No such file or directory

Compile again
1. It is recommended that each compilation will be the last compilation of the content purged, or there may be inexplicable problems

    1. Make clobber

2. Synchronize the source to the latest version again

    1. Repo Sync

3. Initializing the compilation environment

    1. . build/envsetup.sh
    2. Lunch Cm_ido-userdebug

4. Compiling ROM

    1. Mka Ido

A little bit of tips
Turn on CCache to speed up the compilation process

    1. Export use_ccache=1

Red Rice 3 (ido) CyanogenMod12.1 compilation tutorial

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.