[GUIDE] How to port ROMS - Android Software Development

I know that there are actually LOTS of "How to port ROMS" in this forum now.. but I would like to share a certain source I found that is actually fool proof
Here it goes!
find a ROM that is designed for the same CPU type and the same phone manufacturer. Any stock Gingerbread, ICS, or CyanogenMod 7/9 ROM should work, but you’ll have to make sure your phone can handle the ROM – no ICS for an HTC Hero, for example. Also, your Port ROM's original Phone should have the same RESOLUTION with that of your phone's.
You will need:
**Notepad++
**a compression program (WinZip or 7zip and etc)
**the ROM you want to port to your phone (let’s call it the "Port ROM")
**a ROM designed for your phone (let’s call it"Base ROM")
Click to expand...
Click to collapse
This guide may mention some files or directories that aren’t present in your particular ROM; don’t worry, just carry on.
On your PC, extract the .ZIP files containing the two ROMs, and navigate to /system/app in your extracted Port ROM and copy stk.apk, vpnservices.apk, camera.apk, and bluetooth.apk into a temporary directory somewhere else on your PC.
Click to expand...
Click to collapse
Now, delete the following folders from your Port ROM and replace them with the ones from your Base ROM: /data, /system/app, /system/framework, /system/fonts and /system/media.
Click to expand...
Click to collapse
From your Base ROM, copy /system/lib/libandroid_runtime.so to the system/lib/ directory of your Port ROM, overwriting the file.
Click to expand...
Click to collapse
Next up, move the .APKs you copied earlier back into the /system/app directory of your Port ROM.
Click to expand...
Click to collapse
Open up /system/lib in your Port ROM and copy all the files and folders. Paste them into the Base’s /system/lib directory, replacing all. Then go back to the Port ROM and delete the /system/lib folder, and replace it with the /system/lib folder from the Base ROM.
Click to expand...
Click to collapse
Next, navigate to the /system/etc/init.d folder in the Port ROM and do the same copy-from-Port, paste-to-Base, delete-from-Port, copy-from-Base, paste-to-Port shuffle as before.
Click to expand...
Click to collapse
Navigate to /system/etc/permissions and do that same copy-paste dance one more time.
Click to expand...
Click to collapse
open system/build.prop from both the port and the base ROM in Notepad++. Update the Base build.prop to match the values for “ro.build.description=” and “ro.build.fingerprint=” from your Port. Now save the Base build.prop, exit Notepad++, and copy the Base build.prop into the Port ROM, overwriting the Port build.prop.
Click to expand...
Click to collapse
In Notepad++, open \META-INF\com\google\android\updater-script from both your base and port ROMs. Edit the Port’s script to be like the Base’s updater-script: specifically, change, edit, or add the sections for permissions, ui_prints, asserts, run_programs, and installing the kernel. Don’t change any of the symlinks. In the Port script, make sure that the ‘format’ values are appropriate for your device (compare them to the Base script).
Click to expand...
Click to collapse
Finally, make sure that your kernel is specifically for your device.
Click to expand...
Click to collapse
Now, if you desire, you can update any apps you require, or add any tools like BusyBox or SuperSU.
And that’s it! Your base ROM is now ready to be zipped and installed on your device via Clockwork Mod!
SOURCE: http://apcmag.com/port-roms-to-your-android-device.htm
ADDITIONAL INFORMATION:
CUSTOM ROM FOLDERS EXPLAINED
List of Resolution for Smartphones
How to change Kernel of ROM Before installation in its zip file.
[GUIDE][How to Make CWM Recovery Flashable Zip file without Computer]

copy - paste, easy made. nice guide, thanks

30adi said:
copy - paste, easy made. nice guide, thanks
Click to expand...
Click to collapse
Yes but i found the source highly confusing i just "cleaned it up"
Sent from my GT-I9300 using xda premium

Very good job, thank you.

ADDED:
[GUIDE][How to Make CWM Recovery Flashable Zip file without Computer]

