Droid 2 Deodex and Zip Aligned System & Framework Files

Search This thread
A

Angdroid

Guest
This is the stock Droid2 System and Framework files deodexed and zip aligned. This first of two packages that contains my Black (HTC) Status Bar Theme that looks like this. The next package will be the stock Droid2 deodexed and zip aliagned with stock status bar.

D2-Theme-Black.png

StockDroid2.png

( Picture from my Droid2 Theme for Droid 1. Status bar is exactly the same. Too lazy to update pic :) )​


It contains all original Droid2 files so if you have renamed or removed files it will replace them. This includes all Droid2 widgets and bloatware. If you have removed or renamed files then you can rename or remove the files from the app folder you placed on your memory card so you do not have to go back after install to clean up.​

A couple of apk files have been modified so the status icon matches status bar better. I still need to fix up a few more apk files and will post them as an update.zip file.​

I will have a update.zip file soon so it can be installed with clockwork. If you would like to test it for me please message me to let me know.​

Root Privilege:
You must have Root Access to install the files.
Check this thread and this thread on how to root your phone.​

ADB:
You also need to have The Android SDK installed so you can use adb commands.​

Clockwork Recovery:
Download from Android Market or check here and make donation after you download.​



Install Instructions - Recommended Method - Command Line:
Prep
Download the archive from above, extract file to your compter. Place app and framework folders from archive on the root of your sd card (/sdcard/app /sdcard/framework).​

Make sure your phone is plugged into the USB cable and PC Mode is selected and that you have debugging enalbed on the phone application settings.​

