Custom Recovery

Nov 8, 2010
5
0
0
So what is required to get a custom recovery for this phone? I know clockworkmod works on the Fascinate but doesn't work on the Mesmerize.
 
To quote Koush's site:

"Porting Clockwork Recovery to New Devices

This guide will assume you have some familiarity with doing an Android Build.
First, let's check out the CyanogenMod tree. The CyanogenMod repository contains Clockwork Recovery, which is part of a full Android build.

repo init -u git://github.com/CyanogenMod/android.git -b froyo
repo sync
make -j4 otatools

Now, use dump_image or dd to dump your recovery or boot image from a running phone and copy it to your computer somewhere.

dump_image boot boot.img

Note that dump_image only works on phones using MTD. You will need to use dd to dump mmc partitions.

To build Android from source for a new device, you need to set up a board config and its makefiles. This is generally a long and tedious process. Luckily, if you are only building recovery, it is a lot easier. From the root of your Android source directory (assuming you've run envsetup.sh), run the following (substituting names appropriately):

build/tools/device/mkvendor.sh device_manufacturer_name device_name /your/path/to/the/boot.img

You will receive the confirmation "Done!" if everything worked.
The mkvendor.sh script will also have created the following directory in your Android source tree:

manufacturer_name/device_name

Now, type the following:

lunch generic_device_name-eng

This will set the build system up to build for your new device.
Open up the directory in a file explorer or IDE. You should have the following files: AndroidBoard.mk, AndroidProducts.mk, BoardConfig.mk, device_.mk, kernel, system.prop, and vendorsetup.sh.The two files you are interested in are BoardConfig.mk and kernel. The kernel in that directory is the stock one that was extracted from the boot.img that was provided earlier. BoardConfig.mk will need to be tweaked to support ext mounts and their mount points.

For example, if your /data mount is ext and the device is /dev/block/mmcblk0p2, you would need the following lines added in your BoardConfig.mk:

BOARD_DATA_DEVICE := /dev/block/mmcblk0p2
BOARD_DATA_FILESYSTEM := auto
Once the BoardConfig.mk has been properly setup, you can build the recovery using:

make -j4 recoveryimage

Your recovery can then be found at $OUT/recovery.img.
If you are in need of building a fakeflash recovery, you will need to run the following to create the update.zip that hot replaces the recovery:

. build/tools/device/mkrecoveryzip.sh

Once this is done, build, and tested, notify me, "koush", on Github and I can build official releases and add ROM Manager support!

Tip: Run "make clobber" between builds if you change the BoardConfig.mk, or the change will not get picked up."
 
  • Like
Reactions: thescorpion420
Well I am familiar with building android so ill give it a shot. That's all I was looking for was a push in the right direction. Thanks!
 
Well I am familiar with building android so ill give it a shot. That's all I was looking for was a push in the right direction. Thanks!

The only problem that I'm seeing so far is that he's saying that we have to be running froyo. If that's the case, we might be waiting a few more weeks to a couple of months. The update should be out from Samsung by the end of the month but USCC might not let it push until they have a chance to test it fully first.
 
Eh I'm all about trying things out. I'm building a dev environment right now, hopefully I'll give it a test later tonight.
 
Sweet. Keep us informed. I know I'm working on borrowed time with all of the screwing around that I'm doing without a backup. lol
 
I too am in desperate need of a recovery and am not an expert with these things to make my own recovery anyone close?

Sent from my SCH-I500 using Tapatalk