I port a ROM but I am getting unknown baseband no imei please tell me how to fix

khan_frd2002 said:
I port a ROM but I am getting unknown baseband no imei please tell me how to fix
Click to expand...
Click to collapse
go to build.prop in /system and edit rild.libpath=
rild.libargs=
to match your device and that should fix it

your guide was just copied by a person from One V forums without giving proper credits.
see here: here

1ceb0x said:
your guide was just copied by a person from One V forums without giving proper credits.
see here: here
Click to expand...
Click to collapse
I see.. he should've given proper credits to the website
Sent from my GT-I9300 using xda premium

changing lib path in buildprob
not work

erm hello, can you put the other guides in your OP? some are in your other posts and it would not be easy for others to see..
nice guide and gonna try this when i got time
:good:

kemaro30 said:
erm hello, can you put the other guides in your OP? some are in your other posts and it would not be easy for others to see..
nice guide and gonna try this when i got time
:good:
Click to expand...
Click to collapse
What "other" guides do you mean?
Sent from my GT-I9300 using xda premium

Hello I Wanted to port Cm7 On a New cpu named as - MediaTek 6573 ! it is an armv6 one ... any suggestions from where to start ....etc ?

I will definitely give this a try.

Great guide. Subscribed!!

ChummyDays said:
Okay, question: what is the point of porting a ROM made for a device with the same CPU and same manufacturer?? there is VERY few phones that are made by the same company and the same cpu!
Click to expand...
Click to collapse
Well that is to ensure "safety" when porting a ROM.. the guide i posted was a beginner's guide on how to port.. as you can see, almost 80% of the procedure is just basically copy&paste..
however, if you have a good background now in codes and porting things, i believe you may not follow step-by-step the procedures i stated above.
Sent from my GT-I9300 using xda premium

mandeep1 said:
Hello I Wanted to port Cm7 On a New cpu named as - MediaTek 6573 ! it is an armv6 one ... any suggestions from where to start ....etc ?
Click to expand...
Click to collapse
Search for other phones with similar cpu
Sent from my GT-I9300 using xda premium

What about dual Sim ph?

Does anyone have any idea what would cause a "Modem Crashed Forced Upload Mode" on a port for SGS3?
I can't seem to pinpoint what causes that (I think it's a kernel panic but I could be wrong)

Looks like this would work on International Note 2 and Tmobile Note 2. They have the exact same hardware and everything. I was wondering about the last statement about kernel. Can't I just copy the boot.img from tmobile note 2 to international note 2 ? would that work ? I am not familiar with kernels and stuff. Need advice.
Thanks

Related

[Q] how to change ROM