Open DOS prompt and type the following commands or paste them at the DOS prompt.
adb shell
su
stop
mount -o rw,remount -t ext3 /dev/block/mmcblk1p21 /system
cp /sdcard/app/* /system/app/
cp /sdcard/framework/* /system/framework/
rm /system/app/*.odex
rm /system/framework/*.odex
mount -o ro,remount -t ext3 /dev/block/mmcblk1p21 /system
reboot​

Install Instructions - Clockwork:
Coming Soon!​

After reboot it will take a few minutes too boot up so be patient. Your phone has not hung on boot unless the droid eye stops moving.​

Launcherpro:
Download themed LauncherPro 0.7.9.0 here.
Extract the com.fede.launcher.apk file and place on root of SD Card.
Make sure your phone is in PC Mode and Debugging is enalbed in Applications settings on phone.
Open command prompt on pc and type following commands.
adb shell
su
stop
mount -o rw,remount -t ext3 /dev/block/mmcblk1p21 /system
cp /sdcard/com.fede.launcher.apk /system/app/
mount -o ro,remount -t ext3 /dev/block/mmcblk1p21 /system
reboot​
 
Last edited:
A

Angdroid

Guest
Looking forward to the clockwork package. This is the mod I've been waiting for.

Go with the command line for now. Having adb will be better in the long run and have to figure out how to write a script for update.zip to delete all the odex files when installing from clockwork.
 

Natty_lite

Senior Member
Feb 21, 2008
73
0
I think its worth noting that your phone needs to be in PC Mode when plugging it in, with debugging on. If your in mass storage, it won't work because adb won't be able to access the sdcard while its mounted on the computer. These commands should also work via Android Terminal, although I imagine it's easier copying and pasting with a mouse and keyboard.

I know this may be obvious to some, but when you have people not knowing what they're doing in the first place, they assume that certain instructions were omitted intentionally.
 
A

Angdroid

Guest
I think its worth noting that your phone needs to be in PC Mode when plugging it in, with debugging on. If your in mass storage, it won't work because adb won't be able to access the sdcard while its mounted on the computer. These commands should also work via Android Terminal, although I imagine it's easier copying and pasting with a mouse and keyboard.

I know this may be obvious to some, but when you have people not knowing what they're doing in the first place, they assume that certain instructions were omitted intentionally.

Thanks! It's there under the install instructions.
 

newk8600

Senior Member
Aug 19, 2010
525
25
Northglenn
These commands should also work via Android Terminal, although I imagine it's easier copying and pasting with a mouse and keyboard.
.

It isn't a good idea to try installing system files from the phone especially in terminal when there is a "stop" command because this will hault the GUI and the system so you'd be stuck.

Please stick to ADB for this at least. A strong suggestion.:)
 
A

Angdroid

Guest
It isn't a good idea to try installing system files from the phone especially in terminal when there is a "stop" command because this will hault the GUI and the system so you'd be stuck.

Please stick to ADB for this at least. A strong suggestion.:)

I was just going to suggest that too...

-----------

LauncherPro has been updated to 0.7.9.0 Check bottom of first post for download link and install instructions.
 

Natty_lite

Senior Member
Feb 21, 2008
73
0
It isn't a good idea to try installing system files from the phone especially in terminal when there is a "stop" command because this will hault the GUI and the system so you'd be stuck.

Please stick to ADB for this at least. A strong suggestion.:)
You're right. I didn't think about that. I'll make sure I remember that for future reference. Thank God I used ADB

Thanks! It's there under the install instructions.
No problem at all. Very clean work. I'm running the black status bar on my phone as we speak.
 

Natty_lite

Senior Member
Feb 21, 2008
73
0
Cool...so I take it that theme install went well.

Yep, thanks to you. I had issues getting the Deodex tool to work properly on my W7 64 bit machine. This file made life easier.

Someone just upped a D1 theme in the Theme and Apps subforum. Shouldn't I be able to replace the .apks from your file with those? (I'm trying to get the stock Android icons back for browser, music, dialer, sms, and calendar)
 
A

Angdroid

Guest
Yep, thanks to you. I had issues getting the Deodex tool to work properly on my W7 64 bit machine. This file made life easier.

Someone just upped a D1 theme in the Theme and Apps subforum. Shouldn't I be able to replace the .apks from your file with those? (I'm trying to get the stock Android icons back for browser, music, dialer, sms, and calendar)

That should work...
 

pathfin9

Member
Jun 16, 2010
12
0
Would this work if I have already installed a custom rom? Or would it mess things up?

Thanks!

-John
 

Stephan_

Member
Mar 28, 2010
32
0
What exactly is theme in the launcherpro? Sorry to have to ask but couldn't the image be provided for the app drawer from the screenshot? Thanks for the great work! :D
 

chrstdvd

Senior Member
Sep 15, 2010
58
3
McKenney Va
mount -o rw,remount -t ext3 /dev/block/mmcblk1p21 /system
cp /sdcard/app/* /system/app/
cp /sdcard/framework/* /system/framework/
rm /system/app/*.odex
rm /system/framework/*.odex
mount -o ro,remount -t ext3 /dev/block/mmcblk1p21 /system
reboot

Questions:
1. Could you explain the Mount line?

2. When you "rm" the odex files what happens. I mean have you done something to the associated .apx files?
If not, does that mean I could just use these commands and remove my .odex files and I would be what is called deodex'ed?

3. What is the benefit of de oxed' ing?

I am keeping an text file with abd instructions for different categories and do not understand some of the commands like the mount line that is the same in most of the procedures.

I have been googleing around trying to find a tutorial or lesson plan for adb and keep bookmarks on sites I find. Most of the info on the net that I find, you can get by typing adb help. That is fine, except it does not really explain what the commands mean or do.

Understand you are busy man, so if you do not have time for this, I'll understand. I am retired and have nothing else to do. Ha!
 
Last edited:

goliathvt

Member
Dec 30, 2008
14
0
Blacksburg
This is probably more information than you wanted to know, but you seem to be interested in learning so...

Questions:
1. Could you explain the Mount line?

mount -o rw,remount -t ext3 /dev/block/mmcblk1p21 /system

This line mounts the /system partition in read-write instead of the default read-only. In linux, hardware has special device files that are housed in the /dev/ directory. These devices get "mounted" for use to a mount point which usually has a nice, human-readable name. In this case, "/system". The "-t ext3" part defines the file system type. Typical linux file systems are ext2 and ext3. Winblows file systems are things like FAT32 and NTFS.

So, the command spelled out is something like this: remount in read-write mode the block device at "/dev/block/mmcblk1p21" to the mount point "/system" using the file system type "ext3".

2. When you "rm" the odex files what happens. I mean have you done something to the associated .apx files?

Yes something has been done. Deodexing is a lengthy process that, in part, converts the .odex files back to .dex files and reincorporates that data back into the associated .apk file. This is necessary for theme creation and some other kinds of development. The .odex files tend to prevent modification of .apk's, which is required for things like themes. The default .apk's are also signed zip files with a signature to prevent against tampering. In other words, although you can rename an .apk to .zip and extract it, you can't decompress an .apk, modify its contents (change an image or icon, for example) and then recompress without some consequences. Deodexing removes the signature stuff, making it far easier for developers to get at the guts of the content within the .apks.

If not, does that mean I could just use these commands and remove my .odex files and I would be what is called deodex'ed?

No. Simply removing the .odex files without replacing the .apk's with modified (deodexed) versions would leave you with non-functioning applications. The .odex files contain code that has been removed from the .apk files by developers in an effort to compress data and speed up the initial boot process.

Basically, when you phone boots for the first time, a lot of information is being decompressed into the /data directory for easy, quick access. The .odex files help streamline this process. With their data reincorporated into the .apk's, booting takes longer, but the benefits, like themes and other fixes that probably won't ever be available to non-deodexed phones, usually far outweigh the drawbacks.

3. What is the benefit of de oxed' ing?

For now, the ability to install custom themes is the main benefit. However, community developers are often able to provide fixes to problems on deodexed phones that the official devs will not, like the HTC Hero's stock lock screen issues.

If you're interested in learning more about adb, you will probably want to swan dive into some linux documentation. Without a linux background, the adb stuff will seem pretty foreign. I'd include links to some sources, but I'm new here and that's been restricted.
 
Last edited:
A

Angdroid

Guest
What exactly is theme in the launcherpro? Sorry to have to ask but couldn't the image be provided for the app drawer from the screenshot? Thanks for the great work! :D

All that is themed in launcher pro are the icons when you long home press the home screen. So Shortcuts, Widgets, Folders and Wallpapers are using the same icons as Blur Home. Also the people and phone icons have been replaced to match the blur icons when you are using the default icons.
 
A

Angdroid

Guest
This is probably more information than you wanted to know, but you seem to be interested in learning so...



This line mounts the /system partition in read-write instead of the default read-only. In linux, hardware has special device files that are housed in the /dev/ directory. These devices get "mounted" for use to a mount point which usually has a nice, human-readable name. In this case, "/system". The "-t ext3" part defines the file system type. Typical linux file systems are ext2 and ext3. Winblows file systems are things like FAT32 and NTFS.

So, the command spelled out is something like this: remount in read-write mode the block device at "/dev/block/mmcblk1p21" to the mount point "/system" using the file system type "ext3".



Yes something has been done. Deodexing is a lengthy process that, in part, converts the .odex files back to .dex files and reincorporates that data back into the associated .apk file. This is necessary for theme creation and some other kinds of development. The .odex files tend to prevent modification of .apk's, which is required for things like themes. The default .apk's are also signed zip files with a signature to prevent against tampering. In other words, although you can rename an .apk to .zip and extract it, you can't decompress an .apk, modify its contents (change an image or icon, for example) and then recompress without some consequences. Deodexing removes the signature stuff, making it far easier for developers to get at the guts of the content within the .apks.



No. Simply removing the .odex files without replacing the .apk's with modified (deodexed) versions would leave you with non-functioning applications. The .odex files contain code that has been removed from the .apk files by developers in an effort to compress data and speed up the initial boot process.

Basically, when you phone boots for the first time, a lot of information is being decompressed into the /data directory for easy, quick access. The .odex files help streamline this process. With their data reincorporated into the .apk's, booting takes longer, but the benefits, like themes and other fixes that probably won't ever be available to non-deodexed phones, usually far outweigh the drawbacks.



For now, the ability to install custom themes is the main benefit. However, community developers are often able to provide fixes to problems on deodexed phones that the official devs will not, like the HTC Hero's stock lock screen issues.

If you're interested in learning more about adb, you will probably want to swan dive into some linux documentation. Without a linux background, the adb stuff will seem pretty foreign. I'd include links to some sources, but I'm new here and that's been restricted.

He took the words right out of my mouth ;)

Thanks!
 

chrstdvd

Senior Member
Sep 15, 2010
58
3
McKenney Va
Thank you so much for the info. Linux huh, guess I will dive right in. My background is Basic, FORTRAN, COBAL AND Visual Basic for Apps (Excel only). I quit trying to keep up with Visual Basic because Object Oriented Programming was really starting to irritate me. I was fairly good in DOS back in the day. These adb commands remind me of DOS, so hopefully I will catch on and understand.


At least in the olden days you got a manual to explain the commands with some examples.

Anyway, Thank you. I will start Googleinh Linux.

Found this site and I am in pig heaven. Thanks again, things are starting to make sense, from the "old days perspective".

http://www.linux-tutorial.info/
 
Last edited: