Android development – Downloading sources
In this second part, I’ll show you how to download the sources, needed to build the ROM for your device.
If you missed the first tutorial: Android development – Setting up environment
According to your device model, you may have official ROM support or you have to build unofficial releases.
If there is no official support, things are harder for you, since you have to apply patches to make things compatible with your own device.
Sources takes about 20-30gb on your hdd, so be sure you have enough space on yours! (Yes for real)
Sources are the whole of files, mostly written in C and C++, which form the system. You will download tons of GBs of these files, and at the end of the process you’ll just have a 1GB image ready to flash on your device! Compilation maybe a really long task but if you succeed, at the end you’ll have your own fully customized ROM.
If you have recovered from the shock, keep reading!
Open your terminal and cd to a custom directory (I assume you called it “android”).
- To setup the download:
repo init -u git://github.com/CyanogenMod/android.git -b cm-14.0 (-b points to the branch in the repo to be chosen: cm-14.0)
- To start the download:
repo sync -j# (# is a number that tells how many downloads to do simultaneously, according to your connection)
Be patient, do something else, download may take really long time.
In the example I used CyanogenMod, but you can use whatever repo of your favourite custom ROM you want.
Most famous ROMs are (github links):
All ROMS differs in:
- Battery life
- Bugs (of course, I remember you that these are CUSTOM roms)
If you have some request or question, feel free to contact us!
That’s it for today, stay tuned for the next and last tutorial!