I have read through this entire forum, just to find out that it seems nearly impossible to change ROM on our SG3. So could someone please give a detailed step by step explanation how to change ROM on the SG3?
Chickendude said:
I have read through this entire forum, just to find out that it seems nearly impossible to change ROM on our SG3. So could someone please give a detailed step by step explanation how to change ROM on the SG3?
Click to expand...
Click to collapse
Depends on which ROM you want to flash!
Chickendude said:
I have read through this entire forum, just to find out that it seems nearly impossible to change ROM on our SG3. So could someone please give a detailed step by step explanation how to change ROM on the SG3?
Click to expand...
Click to collapse
Its not impossible. . Before flashing, make a backup of the efs partition. For that you need to be rooted. Rooting guide here.
Then backup efs partition. It contains your IMEI. Guide here.
Then the basics of flashing. Flashing guide here.
Apart from these, you also have to follow some other instructions that ROM developers provide for their ROMs.
Thanks, but most of the ROMs I have are .zip files, instead of .tar, so how can I convert those?
Sent from my GT-I5800 using XDA App
Chickendude said:
Thanks, but most of the ROMs I have are .zip files, instead of .tar, so how can I convert those?
Sent from my GT-I5800 using XDA App
Click to expand...
Click to collapse
Which ROM do you have. Do mention the version number also.
Chickendude said:
Thanks, but most of the ROMs I have are .zip files, instead of .tar, so how can I convert those?
Sent from my GT-I5800 using XDA App
Click to expand...
Click to collapse
Are you talking about an "update.zip"? Thats just a Package to update the ROM you already have. To do this :
1) Paste the update.zip in your sdcard
2) Reboot into Recovery (Press and Hold Volume Up + Volume Down + Menu Key + Power Button )
3) Select "Apply sdcard:update.zip"
4) Reboot
For doing this, you need to have the whole ROM already installed in your phone. And that will come in a tar package (.tar file).
Flash it using Odin as One Package. And then apply update.zip.
Chickendude said:
Thanks, but most of the ROMs I have are .zip files, instead of .tar, so how can I convert those?
Sent from my GT-I5800 using XDA App
Click to expand...
Click to collapse
Silly question but....did you try to UNZIP the roms after you downloaded them?
Peace...
Sent from my lestatious 2.0 nokia 3210
Yes, I tried, so most likely the ROM is corrupt, but is it also possible to change ROM without using Odin, because Odin doesn't recognise the .ops file?
dhirend_6d said:
Which ROM do you have. Do mention the version number also.
Click to expand...
Click to collapse
So far, I have still got the standard ROM, but I am trying to get Kyrrilos on my phone.
Chickendude said:
Yes, I tried, so most likely the ROM is corrupt, but is it also possible to change ROM without using Odin, because Odin doesn't recognise the .ops file?
Click to expand...
Click to collapse
No. You have to use ODIN to flash. And the .ops(apollo_0531.ops) you have to select it says "SELECT OPS".
Chickendude said:
So far, I have still got the standard ROM, but I am trying to get Kyrrilos on my phone.
Click to expand...
Click to collapse
Oh Kyrillos' ROM!!
For that first you have to download v5.5. There are 2 parts. Download them both in one folder. Then extract only 1st part. Second part will get extracted automatically. You ll then have a .tar file. Then remove SIM and SD. ollow Kyrillos' instructions. Flash and done.
Or perhaps miuiwiz
Sent from my GT-I5800 using XDA App

[TOOLKIT][LINUX]MIUI Rom Porter

MIUI ROM Porter
About the tool:
This tool is based on rishab.raj37's great guide. And makes porting MIUI ROMs in few simple clicks. This is made only for linux.
Click to expand...
Click to collapse
How to use it:
1. Download the tool zip from here.
2. Extract the zip and place the script.sh, build and up file and your ROM zips in the home directory (~/) (home/username).
3. Now open the terminal and type the following:
Code:
./port.sh
In some cases this might not work so try this:
Code:
bash ~/port.sh
4. Now follow the on-screen instructions and done. :good:
5. You can find your ported ROM in ~/PORT/ directory.
6. Enjoy and press THANKS.
Click to expand...
Click to collapse
Note:
If you get stuck on bootloop, try this tool, here.
Click to expand...
Click to collapse
Credits:
rishab.raj37- For such a great guide
ME
Click to expand...
Click to collapse
hey what it exactly do?
I tried to have fun with patchrom but have too old laptop ( has not enough ram ).
So it just copying all the files or also patching frameworks?
You know what I mean. That we need the same manufacturer rom with the same base not?
For example rom is based on cm10 and I want to port to base AOSP. So will this work or not?
lsander said:
hey what it exactly do?
I tried to have fun with patchrom but have too old laptop ( has not enough ram ).
So it just copying all the files or also patching frameworks?
You know what I mean. That we need the same manufacturer rom with the same base not?
For example rom is based on cm10 and I want to port to base AOSP. So will this work or not?
Click to expand...
Click to collapse
Nopes that's the main prob for now...framework editing is not possible through this script thus u will have to urself patch the framework
Press THANKS if I helped,
Best Regards,
AJ
alokbina is now Abhinav2
Abhinav2 said:
Nopes that's the main prob for now...framework editing is not possible through this script thus u will have to urself patch the framework
Press THANKS if I helped,
Best Regards,
AJ
alokbina is now Abhinav2
Click to expand...
Click to collapse
I have the same Q,but THX~
Sent from my EVO using xda premium
Can i use a base rom that works on my i9505 and a i9500 newer miui version to port ?

