Post Reply

[TOOL] odexer

OP loSconosciuto

10th May 2012, 06:49 PM   |  #1  
OP Senior Member
Thanks Meter: 2,813
 
765 posts
Join Date:Joined: Nov 2011
I made this shell script to automatize the odexing process and maybe it could be useful to someone else.
It should be universal, but I only tested it on my phone.

It's not to re-odex a deodexed rom, but to make stock roms compatible odexed files from deodexed files.
Some mods won't work (signature issues I think)

How to use it:
Extract the attached zip wherever you want on your phone.
In the same directory of the script 'odexer.sh' and the directory 'odextools', make a directory named 'deodexed' (actually, it's already there). Inside 'deodexed' create two directories: 'framework' and 'app'. Put there your modded files, each in the respective directory.
You need the original stock odexed files (apk and odex) and all the '$BOOTCLASSPATH' files (see the note below). The script was intended to be used on odexed rom, but I made it adaptable: in the script change the variable 'moddedpath' with the path to the directory with the original odexed files, each inside 'app' or 'framework (you can directly copy '/system/framework/' and '/system/app/' from a stock rom if you are too lazy).
(I only tested this script on my odexed stock rom using /system as 'moddedpath')

Here how the directory tree should look like:
Code:
/some/random/path/
   |-deodexed
   |---app
   |-----SystemUI.apk
   |---framework
   |-----framework.jar
   |-odexer.sh
   |-odextools
   |---busybox
   |---dexopt-wrapper
   |---zip
You need to run the script as root from 'adb shell' or 'Terminal emulator'.
If you put the script in your vfat formatted sdcard, you won't be able to change its permissions, so, in order to run it, you need to pass its path to 'sh' as argument:
Code:
sh /sdcard/somepath/odexer.sh
It will create in the same directory a directory named 'odexed-DD-MM-hh.mm.ss'.
The script will automatically skip files with no odex (framework-res.apk should be always skipped, I think).

It's important to keep everything in the same place, because I used relative paths in the script.

Enjoy

________
To see your $BOOTCLASSPATH files, run from 'adb shell' or 'Terminal emulator:
Code:
echo $BOOTCLASSPATH
or open your /init.rc
Attached Files
File Type: zip odexer.zip - [Click for QR Code] (465.9 KB, 89 views)
Last edited by loSconosciuto; 10th May 2012 at 08:19 PM. Reason: Attached file updated (it hadn't the needed tools)
The Following 7 Users Say Thank You to loSconosciuto For This Useful Post: [ View ]
10th May 2012, 07:07 PM   |  #2  
TheFrankenstain's Avatar
Senior Member
Flag Moscow
Thanks Meter: 2,828
 
1,085 posts
Join Date:Joined: Dec 2011
More
Thank you
10th May 2012, 07:19 PM   |  #3  
vishal24387's Avatar
Recognized Contributor
Flag Solapur, Maharashtra
Thanks Meter: 1,722
 
3,315 posts
Join Date:Joined: May 2011
More
Thank you for guide. But some points were gone over my head
I found this one. Its one of the simplest method.

http://forum.xda-developers.com/show....php?t=1348062
10th May 2012, 07:24 PM   |  #4  
OP Senior Member
Thanks Meter: 2,813
 
765 posts
Join Date:Joined: Nov 2011
Quote:
Originally Posted by vishal24387

Thank you for guide. But some points were gone over my head

Which point? This?
Quote:

It's not to re-odex a deodexed rom, but to make stock roms compatible odexed files from deodexed files.

10th May 2012, 07:36 PM   |  #5  
vishal24387's Avatar
Recognized Contributor
Flag Solapur, Maharashtra
Thanks Meter: 1,722
 
3,315 posts
Join Date:Joined: May 2011
More
Quote:
Originally Posted by loSconosciuto

Which point? This?


actually I am noob in case of android's coding technical language. Its not ur fault
Post Reply Subscribe to Thread

Tags
odexer
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes