How to deodex a ROM? - GT540 Optimus General

I'm planning to create my own custom rom based on 2.1. I have tried the Android Kitchen but have had no luck, I get lots of errors about java exceptions, etc. Please could anyone tell me a WORKING way to deodex the stock rom.

JackG256 said:
I'm planning to create my own custom rom based on 2.1. I have tried the Android Kitchen but have had no luck, I get lots of errors about java exceptions, etc. Please could anyone tell me a WORKING way to deodex the stock rom.
Click to expand...
Click to collapse
Try wait some time... kitchen try use old smali version and deodex rom correctly
or
Try xUltimate deodexer (find in google )

JackG256 said:
I'm planning to create my own custom rom based on 2.1. I have tried the Android Kitchen but have had no luck, I get lots of errors about java exceptions, etc. Please could anyone tell me a WORKING way to deodex the stock rom.
Click to expand...
Click to collapse
Why don't you just remove the odexed apps? It's easier than deodexing.

despotovski01 said:
Why don't you just remove the odexed apps? It's easier than deodexing.
Click to expand...
Click to collapse
So that means removing, Phone.apk, Settings.apk, and pretty much every system app.

Search daneshm90
Mark

I am trying this script but getting bootclasspath errors. If I could retrieve the bootclasspath then i would have no trouble de-odexing. Thanks

Related

NO LONGER ACTIVE PLEASE CLOSE [devs] deodex version of ivanmmj Eris_Official 1.0

All,
per positive response below is a link to a copy of ivanmmj Eris_Official 1.0 ROM that I have fully deodexed. This is more meant for devs for continued play time, but it is a flashable ROM. PLEASE NOTE that ivanmmj himself looks to be coming out with the next version of Eris_Official 1.0 per his thread http://forum.xda-developers.com/showthread.php?t=652044.
Hope this is helpful and Enjoy
Link: REMOVED FROM HOST SERVER
P.S. please let me know of any issues as this is my first full deodex also I would like to encurage using this tread to exploring moding some of the system files on Eris ROM builds as it has been fun to tweak things
P.P.S. If you want the Zanfer kernel let me know and I will look at adding it in however ivanmmj's new version should have it...
what is Deodex?
I'm definitely interested, but I also think Ivan is working on the same project himself. I'm pretty sure his "1.1" is deodexed and has Zanfur's kernel. Not sure what other changes he has in mind, but you might want to check with him before posting since you'll end up being the one getting all the PM's from people wanting help. ;-)
Yes please I'm looking for exactly that
-------------------------------------
Sent via the XDA Tapatalk App
That would be awesome.
Sent from my Eris using XDA App
BTW jcase's plain jane1.0 has zanfur overclocking kernel.....
i dont know what you think but it might be a better platorm than ivanmmjs
a deodexed version of that would be tight....
kernels are easy to compile and swap out, a different kernel isnt going to influence the build at all
i always seem to get better battery life from the non oc'ed kernel.
Morkai Almandragon said:
what is Deodex?
Click to expand...
Click to collapse
Yes, what does that mean ?
hallstevenson said:
Yes, what does that mean ?
Click to expand...
Click to collapse
it means you have a classes.dex file rather than a .odex file
it makes things easier, its also possible to metamorph these builds and its possible to install a deoexed app on multiple platforms.
anonomouse said:
it means you have a classes.dex file rather than a .odex file
it makes things easier, its also possible to metamorph these builds and its possible to install a deoexed app on multiple platforms.
Click to expand...
Click to collapse
Means I can finally modify Rosie.apk to my liking.
hallstevenson said:
Yes, what does that [deodex] mean ?
Click to expand...
Click to collapse
A more experienced developer can add more but a few quick basics:
.odex files are precompiled class flies that correlate to a .apk or .jar file. In an odex ROM an .apk/.jar file will not function without it's correlated .odex.
a deodex build takes all of the .odex files converts them to a classes.dex and puts them into the .apk or .jar file package
deodex ROM are easier to mod because each .apk or .jar is a "complete" package and can be more easily decompiled and ported (i.e. you do not have to worry about the .odex files)
A deodexed build requires less space in /system, but more space in /data
A deodexed build requires a longer initial boot because they must regenerating those odex files from the dex files in the .apks/.jars and save them to /data/dalvik-cache
Thats a quick list of what I know
odex only help speed up app loading time and first time boot. Think of this as Windows' prefetch.
If you want to re-create odex for apk for porting, etc... I suggest only do this to /system/app not /data/app because when you do update from market and your app will break, unless you wipe out dalvik-cache.
zach.xtr said:
This is more meant for devs for continued play time, but it is a flashable ROM.
Click to expand...
Click to collapse
Would this be ok for an every day ROM? Or should it just be used by dev's as a base ROM?
Hey guys I've been testing this for Ivan. same thing he has a version deodexed.
I edited this
http://forum.xda-developers.com/showthread.php?t=664951
to work for this rom. which works great, but I get an error of
com.htc.bgp because of it, does anyone have any idea why?
Romparoo said:
Would this be ok for an every day ROM? Or should it just be used by dev's as a base ROM?
Click to expand...
Click to collapse
Technically it is fine as an everyday ROM, however I do not recomend using it for such because it is not support and will have no additional features over ivanmmj origional 1.0.
So I guess, yes it meant to be used as a base ROM or "spare parts" for devs.
BlazeD OnE said:
Hey guys I've been testing this for Ivan. same thing he has a version deodexed.
I edited this
http://forum.xda-developers.com/showthread.php?t=664951
to work for this rom. which works great, but I get an error of
com.htc.bgp because of it, does anyone have any idea why?
Click to expand...
Click to collapse
Someone else did this, on androidforums.com. I haven't replied to his posting, but it's in like page 19 of the 'show off your UI layout' thread there. I'm working on a modified Rosie.apk right now, as soon as I get this de-odex'd Ivan's on my phone running. Titanium backup here I come.
FYI, I was able to flash the deodexed version over the original Eris_Official 1.0 Alpha without having to do a full wipe (just wiped dalvik-cache). Naturally, I went back and re-flashed Zanfur's overclock kernel after that.

Adding FriendStream to a Custom ROM ?

Can anybody help me in adding Friendstream to a Custom ROM, which doesn't has FriendStream
can you not just find the App and add it after installing your Rom??
will not work!
Short answer: it's likely not going to be easy
A few days ago I found a detailed guide about porting HTC apps to non htc-ROMS. It was a ****load of work, but doable I guess. In the example he ported an htc app (music player?), by using nice constructions with opening and resigning apk's, pulling necessary parts of the htc.framework and more "mojo jojo".
Problem is: I really can't find the guide anymore, and I have been testing that search function for way to long....
So is there anybody that remembers where I am referring to perhaps?
I tried pushing the .apk's to /system/app/ I knew this wouldn't do, But still gave it a try
EDIT : Maybe a Dev would be able to help us out, Please Any Dev
It *could* work for a deodexed rom... so try asking your rom dev to deodex it and give it a try which rom are we talking about?
killer4o said:
It *could* work for a deodexed rom... so try asking your rom dev to deodex it and give it a try which rom are we talking about?
Click to expand...
Click to collapse
MCR r5, But I have tried pushing the .apk's but still it doesn't work, I have tried this on both deodex and odex ROM's.
Tried to add "FriendStream.apk" and "com.htc.FriendStreamWidget.apk"
to a custom ROM and sign the ROM again,but don`t works,too!

[ deodex script] deodexerious: all your base are belong to us!

Here's a script I've built for my own ROM cooking purpose
another purpose was to create a very easy to read script, so everyone can understand the magic of deodex
had some hard time figuring all the BOOTCLASSPATH and all the signing magic (if you want to do it manually, the secret is: don't pack and sign!, just add the classes.odex to the original jar or apk...whatever...
or use my script to automagically do all that)
after one brick and jtag reincarnation and a few bootloops
I present to you:
DEODEXERIOUS !! (the only spartan deodex script)
requirements:
Linux
zip
* tested on my Ubuntu 10.10
instructions:
1. extract the included script
2. put the content of system(including the system folder) inside the rom folder
actually you can create a folder named system inside the rom folder and copy framwork and app folder there, it does not require any other files from the rom
3. while in the console inside the extracted script directory execute from the console
Code:
./deodexrom.sh
4. wait and watch the console for errors (there shouldn't be any)
5. when it is done, you should find the deodexed files inside the deodexed folder
* if you want to start over just execute from the same place in the console
Code:
./cleanall.sh
tested and successfully deodexed:
I897 UCKB1
I9088 KP2
I9088 ZNKP5
I9000 XXJPY
I9000 XWJS3
I9000 XWJS5
I9000 ZSJPG
I9000 XWJV1 2.3.2, except email.apk
it does not support already deodexed rom's!!! (why should it?)
if you test other raw versions (even captivate ones) please inform the result, or problems found, I'll do my best to help
careful
the script is a very initial version
it does inform errors human readable so watch the console for them
oh! almost forgot , here's the script:
http://dl.dropbox.com/u/3595341/deodexerious/deodexerious_03.zip
change log:
04/03/2011 - deodexerius_03
added gingerbread XWJV1 2.3.2 - custom classpaths
smali and baksmali 1.2.6
case insensitive classpath helpers
note:
deodexerius can deodex all XWJV1 2.3.2, except email.apk
27/02/2011 - deodexerius_02
better support for the additional files in kp5 and kp2
good luck!!
To Be Continued
If someone could come up with one of these for windows they would be my hero
Sent from my GT-I9000 using XDA App
rob989_69 said:
If someone could come up with one of these for windows they would be my hero
Sent from my GT-I9000 using XDA App
Click to expand...
Click to collapse
kind of like this one?
http://forum.xda-developers.com/showthread.php?t=700904
omg
You saved my life man... thanks a billion! And add a donate link, I know I'd like to send a few bucks your way
Pirateghost said:
kind of like this one?
http://forum.xda-developers.com/showthread.php?t=700904
Click to expand...
Click to collapse
If this works you are my hero!!! LOL. I've found a number of different ones, either they don't work or I'm not using them correctly but this one is new to me. Thanks.
rob989_69 said:
If someone could come up with one of these for windows they would be my hero
Click to expand...
Click to collapse
sorry man no windows version.
ytt3r said:
You saved my life man... thanks a billion! And add a donate link, I know I'd like to send a few bucks your way
Click to expand...
Click to collapse
your'e welcome.
rob989_69 said:
If this works you are my hero!!! LOL. I've found a number of different ones, either they don't work or I'm not using them correctly but this one is new to me. Thanks.
Click to expand...
Click to collapse
oh it works....
Just used this on KP2, works great, thanks!
existz said:
Just used this on KP2, works great, thanks!
Click to expand...
Click to collapse
great news!
works great with xwjs3
This is great. Works on the new KB1.
I keep seeing this while the script is running
Compiling classes.dex from rom/system/framework/framework-tests
UNEXPECTED TOP-LEVEL EXCEPTION:
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
at java.util.ArrayList.raiseBoundsError(libgcj.so.11)
at java.util.ArrayList.checkBoundExclusive(libgcj.so.11)
at java.util.ArrayList.get(libgcj.so.11)
at org.jf.dexlib.DexFile$2.placeAt(DexFile.java:783)
at org.jf.dexlib.DexFile.place(DexFile.java:659)
at org.jf.smali.main.fixInstructions(main.java:255)
at org.jf.smali.main.main(main.java:203)
Packing
Cleaning up
Done.
Cleaning up
Do I have to worry? I am going to try it again when it all completes, just want to make sure I am not missing anything
|OP|
it does not support already deodexed rom's!!! (why should it?)
Click to expand...
Click to collapse
what if you wanted to deodex a single new app? just redo the whole thing?
Trusselo said:
what if you wanted to deodex a single new app? just redo the whole thing?
Click to expand...
Click to collapse
To deodex a single app, you need to keep the deodexed framework files around. Then you can just do that app by pulling the code bits out of the framework.
Sent from my SAMSUNG-SGH-I897 using XDA App
Trusselo said:
what if you wanted to deodex a single new app? just redo the whole thing?
Click to expand...
Click to collapse
baksmali/smali + about 6 or 7 framework jars + cmd prompt = win!
How can I verify that the Deodex worked? I ran the script a couple times last night just to see what happens and then dropped the files in on my phone. Everything is working fine, just wanted to know how I can verify its deodexed.
nakedninja42 said:
How can I verify that the Deodex worked? I ran the script a couple times last night just to see what happens and then dropped the files in on my phone. Everything is working fine, just wanted to know how I can verify its deodexed.
Click to expand...
Click to collapse
do you see any .odex files named the same as your apks?
nakedninja42 said:
How can I verify that the Deodex worked? I ran the script a couple times last night just to see what happens and then dropped the files in on my phone. Everything is working fine, just wanted to know how I can verify its deodexed.
Click to expand...
Click to collapse
if you don't see errors like the one quoted bellow, then you should be fine.
nakedninja42 said:
I keep seeing this while the script is running
Compiling classes.dex from rom/system/framework/framework-tests
UNEXPECTED TOP-LEVEL EXCEPTION:
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
at java.util.ArrayList.raiseBoundsError(libgcj.so.11)
at java.util.ArrayList.checkBoundExclusive(libgcj.so.11)
at java.util.ArrayList.get(libgcj.so.11)
at org.jf.dexlib.DexFile$2.placeAt(DexFile.java:783)
at org.jf.dexlib.DexFile.place(DexFile.java:659)
at org.jf.smali.main.fixInstructions(main.java:255)
at org.jf.smali.main.main(main.java:203)
Packing
Cleaning up
Done.
Cleaning up
Do I have to worry? I am going to try it again when it all completes, just want to make sure I am not missing anything
Click to expand...
Click to collapse
actually this is an error, it means it failed to deodex this file
please provide more information, the reason can be many things:
java version
base rom
did you provide the full rom or only the file you mentioned?
provide more information and ill see what can be done.
ih4ckback said:
This is great. Works on the new KB1.
Click to expand...
Click to collapse
awesome.
marcelo.waisman said:
if you don't see errors like the one quoted bellow, then you should be fine.
actually this is an error, it means it failed to deodex this file
please provide more information, the reason can be many things:
java version
base rom
did you provide the full rom or only the file you mentioned?
provide more information and ill see what can be done.
awesome.
Click to expand...
Click to collapse
I am use the same KB1 that hit the forums yesterday that i4ackback stated that works for him. I installed Ubuntu 10.10 and installed Java from the software manager, not sure if its the right one. I started copying the full system folder but ended up only extracting just app and framework just like the OP states. That message appears throughout the process but I end up with everything in the deodexed folder.
Sent from my SAMSUNG-SGH-I897 using XDA App

[Q] Need to manually DeOdex?

N00b here...
I'm on Prime! v 1.5
I've been trawling old posts trying to understand things better and today I've learned what deOdex means and the benefits to modders.
The Prime 1.5 ROM is fully Deodexed at the time you flash it.
Over time as I install new APKs I assume that those new APKs are odexed on install? Will this give me trouble down the line if I install themes etc?
Is a periodic manual deodex necessary/advisable?
Deodexing is only useful for apks you are going to directly mod so no reason to deodex after the fact apks.
brandon... said:
Deodexing is only useful for apks you are going to directly mod so no reason to deodex after the fact apks.
Click to expand...
Click to collapse
Thanks for that. I appreciate the information.
I am a Noob but I'm learning and I figure the better I understand the OS the more fun I'm going to have with my toys (HD2 and TF)

[Q] Can it be replace .apk in system/data?

I install my new ROM (This the ROM: http://forum.xda-developers.com/showthread.php?t=2778909), but there is written that there is a bug in the com.android.phone application is experiencing force close. Can I replace it with another apk and I need to replace any apk so that I can use the phone app?
Thanks and sorry for bad english
since its a port it depends what the dependences are and if another apk you replace it with contains all the smali and dependances to avoid other kinds of force closes
in other words - there is only one way to find out and thats to try and logcat the result
marcussmith2626 said:
since its a port it depends what the dependences are and if another apk you replace it with contains all the smali and dependances to avoid other kinds of force closes
in other words - there is only one way to find out and thats to try and logcat the result
Click to expand...
Click to collapse
Unfortunately I am not very familiar with modifying a Custom ROM, if only I can, certainly I find ...
Thanks for your answers
indrakrisnadi said:
Unfortunately I am not very familiar with modifying a Custom ROM, if only I can, certainly I find ...
Thanks for your answers
Click to expand...
Click to collapse
Yes you can replace those apks with any of the custom ROMs out there.The fixes are yet to be released by me in a new build or in the form of a patch.Just wait for sometime till I fix the whole ROM.
aniket.lamba said:
Yes you can replace those apks with any of the custom ROMs out there.The fixes are yet to be released by me in a new build or in the form of a patch.Just wait for sometime till I fix the whole ROM.
Click to expand...
Click to collapse
Okay, thanks. Now I can call the app from another custom ROM, I wait for the update Fix because the UI of his ROM, great

Categories

Resources