Remove All Ads from XDA

[TUTORIAL] How to integrate a custom recovery into your custom ROM

2,130 posts
Thanks Meter: 5,447
By DaRk-L0rD, Senior Member on 13th March 2014, 11:20 PM
Post Reply Email Thread

Hello everyone

In this tutorial i will show you how to integrate the recovery into a custom rom.
This way users will not have to install it separately

  • You must know how to build a custom rom using Android Kitchen.
  • You must know how to edit an updater-script using Notepad++.
  • The WORKING folder of your rom (the one you get from the android kitchen when you extract system.img or zip folder or system.tar).
  • The recovery's flashable zip.

For this tutorial i am gonna use the PhilZ Touch CWM as example but this method is universal for all recoveries.

So, let's start:

1. Create in the kitchen's WORKING folder, a new folder and name it system2 (in your case working folder's name is gonna be different).

2. Extact the recovery's system folder contents into the system2 folder (the one previously created).

3. From the recovery's META-INF folder open, using Notepad++, the updater-script.

In my case looks like this:

4. Before proceeding, let me explain what is going on with the following lines:

package_extract_file("system/bin/recovery.tar", "/system/bin/recovery.tar");
package_extract_file("system/bin/taimport", "/system/bin/taimport");
package_extract_file("system/bin/taimportx", "/system/bin/taimportx");
package_extract_dir("system/btmgr", "/system/btmgr");

----- package_extract_dir(” “, “/”) – This command extracts all the files from the folder mentioned inside first quotation to the directory inside second quotation. -----

So since you created a new folder named system2, the above lines should be edited and look like this:

package_extract_file("system2/bin/recovery.tar", "/system/bin/recovery.tar");
package_extract_file("system2/bin/taimport", "/system/bin/taimport");
package_extract_file("system2/bin/taimportx", "/system/bin/taimportx");
package_extract_dir("system2/btmgr", "/system/btmgr");

5. Now open, using Notepad++, the updater-script for your rom.

6. Now copy the edited lines from the recovery's updater-script into the updater-script of your rom (add them at the bottom). Remove the show_progress lines. Now save the file.

7. Now you can build your rom and enjoy the integrated recovery!

8. Happy rom building
The Following 28 Users Say Thank You to DaRk-L0rD For This Useful Post: [ View ] Gift DaRk-L0rD Ad-Free
13th March 2014, 11:21 PM |#2  
DaRk-L0rD's Avatar
OP Senior Member
Thanks Meter: 5,447
The Following User Says Thank You to DaRk-L0rD For This Useful Post: [ View ] Gift DaRk-L0rD Ad-Free
14th March 2014, 02:34 AM |#3  
dipesh1502's Avatar
Senior Member
Flag MUMbai
Thanks Meter: 3,839
Donate to Me
Too good
So you are back with your pc i guess:P
14th March 2014, 05:45 AM |#4  
headache59's Avatar
Senior Member
Thanks Meter: 78
Awesome! Definitely looks much, much better than the "ms-dos" clone I see in my device
14th March 2014, 03:45 PM |#5  
Pandemic's Avatar
Senior Member
Flag Meppel
Thanks Meter: 23,132
Donate to Me
Bro @DaRk-L0rD
Very nice and very clear explained, specially for new ones
15th March 2014, 04:55 AM |#6  
serajr's Avatar
Recognized Developer / Recognized Themer
Flag Rafard - SP
Thanks Meter: 18,490
Donate to Me
Very clever tutorial my friend!!
keep rocking...
The Following 2 Users Say Thank You to serajr For This Useful Post: [ View ]
16th March 2014, 08:18 AM |#7  
sandy7's Avatar
Inactive Recognized Developer
Flag bangalore
Thanks Meter: 6,932
Donate to Me
Nice guide..

U are featured on portal. Congrats

Sent from my C5303 using XDA Premium 4 mobile app
The Following User Says Thank You to sandy7 For This Useful Post: [ View ] Gift sandy7 Ad-Free
16th March 2014, 05:25 PM |#8  
josephnero's Avatar
Senior Member
Flag Sanford NC
Thanks Meter: 712
Congratz bro.your post is on portal.nice job
The Following User Says Thank You to josephnero For This Useful Post: [ View ] Gift josephnero Ad-Free
17th July 2014, 06:07 PM |#9  
Dickey Kid'deviel's Avatar
Senior Member
Thanks Meter: 173
Great, its work for me!
Post Reply Subscribe to Thread

build rom, custom rom, kitchen rom, recovery, xperia
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes