[Q] Manual deodex an rom before flashing? - Galaxy Ace S5830 General

I'm searching for a simple way how can I deodex any rom. My idea is to rename the *.odex file to classes.dex and put it into the apk/jar archive using a simple archive manager. Will this work? I don't like any scripts to do that, will make it manual before flashing the rom. And need I to sign the apk/jar files (I think the normal apk files need that, but what witch the framework? Need it too to be resigned?).

no use xultimate
Sent from my GT-S5830 using xda premium

sometimes scripts is better to make your life easier
btw try dsixda android kitchen. its my favorite tool/script to deodex

Hmm ok will try first the dsixda android kitchen, I see it has version for Linux. But I will understand how this script works?
EDIT
Ok, now I see, it uses baksmali and samli to deodex. Thanks to all, will test it tomorrow.

Ok, after using the dsixda android kitchen and deodexing the framework (and SystemUI.apk, not more) and flashing the ROM I got an bootloop (wipe doesn't help). Her is my logcat http://pastebin.com/DtfChnPp , can some help, what did I wrong? I have only after deodexing apply the volume mod and the Pdroid patch, I am working on this rom http://forum.xda-developers.com/showthread.php?t=1360889

try this
download xultimate, theres a thread about it somewhere. unzip it and connect your phone with the rom thats .odex http://forum.xda-developers.com/show....php?t=1360889
next
once connected click on opition 5 which will pull all the apps and framework files from your phone and will deodex all the files and store them in the folder called "done_app" and "done_framework" may take up to 15mins
next
change the folder names of the done folders to "app" and "framework" and have both folders and the rom.zip that you installed pre at hand, in your case
http://forum.xda-developers.com/show....php?t=1360889
Then open the rom.zip up with 7zip and then click on system folder and drop "app" and "framework" folders into the rom.zip so your swaping the the folders with the .odex files for the deoxed ones you just did. put it on sd-card. wipe, mount system and data and install.
correct me if im wrong.
hope this works.

Related

Creating a CWM zip file

I have some changes that I like to make to the Settings.apk, Systemui.apk, and framework-res.apk. Typically, I just pull these files from the Rom I'm using, edit the images in the drawable folders, and then copy them into the system files on my phone. I'd like to be able to create a zip file to do this for me. It looks like I can take someone elses update package and edit the "update script" file to do this. Is it that simple or is there more to it? What other files are important to creating an updater zip.
Thanks
Sent from my SAMSUNG-SGH-I777 using xda premium
BigMc71 said:
I have some changes that I like to make to the Settings.apk, Systemui.apk, and framework-res.apk. Typically, I just pull these files from the Rom I'm using, edit the images in the drawable folders, and then copy them into the system files on my phone. I'd like to be able to create a zip file to do this for me. It looks like I can take someone elses update package and edit the "update script" file to do this. Is it that simple or is there more to it? What other files are important to creating an updater zip.
Thanks
Sent from my SAMSUNG-SGH-I777 using xda premium
Click to expand...
Click to collapse
Just head over to perkas files stash (google it) and look for a empty system cwm.
Now you just have to make folders in this zip and add your files. example you want framework-res.apk and systemui.apk flashed.
So open the cwm zip and add a folders called app and a folder called framework.
The zip will be/system and so with the folders it creates /system/framework/framework-res.apk and system/app/SystemUI.apk. Etc
This empty system cwm should have all the folders you need for the zip

Packing a boot.img and drivers to a zip?

Im developing a custom kernel. I was wondering now that i have my boot.img and drivers is there a way to pack them for installtion in a flashable .zip? I basically want to supply features to an existing rom. with custom kernel and shell scripts. I would like ot to be easy for others to install. Google didnt turn up much about this. Any info or links would be greatly appreciated!
Sent from my LG-VM670 using XDA App
Have the drivers put into folders in this fashion. system/lib/modules the drivers being in the modules folder. The boot.img is in the root of the zip along with the META-INF and system folders. The META-INF folder consists of this order META-INF/com/google/android and in the android folder contains the update-binary and updater-script files. The update-binary is specific to whatever device you have. The updater-script is to be edited by a text editor to tell how to flash. Look through other flashable zips to see the syntax of the updater-script.
私のEVO 3Dから送信される。
Thank you this is allot simpler than i expected. I thought i was going to need some kind of Kitchen or tools to build the META stuff and scripts!
The only thing im still fuzzy on is the directory structure of the zip file lets say i have these three files boot.img, /system/bin/modules/wirless.ko, and /system/bin/remount.sh the zip should look like this:
-/boot.img
-/META-INF/obviously more to this dir just a quick layout
-/system/bin/remount.sh
-/system/lib/modules/wirless.ko
and if i wanted to throw anything else in there i would just add the directory with the new files in it as needed and any will /data, /mnt/sd-ext, whatever
Refer the link in my sig

Re-compile framework-res.apk (Custom Rom)

I got this figured out already, sorry about that.
Who ever thanked me, I wasn't posting a guide but a question.
I am trying from a fresh firmware base to learn from scratch but no idea how to get that framework to compile correctly.
did you install framework first?
Code:
apktool if framework-res.apk
Easy
I had problems with the apk tool and recompiling. The way I ended up doing it is:
I didnt decompile the framework-res.apk.
rename the file framework-res.apk.zip
open it with 7zip.
Extract the files you are wanting to work on
Do what ever work on the files you need done
Drag and drop the files back in the directories they go into while file is open in 7zip
Close 7zip
Rename file back to framework-res.apk
push to phone with adb
No decompile or recompile.
Hope this helps
Chadw1985 said:
I had problems with the apk tool and recompiling. The way I ended up doing it is:
I didnt decompile the framework-res.apk.
rename the file framework-res.apk.zip
open it with 7zip.
Extract the files you are wanting to work on
Do what ever work on the files you need done
Drag and drop the files back in the directories they go into while file is open in 7zip
Close 7zip
Rename file back to framework-res.apk
push to phone with adb
No decompile or recompile.
Hope this helps
Click to expand...
Click to collapse
If you just want to modify one of the 'normal' XML files or an image then that approach will work fine. The problem is he wants to edit the bool.xml file and that is contained in the 'resources.asrc' file and you need to decompile it first.
I am in the same situation although someone managed to edit the file for me and recompile it so I got there in the end, just not by doing it myself.
I followed the instructions you describe and the file never recompiled properly - or at least my device never booted with the one I recompiled
Try it like this:
1. Place APK in "place-apk-here-for-modding"
2. Choose "9" to Decompile
3. Grab resource "resources.arsc" from framework-res.apk
4. Do my edit in projects\framework-res.apk\res\values\bools.xml
5. Compile - Yes (system app) - Yes (copy files)
6. Go to "keep" folder and delete "resources.arsc" and the bools.xml file
7. Press any key
8. Either push by ADB or Root Explorer or Flash
nickiberli said:
Try it like this:
1. Place APK in "place-apk-here-for-modding"
2. Choose "9" to Decompile
3. Grab resource "resources.arsc" from framework-res.apk
4. Do my edit in projects\framework-res.apk\res\values\bools.xml
5. Compile - Yes (system app) - Yes (copy files)
6. Go to "keep" folder and delete "resources.arsc" and the bools.xml file
7. Press any key
8. Either push by ADB or Root Explorer or Flash
Click to expand...
Click to collapse
I have tried exactly like this and it didn't work for me. I downloaded lots of different APK tools and tried them all - there were comments about using older versions of apktool.jar etc. I kept getting different sizes of the output file depending on which one I used. I gave up in the end as someone edited the file for me and it was only one specific entry in bool.xmls I wanted changing. As far I could tell we were both doing exactly the same thing.
The last thing I said I was going to do was wipe the PC I was attempting to do this on. I never got round to doing it... I'd be interested to know why I could never get this working though
Andy
Give me the framework and tell me what u want to do.
I will do that for u
Btw is the framework ICS based?
Sent from my Micromax_A70 using Tapatalk 2 Beta-4
You have resigned?
Greets!

[Q] How should I de/recompile a system app? What did I do wrong?

Hi,
So the situations is like this:
Just got a new LG Nexus 4, NFC enabled, GREAT!!!!
But then I start using it, and the NFC sound (everytime the phone reads a nfc-tag it makes an sound) annoys me beyond belief.
So I start looking around, it seems there's no solution, except recompiling the app.
So I learn how to compile an app (noob here), using this guide: http://forum.xda-developers.com/showthread.php?t=1860115
I'm up to the point where my apk is decompiled, and I have modified the sound files, located in my decompiled files folder respectively at res/raw/start.ogg & res/raw/end.ogg.
I modded the files using audacity, lowering the volume to zero, used them to replace the original .ogg files. The file size is a bit smaller as the original ones (1Kb difference).
Next I use the recompile command: apktool b decompiled_apk_folder_with_modified_files modded_apk_file.apk
So now I have the new nfc apk file, called NfcNci.apk, with which I replace the original file in /system/app.
Next up I reboot my phone into recovery, wipe all cache and dalvik cache, and reboot again.
First thing that pops up on my screen is a force-close message, saying that the nfc-service force closed.
Anyone who can tell me what I did wrong? Or how I can fix this?
Attached are: my decompiled-files-folder (compressed to zip)
the original NfcNci.apk file
my modded NfcNci.apk file which causes the FC's.
Any help will be greatly appreciated!!!!
S.
Looks like you're still on 4.2
The latest NfcNci.apk has some more files.
And your apk is missing the META-INF folder.
I guess that this is the problem.
But you should use "adb logcat" to ensure we're on the right track.
Micky
1 thing i would recomend is not using the actual apk you just built. instead, open your new apk with a file manager such as 7zip and remove your newly compiled files out of it, then put them into the original apk from your rom using 7zip as well! thus keeping the apk's original signature
try to copy the least amount of files from one to another, so to be safe only pull out your new .ogg files, then put them into your original apk! hope this helps
ldrifta said:
1 thing i would recomend is not using the actual apk you just built. instead, open your new apk with a file manager such as 7zip and remove your newly compiled files out of it, then put them into the original apk from your rom using 7zip as well! thus keeping the apk's original signature
try to copy the least amount of files from one to another, so to be safe only pull out your new .ogg files, then put them into your original apk! hope this helps
Click to expand...
Click to collapse
Hi, I tried this, installed 7zip, and double clicked the original apk, I opende the res/raw/ directory, and only copied the files I was using: start.ogg & end.ogg. Then I close 7zip, and send the file to my phone. But as soon as I it them to /system/apps on my phone, and reboot to recovery, wiping the dalvik cache. I get FC's on reboot (NFC-service has FC'd).
Any reasons for this?
Thanks for the help, both of you!
BTW: I'm on Android 4.3 JB

