[Onetouch Idol 3 General] Jeik:
Oooookay,now let's get down to business!

PART 1

First of all,we will have to create a directory for rom build folders.

Here is MY EXAMPLE,you can name your folders however you want!

Then,of course,let's get our hands on the CyanogenMod manifest.

A manifest is a part of a rom's github directory network which holds the information which one uses to intialize a certain rom's build directory on his PC.

In our case,we need the manifest from CyanogenMod 12.1,which is HERE

There you will find this:

Of course,after you cd-d into your cm build directory,type this command in:

repo init -u git://github.com/CyanogenMod/android.git -b cm-12.1

Then navigate to the CM build folder,make hidden folders visible and open the manifest.xml in the text editor.

Find the "darwin" line,and delete the lines containing the darwin directories(the ones in the picture,there are other ones as well-delete them too)

This will reduce the download time by a decent amount. Those lines are meant for the PC to download files for MacOS,which we don't even need.

Now,let's move on to making the PC sync all the files for OUR device.

For that we need to create a file named "local_manifest.xml"

We will input the lines which will pull files for our device files from the repositories Unjustified Dev had made.

The final product is visible in the picture.

You most likely see an extra line on the bottom. That line is a MUST for CM,otherwise it won't build...

Here is it all in code,so you can just paste it. You are very welcome,by the way ;P

<?xml version="1.0" encoding="UTF-8"?>
<manifest>
<project path="device/alcatel/idol3" name="TeamRegular/android_device_alcatel_idol3" remote="github" revision="cm-12.1" />
<project path="vendor/alcatel/idol3" name="TeamRegular/android_vendor_alcatel_idol3" remote="github" revision="cm-12.1" />
<project path="kernel/alcatel/msm8916" name="TeamRegular/android_kernel_alcatel_msm8916" remote="github" revision="cm-12.1" />
<project path="device/qcom/common" name="CyanogenMod/android_device_qcom_common" remote="github" revision="cm-12.1" />
</manifest>

Okay,now we can perform a REPO SYNC.

Type in

repo sync -c

Now,depending on your internet download speed,all the files will be downloaded to your PC.

Now we will set up ccache and prebuilt Webview.

Ccache is a type of cache. Without tiring you with the details,I will make it simple.

You do understand that a lot of tools will be working while making your build,right?

Ccache stores the data those build tools need,so after the first time,those tools won't need to load all the data yet again.

This saves a lot of time!

Now,we already did one part of this set up while editing .bashrc,but this is the main attraction.

Make sure you are in your cm build directory when typing this command,or you will get an error saying "no directory"

prebuilts/misc/linux-x86/ccache/ccache -M 64G

Now,onto prebuilt Webview.

You see,this is only for those who have less than 8GB of RAM.

While being created,the Webview will hog around 7GB of RAM,overloading the PC and making it freeze for more than 8 hours until it force-stops the building or decides to pull it off after extra 6 hours,resulting in 14 hours for one single damn file.

Buuut,because

I will show you how to make the build finish in less than 12 hours at first,and then in less than 4 hours on "dirty"(aka stack builds).

1. Open up your manifest.xml

2. Find the line holding " webview ".

then,replace the line

<project path="frameworks/webview" name="CyanogenMod/android_frameworks_webview" />

with this line

<project path="frameworks/webview" name="arter97/android_frameworks_webview" remote="github" revision="cm-12.1" />

3. Go to " frameworks " folder and delete the " webview " folder

4. In the terminal(while in the CM folder,of course) type

repo sync -c --force-sync

and wait for it to do its magic

5. Open the newly appeared " webview " folder inside the " frameworks" folder, and open its " Readme.mkdn " file with a text editor

6. Follow its procedure,I present to you the pictures of things I changed!

7. Save the changes!

Woohoo,another step closer!

PART 2

Now the real party begins!

Make sure you are in your CM folder.

Type THIS command:

. build/envsetup.sh

Then THIS one:

lunch cm_idol3-userdebug

And finally,THIS one

mka bacon

Which, in the end, should look like THIS

The building procedure has begun. U.U

​