# [TUTORIAL] So You Want To Build AOKP/ICS for the Touchpad?



## ProTekk (Jun 12, 2011)

This is strictly just a reference guide/tutorial! If you cannot simply follow directions and copy/paste, I'm not going to help you! This is idiot-proof.

*Build Environment*​
Operating system -- Tested on Ubuntu 10.04 (64bit)
Terminal
Decent hardware (minimum of at least a dual core CPU and 4 GB of RAM)
Optimally have an SSD (standard mechanical drives work as well but slow down the process drastically)
Must have required packages for building installed, I will list them further down
*Required Packages*​
Simply copy and paste this in a terminal window:​

```
sudo apt-get install curl git-core gnupg flex bison gperf libsdl1.2-dev libesd0-dev libwxgtk2.6-dev squashfs-tools build-essential zip curl libncurses5-dev zlib1g-dev sun-java6-jdk pngcrush schedtool g++-multilib lib32z1-dev lib32ncurses5-dev lib32readline5-dev gcc-4.3-multilib g++-4.3-multilib
```

Let that install and then proceed.​
*Getting the Source*​
Make required directories
Obtain repo binary
Add repo binary to your path
Give repo binary proper permissions
Initialize empty repo
Sync repo
Alright, so now we're getting there. I have outlined the basics of what we're about to do and broke them down as I know them. This is all pretty much going to be copy/paste so it'll be fairly difficult to screw this up ​
Copy/paste:​
*Make directory for repo binary*​
```
mkdir ~/bin
```

*Add directory for repo binary to your path*​
```
PATH=~/bin:$PATH
```

*Download repo binary and place it in the proper directory*​
```
curl [URL=https://dl-ssl.google.com/dl/googlesource/git-repo/repo]https://dl-ssl.google.com/dl/googlesource/git-repo/repo[/URL] > ~/bin/repo
```

*Give the repo binary the proper permissions*​
```
chmod a+x ~/bin/repo
```

*Create directory for where the AOKP repo will be stored and synced*​
```
mkdir ~/aokp
```

*Move to our new AOKP directory*​
```
cd ~/aokp
```

*Initialize the AOKP repo and download the manifest*​
```
repo init -u [URL=git://github.com/AOKP/platform_manifest.git]git://github.com/AOKP/platform_manifest.git[/URL] -b master
```

*Sync AOKP source*​
```
repo sync -jX
```
 X == Number of cores your CPU has​
*Start the build*​
This is probably the EASIEST part of all, simply copy/paste this command and walk away!​
```
. build/envsetup.sh && lunch aokp_tenderloin-userdebug && make otapackage -jX
```
 Where X == cores per CPU again.​
Syncing the repo is dependent upon your Internet connection. It can take anywhere from 30 minutes to several hours to fully sync. Same thing goes for build times. Don't expect this to be short. If you have patience and have no build errors, you'll end up with a flashable zip in ~/aokp/out/target/product/tenderloin! Happy crack-flashing!​


----------



## Redflea (Jun 7, 2011)

ProTekk said:


> This is strictly just a reference guide/tutorial! If you cannot simply follow directions and copy/paste, I'm not going to help you! This is idiot-proof.
> 
> *Build Environment*​
> Operating system -- Tested on Ubuntu 10.04 (64bit)
> ...


Great to see another build thread, nice post. Pretty soon we'll have as many builders as downloaders.









Sent from my Galaxy Nexus using Tapatalk


----------