Help abut android kitchen

Hello everyone
i want to know that if we make a rom through
dsixda's android kitchen
will it work on galaxy y
because the main page says something about a yaffs file system
abhishekr700 said:
Hello everyone
i want to know that if we make a rom through
dsixda's android kitchen
will it work on galaxy y
because the main page says something about a yaffs file system
Click to expand...
Click to collapse
yes it will
all you need to do is change the update binary and updater script with one from our phone in the final rom zip kitchen generates after building
marcussmith2626 said:
yes it will
all you need to do is change the update binary and updater script with one from our phone in the final rom zip kitchen generates after building
Click to expand...
Click to collapse
But I used a stock rom of my device
Not sure if it had update script or updater script
Do I still need another updater script
abhishekr700 said:
But I used a stock rom of my device
Not sure if it had update script or updater script
Do I still need another updater script
Click to expand...
Click to collapse
heres mine unzip attachment for stock based roms - you just need to edit the wording and use the symlinks from the one kitchen generates
there are guides to using kitchen if you need further help
marcussmith2626 said:
heres mine unzip attachment for stock based roms - you just need to edit the wording and use the symlinks from the one kitchen generates
there are guides to using kitchen if you need further help
Click to expand...
Click to collapse
can u pplease give me detailed instructions
and tell me why i cant use the kitchen's update script
marcussmith2626 said:
heres mine unzip attachment for stock based roms - you just need to edit the wording and use the symlinks from the one kitchen generates
there are guides to using kitchen if you need further help
Click to expand...
Click to collapse
can u pplease give me detailed instructions
and tell me why i cant use the kitchen's update script
abhishekr700 said:
can u pplease give me detailed instructions
and tell me why i cant use the kitchen's update script
Click to expand...
Click to collapse
because you will most likely get status 0 error when you flash it in cwm or error 6 or 7
please search for any guides you require
read this for starters
http://forum.xda-developers.com/showthread.php?t=1801690
marcussmith2626 said:
because you will most likely get status 0 error when you flash it in cwm or error 6 or 7
please search for any guides you require
read this for starters
http://forum.xda-developers.com/showthread.php?t=1801690
Click to expand...
Click to collapse
no detail instruction about symlinks
abhishekr700 said:
no detail instruction about symlinks
Click to expand...
Click to collapse
no
detailed instructions about symlinks
abhishekr700 said:
no
detailed instructions about symlinks
Click to expand...
Click to collapse
kitchen creates the symlinks for you
you only have to edit the mount points that are above the symlinks
compare with other updater scripts for this phone
flash it and you will see if it needs to be changed

[SM-T700]Edify Definition file for Dsixda's Kitchen

I decided to use Dsixda's kitchen, so I made the file for the Tab S 8.4 Wi-Fi (Klimtwifi).
Here it is. Try it, I think it was correctly made.
Mirror: https://www.androidfilehost.com/?fid=95887005526786375
What is it?
Dsixda's kitchen includes support for several devices, but that list is no longer updated. Meaning, you'd have to set the file up yourself. Dsixda's kitchen must know what are the partitions, the file systems, etc. This file says where the mount points are, for example. Just drag the "klimtwifi" to the /kitchen/tools/edify_defs directory, and you now the kitchen knows how to make the Updater Script for your device.
gnmmarechal said:
Dsixda's kitchen includes support for several devices, but that list is no longer updated. Meaning, you'd have to set the file up yourself. Dsixda's kitchen must know what are the partitions, the file systems, etc. This file says where the mount points are, for example. Just drag the "klimtwifi" to the /kitchen/tools/edify_defs directory, and you now the kitchen knows how to make the Updater Script for your device.
Click to expand...
Click to collapse
Hi, can you perhaps make one for the SM-T800? Just tell me what you need Thanks!
-DUHA
DUHAsianSKILLZ said:
Hi, can you perhaps make one for the SM-T800? Just tell me what you need Thanks!
-DUHA
Click to expand...
Click to collapse
Sure, I can try. I will only need the stock ODIN firmware (which I can get myself) I'll have time to look into it this weekend.
gnmmarechal said:
Sure, I can try. I will only need the stock ODIN firmware (which I can get myself) I'll have time to look into it this weekend.
Click to expand...
Click to collapse
Here are some mirrored T800 firmwares if you need them http://forum.xda-developers.com/showthread.php?p=58633854
Thank you very much!
-DUHA
DUHAsianSKILLZ said:
Here are some mirrored T800 firmwares if you need them http://forum.xda-developers.com/showthread.php?p=58633854
Thank you very much!
-DUHA
Click to expand...
Click to collapse
K. I'll look at them when I have the chance, maybe tomorrow.

[REQUEST] Smaller Navbar

Anyone know of a working smaller navbar mod (not using xposed) that works on MHC19I ? or able to point me in the direction of guide that allows me to attempt to make one myself ?
Looking to stay stock+rooted, rather than a custom rom.
TIA
EDIT - I've modified framework-res.apk for MHC19I - Grab it here. Mod changes navbar to 24 instead of 48 height.
* Backup your original /system/framework-res.apk and replace it with the download.
I'd recommend to flash resurrection remix rom where you can set the navbar to 24dp.
snachez said:
Anyone know of a working smaller navbar mod (not using xposed) that works on MHC19I ? or able to point me in the direction of guide that allows me to attempt to make one myself ?
Looking to stay stock+rooted, rather than a custom rom.
TIA
Click to expand...
Click to collapse
U can make it by editing framework-res.apk
Decompile framework-res.apk then go to res/values/dimens.xml there u can change it.
Rajeev said:
U can make it by editing framework-res.apk
Decompile framework-res.apk then go to res/values/dimens.xml there u can change it.
Click to expand...
Click to collapse
Thanks, I'll give it a shot !
snachez said:
Thanks, I'll give it a shot !
Click to expand...
Click to collapse
So I've decompiled and made the edit, recompiled and signed the apk, pushed it to my device and replaced the original.. but now it just sits on the bootup logo animination and I cant get past that stage.
Hopefully you have a backup that you can restore. If not, push the stock framework via adb
snachez said:
So I've decompiled and made the edit, recompiled and signed the apk, pushed it to my device and replaced the original.. but now it just sits on the bootup logo animination and I cant get past that stage.
Click to expand...
Click to collapse
U have done something wrong.. Which apktool u used to edit ?
Rajeev said:
U have done something wrong.. Which apktool u used to edit ?
Click to expand...
Click to collapse
I used apktool 2.0.3 from https://bitbucket.org/iBotPeaches/apktool/downloads/apktool_2.0.3.jar
Signed with tool from http://forum.xda-developers.com/showthread.php?t=2723579
Many thanks for any advice
snachez said:
I used apktool 2.0.3 from https://bitbucket.org/iBotPeaches/apktool/downloads/apktool_2.0.3.jar
Signed with tool from http://forum.xda-developers.com/showthread.php?t=2723579
Many thanks for any advice
Click to expand...
Click to collapse
Aww yuss. I followed a different guide from http://forum.xda-developers.com/showthread.php?t=1814441 and found I was missing a few steps (copying the META-INF etc)
Much success now.
For anyone interested, I've posted a modded framework-res.apk in OP... Flashable Zip my next project.
snachez said:
Aww yuss. I followed a different guide from http://forum.xda-developers.com/showthread.php?t=1814441 and found I was missing a few steps (copying the META-INF etc)
Much success now.
For anyone interested, I've posted a modded framework-res.apk in OP... Flashable Zip my next project.
Click to expand...
Click to collapse
Glad u made it dude.. Enjoy. Feel free to ask any helps

Categories

Resources