How To Odex Non-System Apps

Hi, Deodexing an Odexed App is very simple. There are many tools for deodexing like the Famous Ultimate Deodexer . How about Odexing back an App without its original odex file? How could we odex it? Here's what I did to get all our problem solved:
1.) First of all, explore your Apk file using WinRar or 7zip, search for its classes.dex file. When you see one, proceed to the other step. When there's no classes.dex in your .apk file, I'm sorry, that App cannot be odexed.
2.) The next step is to extract the classes.dex file from that Apk by dragging it out. Then rename it to ["Appname".odex](Make sure you name Appname.odex the same as your Package Name.
Ex. CHATOn_MARKET.odex--->CHATOn_MARKET.apk
3.)Download Deodexer-Odexer-Tool_v1.00. I can't share the link. Just google it
4.) Extract the downloaded files. Pull framework dependencies. (I feel lazy about this common sense needed
5.) Move the .apk and .odex file you've just made in the "put-file-here" folder of Deodexer-Odexer-Tool_v1.00. Copy again the .apk file to the "finish" folder and rename it to "Deodexed_Appname.apk".
6.) Open "Deodexer-Odexer-Tool.bat" now deodex your apk file. Its just simple, read and understand the onscreen instructions.
7.) Last Step: Push your .apk file to your phone.
Hope I helped you.
For odexing apps i recommend Lucky Patcher, is the only app that actually odex my apps

Categories

Resources