[AT&T, Rogers HTC One X, Telstra One XL] mikshepard:
** HOW-TO COMPILE THIS YOURSELF **

Here are my notes on how to port SlimBean to our devices, should anyone be interested in compiling their own. I ran into a few headaches when I attempted this, so I’m hoping these notes will save others from that. The point of this tutorial is to teach newbies how to port a ROM, while I could do some things on my end make it easier to compile this ROM, I think it's important to outline all the steps involved in doing this by hand, so the methods may be applied to other ROM ports, not just SlimBean.

I compiled on a Debian Wheezy system, 64bit (squeeze should be the same). A 64-bit computer is required to compile Jellybean (ICS and above for that matter), so don’t attempt this on anything less. If you are unfamiliar with installing Debian, you can use LMDE, it's a live Debian system that you can install with minimal linux knowledge and works pretty nice. However the installation process is pretty easy for vanilla Debian and a good learning process, so give it a shot if you have the time.

Do this all as root

Download dependencies:

apt-get install git-core gnupg flex bison gperf build-essential zip curl libc6-dev libncurses5-dev x11proto-core-dev libx11-dev libreadline6-dev g++-multilib mingw32 openjdk-6-jdk tofrodos python-markdown libxml2 libxml2-utils schedtool pngcrush xsltproc zlib1g-dev lib32stdc++6 lib32ncurses5 ncurses-libs.i686 libstdc++.i686 libgcc.i686 lib32readline-gplv2-dev lib32z1-dev

Link files:

ln -s /lib32/libncurses.so.5 /lib32/libncurses.so

or for Ubuntu 10.10:

sudo ln -s /usr/lib32/mesa/libGL.so.1 /usr/lib32/mesa/libGL.so

Install Google’s repo script:

mkdir ~/bin
PATH=~/bin:$PATH
curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo
chmod 755 ~/bin/repo

Make your working Directory and start syncing with SlimBean

mkdir ~/slimbean; cd ~/slimbean
repo init -u git://github.com/SlimRoms/platform_manifest.git -b jb4.2
repo sync

Create a local_manifests file with Cyanogenmods sources for our phone and kernel (thanks to Deck’s work). This is porting part.

mkdir ~/slimbean/.repo/local_manifests
echo ‘<?xml version="1.0" encoding="UTF-8"?>
<manifest>

<!-- CyanogenMod -->
<project name="CyanogenMod/android_device_htc_evita" path="device/htc/evita" remote="github" revision="cm-10.1" />
<project name="CyanogenMod/android_device_htc_s4-common" path="device/htc/s4-common" remote="github" revision="cm-10.1" />
<project name="CyanogenMod/android_device_htc_msm8960-common" path="device/htc/msm8960-common" remote="github" revision="cm-10.1" />
<project name="CyanogenMod/android_kernel_htc_msm8960" path="kernel/htc/msm8960" remote="github" revision="cm-10.1" />

<!-- Add HTC Proprietary Files -->
<project name="TheMuppets/proprietary_vendor_htc" path="vendor/htc" remote="github" revision="cm-10.1" />

<!-- Add qcom-caf source for our phone -->
<project path="hardware/qcom/media-caf" name="SlimRoms/hardware_qcom_media-caf" remote="github" revision="jb4.2" />
<project path="hardware/qcom/display-caf" name="SlimRoms/hardware_qcom_display-caf" remote="github" revision="jb4.2" />
<project path="hardware/qcom/audio-caf" name="SlimRoms/hardware_qcom_audio-caf" remote="github" revision="jb4.2" />

<!-- Add personal fixed bash -->
<remove-project name="SlimRoms/android_external_bash" />
<project path="external/bash" name="mikshepard/android_external_bash" remote="github" revision="cm-10.1" />

</manifest>’ > ~/slimbean/.repo/local_manifests/evita.xml

Sync the repo again

repo sync

Create your device file for Slimbean (adapted from CM’s cm.mk file):

echo '# Specify phone tech before including full_phone
$(call inherit-product, vendor/slim/config/gsm.mk)

# Release name
PRODUCT_RELEASE_NAME := evita

# Boot animation
TARGET_SCREEN_HEIGHT := 1280
TARGET_SCREEN_WIDTH := 720

# Inherit some common CM stuff.
$(call inherit-product, vendor/slim/config/common_full_phone.mk)

# Inherit device configuration
$(call inherit-product, device/htc/evita/device_evita.mk)

# Device naming
PRODUCT_DEVICE := evita
PRODUCT_NAME := slim_evita
PRODUCT_BRAND := htc
PRODUCT_MODEL := One X
PRODUCT_MANUFACTURER := HTC

# Set build fingerprint / ID / Product Name etc.
PRODUCT_BUILD_PROP_OVERRIDES += PRODUCT_NAME=htc_evita BUILD_FINGERPRINT=cingular_us/evita/evita:4.1.1/JRO03C/131981.6:user/release-keys PRIVATE_BUILD_DESC="3.18.502.6 CL

# Copy compatible prebuilt files
PRODUCT_COPY_FILES += \
vendor/slim/prebuilt/hdpi/bootanimation.zip:system/media/bootanimation.zip' > ~/slimbean/device/htc/evita/slim.mk

then create a vendorsetup.sh file

echo “add_lunch_combo slim_evita-userdebug” >> ~/device/htc/evita/vendorsetup.sh

now we build our environment:

. build/envsetup.sh

get a list of all devices:

lunch

Choose slim_evita-userdebug (it should be option 9), and then create your ROM:

make bacon

when finished, it’ll be located in ~/slimbean/out/target/product/evita/

NOTE: if using a multi-core processor use "make -jX bacon" where X = the number of cores you have. For my duel-core processor, I use "make -j2 bacon".

TIP:

If you are into building, checkout my acompile script in my signature, it'll email you when your build is complete using Gmail's snmp and will include the time it took and the last few lines of the output. I find it very useful for knowing when my build is done (especially since they take me about 3+ hours apiece)

SOURCES:

This page helped a lot with a great tutorial on building ROMS

This forum is filled with great people who others with the building of ROMS. A great source when you run into errors you don’t understand.

Hope this helps someone,

-Mike