[Sony Xperia Miro, Tipo (Dual), J, E] ShivangDave:
How to use Xperia J's ROM on Miro/Tipo/E OR Xperia Miro/Tipo/E's ROM on Xperia J:

The same steps will be applied here also, Still you need to edit some more things...

FOLLOW THE SAME 1-8 STEPS WHICH WE USED BEFORE.. THEN,

Patching framework:

Patching framework-res.apk:

Let's decompile both files..

1. Create folder and name it whatever you want, place there apktool. I will name that folder "X".

2. Copy CM10's framework-res.apk to "X" folder.

3. Decompile with this command:

apktool d framework-res.apk framework-res-CM

and after it finished, delete file framework-res.apk.

4. Copy framework-res.apk from ROM you're porting to "X" folder.

5. Decompile it with this command:

apktool d framework-res.apk

and after it finished, delete file framework-res.apk.

6. Now we have two folders:

- framework-res-CM

- framework-res

so we can recognize which one is from CM or PORT rom.

7. Go to given directory in both folders:

res/xml

copy and replace storage_list.xml from CM's to PORT's folder. (it's important when rom you are porting is from device that has different storage, so we need to use storage lists from CM10 that is for our device).

8. Now build pachted framework-res and of-course place compiled framework-res.apk to system/framework of our PORT.

apktool b framework-res framework-res.apk

Patching framework.jar:

1. Copy CM10's framework.jar to "X" folder.

2. Decompile with this command:

apktool d framework.jar framework-jar-CM

and after it finished, delete file framework.jar.

3. Copy framework.jar from ROM you're porting to "X" folder.

4 Decompile it with this command:

apktool d framework.jar

and after it finished, delete file framework.jar.

5. Now we have two folders:

- framework-jar-CM

- framework.jar.out

6. Now quick explanation. We are going to copy and replace files from CM's to PORT's framework.

If I say copy and replace xyz*.smali you have to copy and replace all smali files that start with xyz.

Is it clear? I hope so. Here is example from MIUI porting guide:

RIL*.smali means:
RIL.smali

RIL$1.smali

RIL$RILReceiver.smali

Let's start.

7. Copy and replace given files

android/view/Gles20*.smali (whole gles20 tree)
android/hardware/Camera*.smali (whole Camera tree)
android/server/BluetoothA2dpService*.smali
android/content/res/PackageRedirectionMap*.smali
com/android/internal/telephony/RIL*.smali (it is the most important part, copy all RIL files, and also files like:
HTCQualcommRIL.smali
LGEQualcommRIL.smali
LGEQualcommUiccRIL.smali
SamsungCDMAQualcommRIL.smali ... - all samsung files
SemcRIL.smali
SemcRIL$1.smali
SemcRIL$IccHandler.smali
SonyQualcommRIL.smali
SonyQualcommRIL7x27a.smali
)
android/bluetooth/HeadsetBase*.smali
com/android/internal/app/ActivityTrigger.smali
android/webkit/HTML5*.smali
android/webkit/SelectActionModeCallback
android\os\Environment.smali
android\os\SystemProperties.smali
smali\smali\android\view :
HardwareCanvas.smali
HardwareRenderer$Gl20Renderer.smali
HardwareRenderer$GlRenderer.smali
HardwareRenderer.smali

8. Now build pachted framework.jar and of courses place compiled framework.jar to system/framework of our PORT.

apktool b framework.jar.out framework.jar

NOTE:

YOU CAN USE THIS GUIDE TO PORT OTHER MANUFACTURER ROMS ALSO..

REPLACE SYSTEM/MEDIA AND SYSTEM/FRAMEWORK