[Sony Xperia T, TL, TX, V] WhiteNeo:
Maybe this will help someone.. :)

I'll be visiting this thread occasionally in case someone needs help. But I'd be glad if people and future devs also helped each other. :good:

If you compile a running build with these instructions, feel free to share it with people in this thread. Maybe development for these phones is not over yet! :fingers-crossed:

Soo.. Let's start!

What you need:

- Basic coding skills

- A GitHub account and some skills on how to use git.

- A computer with decent specs. (using an i5-4670k and 8gb ram here)

- LOTS of free storage. I recommend at least 100-200GB. The more, the better.

- A linux VM with all neccesary tools to build android. I recommend BBQLinux.

Initial Steps:

1. Grab the CM12.1 source by typing the following in your VM's Terminal:

mkdir cm12
cd cm12
repo init -u git://github.com/CyanogenMod/android.git -b cm-12.1
repo sync

This will take some hours. Just wait.

2. Create a file called roomservice.xml in /home/yourusername/cm12/.repo/local_manifests directory, containing the following:

<?xml version="1.0" encoding="UTF-8"?>
<manifest>
<remove-project name="CyanogenMod/android_bootable_recovery" />
<remove-project name="CyanogenMod/android_build" />
<remove-project name="CyanogenMod/android_external_bluetooth_bluedroid" />
<remove-project name="CyanogenMod/android_frameworks_av" />
<remove-project name="CyanogenMod/android_frameworks_base" />
<remove-project name="CyanogenMod/android_hardware_qcom_display" />
<remove-project name="CyanogenMod/android_libcore" />
<remove-project name="platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.8" />
<remove-project name="platform/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.8" />
<project name="ArchiDroid/Toolchain" path="prebuilts/gcc/linux-x86/arm/arm-eabi-4.8" remote="github" revision="architoolchain-4.9-arm-linux-gnueabihf-cortex_a9_neon" />
<project name="ArchiDroid/Toolchain" path="prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.8" remote="github" revision="sabermod-4.9-arm-linux-androideabi" />
<project name="CyanogenMod/android_device_sony_common" path="device/sony/common" remote="github" />
<project name="CyanogenMod/android_device_qcom_common" path="device/qcom/common" remote="github" />
<project name="CyanogenMod/android_hardware_sony_DASH" path="hardware/sony/DASH" remote="github" revision="cm-12.1" />
<project name="CyanogenMod/android_kernel_sony_msm8x60" path="kernel/sony/msm8x60" remote="github" />
<project name="WhiteNeo-/android_bootable_recovery" path="bootable/recovery" remote="github" revision="android-5.1" />
<project name="WhiteNeo-/android_build" path="build" remote="github" revision="cm-12.1" />
<project name="WhiteNeo-/android_external_bluetooth_bluedroid" path="external/bluetooth/bluedroid" remote="github" revision="cm-12.1" />
<project name="WhiteNeo-/android_frameworks_av" path="frameworks/av" remote="github" revision="cm-12.1" />
<project name="WhiteNeo-/android_frameworks_base" path="frameworks/base" remote="github" revision="cm-12.1" />
<project name="WhiteNeo-/android_hardware_qcom_display" path="hardware/qcom/display-caf/msm8960" remote="github" revision="cm-12.1-caf-8960" />
<project name="WhiteNeo-/android_libcore" path="libcore" remote="github" revision="cm-12.1" />
<project name="WhiteNeo-/android_device_sony_blue-common" path="device/sony/blue-common" remote="github" revision="cm-12.1" />
<project name="WhiteNeo-/android_device_sony_mint" path="device/sony/mint" remote="github" revision="cm-12.1" />
<project name="WhiteNeo-/android_device_sony_hayabusa" path="device/sony/hayabusa" remote="github" revision="cm-12.1" />
<project name="WhiteNeo-/android_device_sony_msm8960-common" path="device/sony/msm8960-common" remote="github" revision="cm-12.1" />
<project name="WhiteNeo-/android_device_sony_tsubasa" path="device/sony/tsubasa" remote="github" revision="cm-12.1" />
<project name="WhiteNeo-/kernel-msm" path="kernel/sony/msm8960" remote="github" revision="master" />
<project name="WhiteNeo-/proprietary_vendor_sony" path="vendor/sony" remote="github" revision="cm-12.1" />
</manifest>

3. Find all the lines containing "WhiteNeo-", fork those repositories at GitHub and replace "WhiteNeo-" with your GitHub name. (Important!)

Then copy the related repositories to your local drive with the "git clone" command.

4. Some sources are still old and need to be updated before we start to compile. These are:

android_bootable_recovery

android_build

android_external_bluetooth_bluedroid

android_frameworks_av

android_frameworks_base

android_hardware_qcom_display

android_libcore

These sources have to be updated like the example below.

Just remember that not all branches are named cm-12.1, so replace "cm-12.1" with the revision from roomservice.xml (look above)

cd android_build
git pull https://github.com/CyanogenMod/android_build.git cm-12.1
git push https://github.com/WhiteNeo-/android_build.git cm-12.1

The recovery sources are updated differently:

cd android_bootable_recovery
git pull https://github.com/omnirom/android_bootable_recovery.git android-5.1
git push https://github.com/WhiteNeo-/android_bootable_recovery.git android-5.1

5. Once more do a repo sync in your cm12 directory, to synchronize our updated repositories with the ones in CM12 directory.

6. Start the build with the following terminal commands:

cd cm12
. build/envsetup.sh
brunch yourdevicename

(Replace "yourdevicename" with your phone's manufacturer name: tsubasa = Xperia V // mint = Xperia T // hayabusa = Xperia TX)

If there are no issues, you'll find the finished ROM zip in cm12/out/target/product/yourdevicename directory.

Copy the META-INF folder from my latest NEO build over to the new zip and flash. Done. :)

Future builds:

Just repeat steps 4 to 6.

Troubleshooting:

If you run into toolchain errors, grab the libraries from the following link and install them in your virtual machine.

http://sabermod.com/Prebuilt-libs (DEV ONLY)/ROM-Kernel/