[XPERIA X10 Android Development] x10forevers:
Vendor tree modification for Xperia X10

- All vendor setup will be made to the local directory in your WORKING_DIRECTORY/Vendor

4A: Slimroms Vendor Setup​

- Go to vendor/slim to your local directory

- Here you only need to edit one file and that file is vendorsetup.sh

- Open vendorsetup.sh with text editor and just add this line to the end of the file

add_lunch_combo slim_es209ra-userdebug

- Save file and you are ready to go with Step 3F

4B: Vendor Setup for MoKee OpenSource​

- Go to vendor/mk to your local directory

- Here you have to edit 1 file and that file is mokee-build-targets

- Open mokee-build-targets with text editor and just add this line to the end of the file

mk_es209ra-userdebug

- Save file and you are ready to go with Step 3F

4C: Vendor Setup For Paranoid Android​

- Go to vendor/pa to your local directory

- Here you need to edit files in packages, Products, vendorprops and vendorsetup.sh

Step-1

So, First we are going to add file in vendor/pa/packages, so go to vendor/pa/packages

- Here we are adding torch to our package

- Right click and create a blank document and name it as es209ra.mk and copy paste this content.

# Extra packages
PRODUCT_PACKAGES += \
Torch

Step 2

Now go to vendor/pa/products

- Here we have to add product file for our device

- Open AndroidProducts.mk file with text editor and following lines at the end

ifeq (pa_es209ra,$(TARGET_PRODUCT))
PRODUCT_MAKEFILES += $(LOCAL_DIR)/pa_es209ra.mk
endif

- Right click and create a blank document and name it as pa_es209ra.mk

- Copy Paste following details in that file

# Copyright (C) 2012 ParanoidAndroid Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# Check for target product
ifeq (pa_es209ra,$(TARGET_PRODUCT))

# Define PA bootanimation size
PARANOID_BOOTANIMATION_NAME := HDPI

# OVERLAY_TARGET adds overlay asset source
OVERLAY_TARGET := pa_hdpi

# Build paprefs from sources
PREFS_FROM_SOURCE ?= false

# Include ParanoidAndroid common configuration
include vendor/pa/config/pa_common.mk

# Inherit AOSP device configuration
$(call inherit-product, device/semc/es209ra/full_es209ra.mk)

# Product Package Extras
-include vendor/pa/packages/es209ra.mk

# Override AOSP build properties
PRODUCT_NAME := pa_es209ra
PRODUCT_BRAND := semc
PRODUCT_MODEL := es209ra
PRODUCT_MANUFACTURER := Sony Ericsson
PRODUCT_BUILD_PROP_OVERRIDES += PRODUCT_NAME=LT18i BUILD_FINGERPRINT="SEMC/LT18i_1254-2184/LT18i:4.0.4/4.1.B.0.431/UL5_3w:user/release-keys" PRIVATE_BUILD_DESC="LT18i-user 4.0.4 4.1.B.0.431 UL5_3w test-keys"

# Update local_manifest.xml
GET_VENDOR_PROPS := $(shell vendor/pa/tools/getvendorprops.py $(PRODUCT_NAME))
GET_PROJECT_RMS := $(shell vendor/pa/tools/removeprojects.py $(PRODUCT_NAME))
GET_PROJECT_ADDS := $(shell vendor/pa/tools/addprojects.py $(PRODUCT_NAME))

endif

Step 3

- Edit vendosetup.sh file

- Go to vendor/pa and vendorsetup.sh with text editor

- Copy Paste followinfg lines at the end of that file

add_lunch_combo pa_es209ra-userdebug

- Now you are ready to go with step 3F

4D: Vendor Setup For PAC-Man​

- Here we have to edit files in vendor/pac

- We have to edit files of products and vendorsetup.sh

Step 1

- Go to vendor/pac/products

- Right click and create blank document and name it as pac_es209ra.mk

- Copy paste following content to that file

# Check for target product
ifeq (pac_es209ra,$(TARGET_PRODUCT))

# OVERLAY_TARGET adds overlay asset source
OVERLAY_TARGET := pa_hdpi

# PAC device overlay
PRODUCT_PACKAGE_OVERLAYS += vendor/pac/overlay/pac/hdpi_480x800
$(shell cp -f vendor/pac/prebuilt/common/bootanimation_framework/android-logo-mask_sony-hdpi.png frameworks/base/core/res/assets/images/android-logo-mask.png)

# PAC boot logo
PRODUCT_COPY_FILES += \
vendor/pac/prebuilt/common/bootlogo/pac_logo_480x800.rle:root/logo.rle

# Copy bootanimation
PRODUCT_COPY_FILES += \
vendor/pac/prebuilt/hdpi/bootanimation.zip:system/media/bootanimation.zip

# include PAC common configuration
include vendor/pac/config/pac_common.mk

# Inherit CM device configuration
$(call inherit-product, device/semc/es209ra/cm.mk)

PRODUCT_NAME := pac_es209ra

# Update local_manifest.xml
GET_PROJECT_RMS := $(shell vendor/pac/tools/removeprojects.py $(PRODUCT_NAME))
GET_PROJECT_ADDS := $(shell vendor/pac/tools/addprojects.py $(PRODUCT_NAME))

Step 2

- Edit vendosetup.sh file

- Go to vendor/pa and vendorsetup.sh with text editor

- Copy Paste followinfg lines at the end of that file

# Xperia 2010
add_lunch_combo pac_es209ra-userdebug

- Now you are ready to go with step 3F​