[Q] Signing APKs/Themeing....... - Thunderbolt Q&A, Help & Troubleshooting

So I'm trying to do a little themeing and I have some questions. For instance, if I modify idlescreen_base.apk, do I have to sign that and then also sign the .zip? I'm trying to do a full on theme, modifying every little part of the ROM. When do you have to sign the .apks and .zips? One thing I don't like is the bubble around the four icons on the lock screen, so I went in to modify that and then found more files to change and so it began. And so while I'm on it, why do some m10s decode and some don't? Gingeritis3D and ShiftS3NS3 v3.0 have a default folder, but others have Blue Sky, etc. The default folder that has sharedm10 will decode but the others don't. Just curious. I'm using ShiftS3NS3 v3.0 as my base ROM to theme, by the way.

TheBeardedMann said:
So I'm trying to do a little themeing and I have some questions. For instance, if I modify idlescreen_base.apk, do I have to sign that and then also sign the .zip? I'm trying to do a full on theme, modifying every little part of the ROM. When do you have to sign the .apks and .zips? One thing I don't like is the bubble around the four icons on the lock screen, so I went in to modify that and then found more files to change and so it began. And so while I'm on it, why do some m10s decode and some don't? Gingeritis3D and ShiftS3NS3 v3.0 have a default folder, but others have Blue Sky, etc. The default folder that has sharedm10 will decode but the others don't. Just curious. I'm using ShiftS3NS3 v3.0 as my base ROM to theme, by the way.
Click to expand...
Click to collapse
I'm not much of a themer, but I might be able to help you with the signing.
You have to sign an APK any time you decompile and recompile it. Alternatively, if you use apktool, build the apk, then take the META-INF folder and AndroidManifest.xml from the original apk and copy them to the /build/app folder of the decompiled apk. Rebuild and your apk is signed. Your essentially taking the signature from the original apk and copying it to the one you recompiled.
If you want the zip to flash, you have to sign it. If you remove anything from an already signed zip, you have to resign it.

orkillakilla said:
I'm not much of a themer, but I might be able to help you with the signing.
You have to sign an APK any time you decompile and recompile it. Alternatively, if you use apktool, build the apk, then take the META-INF folder and AndroidManifest.xml from the original apk and copy them to the /build/app folder of the decompiled apk. Rebuild and your apk is signed. Your essentially taking the signature from the original apk and copying it to the one you recompiled.
If you want the zip to flash, you have to sign it. If you remove anything from an already signed zip, you have to resign it.
Click to expand...
Click to collapse
That makes total sense. I get it now. Thanks!

orkillakilla said:
I'm not much of a themer, but I might be able to help you with the signing.
You have to sign an APK any time you decompile and recompile it. Alternatively, if you use apktool, build the apk, then take the META-INF folder and AndroidManifest.xml from the original apk and copy them to the /build/app folder of the decompiled apk. Rebuild and your apk is signed. Your essentially taking the signature from the original apk and copying it to the one you recompiled.
If you want the zip to flash, you have to sign it. If you remove anything from an already signed zip, you have to resign it.
Click to expand...
Click to collapse
Sorry I seen this thread, and was wondering if you use metamorph to theme if you add the META-INF folder and the AndroidManifest.xml to the respective theme will the .apk be able to be installed into the data/app folder?

Deftoolfinch said:
Sorry I seen this thread, and was wondering if you use metamorph to theme if you add the META-INF folder and the AndroidManifest.xml to the respective theme will the .apk be able to be installed into the data/app folder?
Click to expand...
Click to collapse
Not sure. I don't use metamorph so I can't help you there. Sorry.
Sent from my ADR6400L using xda premium

I don't use metamorph. I modify the .apk then flash in recovery. Meta and ninja morph aren't necessary once you get the hang of flashing .zips.

Related

[Q] Implement Theme in Rom

Hello!
I'm trying to make my own Rom right now. With dsixda's Kitchen it isn't very hard to do so I thought I'd just give it a try. I'm taking a rooted official Update (Version: 2.10.405.2) as my base. Adding busybox runparts, the /data/app functionality, a2sd+, the custom bootanimation functionality etc. isn't a problem. Removing some apps like Maps, Facebook, Teeter (and so on) and adding some like Rom Manager, Neocore or Quadrant isn't a problem, too. But if I want to implement a theme like the Carbon Espresso Mod or a theme I made with the UOT Kitchen I'm getting bootloops at booting the phone. Here's what I do: I unzip the folder (for example a theme made with the UOT Kitchen) and I copy over the framework-res.apk from the unzipped folder to my Working Folder of the Kitchen (to system/framework) and I overwrite the original framework-res.apk.
And NO: I didn't choose a battery mod or a bootanimation in the UOT Kitchen....
Hope you guys can help me
I might be wrong but doesn't the new file have to be signed? I know there is a signing option in the kitchen.
Sent from my PC36100 using Tapatalk
It's a system .apk so it doesn't have to be signed.
I can't shed any light on the subject, but here's a bump.
Are you replacing the whole "framework-res.apk" file? If so then you will need to resign your entire ROM. Why? When you change a system file ("framework-res.apk", "com.htc.framework.apk", "twframework-res", "rosie.apk", etc.) it no longer has a matching "signature" for all the files it serves images to. Plug your phone into your computer and open up "ddms" in your android_sdk > tools folder to watch what happens when the phone boots up.
A workaround (The way I do it, it's more fun IMHO) is to open up your .apk files in 7zip (or if you're on a mac BetterZip) and add the images from the themed .apk to your stock .apk. This way makes it so your original .apk has the same signature as your other system files yet has the new images from the other files that you wanted. I've had a lot of luck with this method. I don't know if it will still work if you change any .xml files as I have not messed with those yet.
I've subscribed to this thread so if you have any questions post back here or you can PM me if you want. I'm on XDA all day, every day so I'll try to help as much as I can.
Thanks for all the answers! Especially to you, mbobino. Is there a way to sign the whole Rom new? When I make my Rom at the End, the Kitchen signs it automatically, doesn't it? The idea with the images is very good, but if I want to implement a theme like Carbon Espresso it isn't that easy, 'cause Carbon Espresso isn't just a few images. There are several .xml's etc.
The reason you boot loop is mis matched resource ID's in the public.xml file. If you decompile the framework using apktool after adding your images using an archiver then recompile apktool will update the public file for you which saves you from pulling ID''s for every image. I have a video tutorial of how to set up apktool and decompile framework in my Rom thread. Changing images in app apk's won't cause you to boot loop just messing with the framework will.
Sent from my ADR6300 using XDA App
DomiKamp said:
Thanks for all the answers! Especially to you, mbobino. Is there a way to sign the whole Rom new? When I make my Rom at the End, the Kitchen signs it automatically, doesn't it? The idea with the images is very good, but if I want to implement a theme like Carbon Espresso it isn't that easy, 'cause Carbon Espresso isn't just a few images. There are several .xml's etc.
Click to expand...
Click to collapse
The kitchen signs the .zip that you flash when you build it. It does not sign any .apks for you on its own. However, there is an option to sign .apks within the kitchen.
In my opinion, taking all of the images and figuring out how it all works is fun. I feel like I've already learned quite a bit from just digging around and moving files around.
As for the .xml files, you can decompile the .apk and edit them and then recompile the .apk. I'm actually looking into this today. It sounds like some work but hopefully I'll get it figured out.
Sounds like fun indeed So, I'll just have to try it. Where can I find the "Settings" for the Notification Bar? Thanks
The variois status*.xml files in the res/layout folder of the framework-res.apk and the status*.smali files in the services.jar.
What? If I want to implement a Theme made with the UOT Kitchen (without battery) I should just copy over those files to my existing res-framework.apk OR copy over the whole res-framework.apk (the new one) and sign it?
EDIT: Just tried it with a theme from the UOT Kitchen and it worked perfectly. I've just signed the res-framework.apk and the htc.com.resources.apk (or whatever) in the Kitchen, flashed it on my Phone and it just worked like a Charm. But I have got a 50% Transparent Notification Bar and all the system icons (Battery and time/date) are still black and not transparent! Has anyone got a idea where to change this? (.xml or whatever)...And does anyone know where I can find the HTC Wallpapers? I want to change them a little bit
HeyItsLou said:
The reason you boot loop is mis matched resource ID's in the public.xml file. If you decompile the framework using apktool after adding your images using an archiver then recompile apktool will update the public file for you which saves you from pulling ID''s for every image. I have a video tutorial of how to set up apktool and decompile framework in my Rom thread. Changing images in app apk's won't cause you to boot loop just messing with the framework will.
Sent from my ADR6300 using XDA App
Click to expand...
Click to collapse
HeyItsLou, I looked up your ROM thread but couldn't locate the video tutorial.... do you mind providing the url? Specifically, I am trying to add to the list of wallpapers in a ROM. (I have setup apktool but not sure where/which folder to add my wallpapers in Framework-res.apk Launcher.apk before recompiling/signing). Thanks.
You COULD use the Theme Porter by daneshm90. It will only port the PNG s for it so things like clock colour n stuff will be lost, but it will get you alot closer...
http://forum.xda-developers.com/showthread.php?t=737526
Sent from my HTC Hero using XDA App
Thanks! But like I've written before in my Edit, I made it. The bigger theme (Carbon Espresso) wasn't a problem, too. I just had to sign the .apk's in system/app and system/framework (the kitchen doesn't do it by itself. You have to choose the option to sign a single .apk and then look, where the system/framework .apk's are...). Works great now!
DomiKamp said:
Thanks! But like I've written before in my Edit, I made it. The bigger theme (Carbon Espresso) wasn't a problem, too. I just had to sign the .apk's in system/app and system/framework (the kitchen doesn't do it by itself. You have to choose the option to sign a single .apk and then look, where the system/framework .apk's are...). Works great now!
Click to expand...
Click to collapse
Isnt that what I said in the 2nd post -.- lol jk. Glad you got it working!
Yes! And that's why I tried it. And it worked! Thanks Husker and, of course, everybody else!
Glad you got it working. Welcome to the development side of android!
Sent from my PC36100 using XDA App
I don't sign system files or apps and apkmanager among other threads I've read say not to. Im on a rooted backflip. I find I only have to sign third party apps to install.
Why do you have to sign YOUR files?
Sorry for answering that late. Had a few things to do, so I wasn't online very often
If you want to cook an App into your Rom (NeoCore for example), then you don't have to sign it. You can just copy it into data/app. But if you want to change the whole framework-res.apk of the Rom, you have to sign it. 'Cause if you don't sign it, you'll get a Bootloop. The framework-res.apk is a very important part of the Rom, so it has to "fit" to the others. There are some ID's which have to match. Otherwise it won't work. That's how I understood it
Another Question: Has anybody got an Idea where to change the things that are coming, when you first start the phone with a new Rom (the "installation" of the Rom)? I wan't to write: "Welcome to DomiKamp's Rom!" Or something like that...
bestialbub said:
I don't sign system files or apps and apkmanager among other threads I've read say not to. Im on a rooted backflip. I find I only have to sign third party apps to install.
Why do you have to sign YOUR files?
Click to expand...
Click to collapse
I was curious about this too. I always edit the framework-res of any ROM I flash using a custom set of images I have and have never signed the apk afterwards and it has always worked. Maybe cause I'm only replacing images? I usually do this with framework-res and twframework-res and they both can sometimes grow by 1MB or more. Just my experience.
Sent from my SAMSUNG-SGH-I897 using XDA App
DomiKamp said:
Sorry for answering that late. Had a few things to do, so I wasn't online very often
If you want to cook an App into your Rom (NeoCore for example), then you don't have to sign it. You can just copy it into data/app. But if you want to change the whole framework-res.apk of the Rom, you have to sign it. 'Cause if you don't sign it, you'll get a Bootloop. The framework-res.apk is a very important part of the Rom, so it has to "fit" to the others. There are some ID's which have to match. Otherwise it won't work. That's how I understood it
Another Question: Has anybody got an Idea where to change the things that are coming, when you first start the phone with a new Rom (the "installation" of the Rom)? I wan't to write: "Welcome to DomiKamp's Rom!" Or something like that...
Click to expand...
Click to collapse
I think that in order to do the "welcome to" thing you'll have to edit the update-script file. I'm not 100% on it though. Look at a cm Rom and see what all is in there.
Sent from my HTC Evo 4G using XDA App

[Q] How do I edit systemui.apk?

Just wondering how to do it? I'm just trying to change the colour of the signal bars in the notification bar.
I'm running Lite'ning ROM 5.0 and I've replaced the .png files in systemui.apk with 7zip. I then use root explorer to copy into /system/app but the notification bar disappears after I reboot. I also tried editing with ninjamorph and resigning with signapktic with no luck.
Any idea what I'm doing wrong?
Cheers.
you need to decompile it, do changes, compile it an than copy it to the right folder.
decompiling can be done with tools like apk manager.
Great thanks! Will give it a go.
Actually for something as small as couple of image changes you don't need to de compile
You can just open the apk in 7zip add your files then put it in a flashable zip.
some things must change in the framework-res.apk too, or am i wrong?!
esk02k said:
Actually for something as small as couple of image changes you don't need to de compile
You can just open the apk in 7zip add your files then put it in a flashable zip.
Click to expand...
Click to collapse
As in a CWM update zip? Is there a program that can make it flashable?
Edit: Actually I got it all working with the app "Ninjamorph"

[Q] Need Help. After editing Framework-res, Rom wont boot

I've looked through many posts. I am very new to creating my own Rom's, and I am having a problem after editing framework-res.apk. I started by downloading a popular rom for the Evo 3D, and decompiled it, edited framework-res, and after flashing the rom it wouldn't boot past the startup animation. The screen just remained black, but the capacitive buttons remained lit. Heres my process:
1.) Download the rom I desired.
2.) Extract zip
3.) Locate Framework-res.apk, copy, paste on desktop.
4.)Extract framework-res.apk, edited icons to my liking.
5.) Delete Meta-inf.
6.) Compress framework-res back to .zip, then to .apk.
7.)Sign Framework-res.apk.
8.) Replace framework-res.apk in my desired rom.
9.) Go into Meta-inf, delete Cert.RSA, Cert.SF, Manifest.MF (everything but the com folder)
10.) Re-sign .zip
11.) Flash via CWM, reboot, see Android startup animation, black screen?!!?!?
I am 99% I didn't change any dimensions of any of the images, and I re-signed everything perfectly. I know my mistake(s) are probably very noob, but as of now, I can't figure out what I am doing wrong. Any help would be greatly appreciated!
(Before you say anything, I have searched the forums several times, with no luck. I also tried this process several times, only editing one.png in framework-res, and I still get the same result.)
ellisperkins said:
I've looked through many posts. I am very new to creating my own Rom's, and I am having a problem after editing framework-res.apk. I started by downloading a popular rom for the Evo 3D, and decompiled it, edited framework-res, and after flashing the rom it wouldn't boot past the startup animation. The screen just remained black, but the capacitive buttons remained lit. Heres my process:
1.) Download the rom I desired.
2.) Extract zip
3.) Locate Framework-res.apk, copy, paste on desktop.
4.)Extract framework-res.apk, edited icons to my liking.
5.) Delete Meta-inf.
6.) Compress framework-res back to .zip, then to .apk.
7.)Sign Framework-res.apk.
8.) Replace framework-res.apk in my desired rom.
9.) Go into Meta-inf, delete Cert.RSA, Cert.SF, Manifest.MF (everything but the com folder)
10.) Re-sign .zip
11.) Flash via CWM, reboot, see Android startup animation, black screen?!!?!?
I am 99% I didn't change any dimensions of any of the images, and I re-signed everything perfectly. I know my mistake(s) are probably very noob, but as of now, I can't figure out what I am doing wrong. Any help would be greatly appreciated!
(Before you say anything, I have searched the forums several times, with no luck. I also tried this process several times, only editing one.png in framework-res, and I still get the same result.)
Click to expand...
Click to collapse
Are you editing .9.pngs? If you are then you can't edit them the normal way. Also you don't sign anything that goes into the system folder.
Hey you can't do apk editing that way it wont work. You have to decompile the apk use apktool. Then make changes and recompile back.
Sent from my LG-P500 using XDA Premium App
I tryed with the apk tool and gave all green icons a blue color with gimp but after recompiling the framework-res.apk and uploading it to the phone it won't boot anymore. (bootloop)
Does anybody know if I have to sign the apk or do I have to do something different to make this work? (I did'n't change the size of the pictures, only recolored it.)
It's about the png files in the "drawable-hdpi" folder.
I followed the instructions from this site: http://www.miui-au.com/add-ons/apktool/)
Nemesco said:
I tryed with the apk tool and gave all green icons a blue color with gimp but after recompiling the framework-res.apk and uploading it to the phone it won't boot anymore. (bootloop)
Does anybody know if I have to sign the apk or do I have to do something different to make this work? (I did'n't change the size of the pictures, only recolored it.)
It's about the png files in the "drawable-hdpi" folder.
I followed the instructions from this site: http://www.miui-au.com/add-ons/apktool/)
Click to expand...
Click to collapse
You never sign a system apk. You main issue may be your trying to edit a .9.png if that is the case then you can't just recolor them in Gimp. They have to be decompiled and edited a certan way, then ran threw the draw9patch tool from the android sdk.
I believe the framework.apk and rom have to be deoxed to make these modifications
Sent from my HTC HD2 using XDA Premium App
Problemen is half solved. I re-colored all green icons to blue, exept the .9.png
Tryed the .9 patch tool but didn'd manage to change the .9.png without problems.
My ROM is deodexed, so this couldn'd be the problem.
When uploading the framework without recolored .9.png files the ROM works well.
Sent from my HTC Desire using Tapatalk
Nemesco said:
Problemen is half solved. I re-colored all green icons to blue, exept the .9.png
Tryed the .9 patch tool but didn'd manage to change the .9.png without problems.
My ROM is deodexed, so this couldn'd be the problem.
When uploading the framework without recolored .9.png files the ROM works well.
Sent from my HTC Desire using Tapatalk
Click to expand...
Click to collapse
If you're only changing colors you can modify a .9 with PhotoShop or Gimp just do not touch the black patch lines around the edges and they have to be decompiled then recompiled in order for it to work properly. The way I personally do theming of system apks is as follows:
Decompile apk with apktool.
Modify the images I want to change. Compile with apktool.
Copy the new images from newly compiled apk to original apk.
Push apk to proper location to test.
If you make xml changes you will need to copy those as well as the newly compiled resources.arsc file. You only need the resources file if you change xml files though.
Sent from my ADR6300 using XDA App
ellisperkins said:
I've looked through many posts. I am very new to creating my own Rom's, and I am having a problem after editing framework-res.apk. I started by downloading a popular rom for the Evo 3D, and decompiled it, edited framework-res, and after flashing the rom it wouldn't boot past the startup animation. The screen just remained black, but the capacitive buttons remained lit. Heres my process:
1.) Download the rom I desired.
2.) Extract zip
3.) Locate Framework-res.apk, copy, paste on desktop.
4.)Extract framework-res.apk, edited icons to my liking.
5.) Delete Meta-inf.
6.) Compress framework-res back to .zip, then to .apk.
7.)Sign Framework-res.apk.
8.) Replace framework-res.apk in my desired rom.
9.) Go into Meta-inf, delete Cert.RSA, Cert.SF, Manifest.MF (everything but the com folder)
10.) Re-sign .zip
11.) Flash via CWM, reboot, see Android startup animation, black screen?!!?!?
I am 99% I didn't change any dimensions of any of the images, and I re-signed everything perfectly. I know my mistake(s) are probably very noob, but as of now, I can't figure out what I am doing wrong. Any help would be greatly appreciated!
(Before you say anything, I have searched the forums several times, with no luck. I also tried this process several times, only editing one.png in framework-res, and I still get the same result.)
Click to expand...
Click to collapse
Without signing and deleting meta-inf. Just extract it with winzip, past ur png s then rezip it. It should work.
Sent from my GT-I9100 using xda premium
Open rom with 7-zip, open framework inside 7-zip, pull the folder to your desktop and keep 7-zip open, edit your pngs, drag folder back into 7-zip, accept changes, press back til it asks you if you wanna update framework inside the zip, select yes. Flash rom. Profit.
.9 editing (assuming you have eclipse set up, google how to)
Same steps as above until where you edit the pngs, copy the .9 files to a new folder on the desktop, name it 9pngs (or whatever), remove the .9 just make it a png (background.9.png to background.png), edit the colors, open draw9patch, color in the whole right side and bottom all black, then place one black dot in the middle of the top and one black dot in the middle on the left side (this might not work on every one, but it has worked fine on every one ive edited, theres more info on how to use draw9, google is your friend), save the image, this will make it a .9 but it wont be recognized by android til putting it thru eclipse, do the same with all of the images, open Eclipse, start new android project, name it whatever you want, open the project folder, go to res, drag all images to appropriate folder, right click on the project folder, choose android tools, extract unsigned application, open the application you made with 7-zip, drag out the images into your drawable folder, insert folder into framework inside of 7-zip, back out of 7-zip until it asks if you want to update framework inside of zip, select yes, flash rom, profit.

Need Help

Posted it here because i need a dev.
I pulled my Framework-res.apk and modified all the icons for everything. I decompiled using apktool.
My question is what steps do i take now (do i need to sign it, what a good tool to recompile it as apktool does and gives me a framework-res.apk but caused my phone not to boot up)..also someone said seomthing about resources.arsc or something..not sure where to go...thanks for your help.
Open ur new apk using 7zip (righr click>7zip>open archive) and do the same with ur old one. Delete the resources.xxxx(i dont know the name by heart lol) and drag and drop the one (by one i meant the resources.xxxx file) from the new zip to the old zip and adb push ur old frameworkres apk and reboot
Sent from my PG86100 using XDA App
kpkimmel said:
Posted it here because i need a dev.
I pulled my Framework-res.apk and modified all the icons for everything. I decompiled using apktool.
My question is what steps do i take now (do i need to sign it, what a good tool to recompile it as apktool does and gives me a framework-res.apk but caused my phone not to boot up)..also someone said seomthing about resources.arsc or something..not sure where to go...thanks for your help.
Click to expand...
Click to collapse
sounds more like a question. Use apk manager and or 7zip
how does just that one file carry over all the new pics and stuff i changed...
edited......
What exactly have you edited? If you just change non patch9 images... then you can just drag and drop the new images into the apk (may have to rename apk to zip).
If they are patch9's... you need to..
decompile framework-res.apk (apktool d framework-res.apk)
swap out images
recompile (apktool b framework-res)
Now take the newly compiled apk (in the /dist folder). Open it up and take the edited images (only the ones you need changed) and put them into your original apk.
No need to resign just push it to your phone and verify that it works
If you are editing xml files in /values* or /layout..
do the same as above, except after re-compiling, you're going to swap over the resources.arsc file to the original apk.
This is using apktool... in my experience apk manager doesn't do the job to my expectations... so i just do it manually with apktool.
Lemme know if u need anything more, or if i didnt touch on a specific situation.
Btw, maybe to combat the retarded comments about q&a and being in the right section... maybe turn the OP into a How-To?
preludedrew said:
What exactly have you edited? If you just change non patch9 images... then you can just drag and drop the new images into the apk (may have to rename apk to zip).
If they are patch9's... you need to..
decompile framework-res.apk (apktool d framework-res.apk)
swap out images
recompile (apktool b framework-res)
Now take the newly compiled apk (in the /dist folder). Open it up and take the edited images (only the ones you need changed) and put them into your original apk.
No need to resign just push it to your phone and verify that it works
If you are editing xml files in /values* or /layout..
do the same as above, except after re-compiling, you're going to swap over the resources.arsc file to the original apk.
This is using apktool... in my experience apk manager doesn't do the job to my expectations... so i just do it manually with apktool.
Lemme know if u need anything more, or if i didnt touch on a specific situation.
Btw, maybe to combat the retarded comments about q&a and being in the right section... maybe turn the OP into a How-To?
Click to expand...
Click to collapse
Thank you very much..finally...one last question, where do i put the wallpaper so when the system is fully booted it shows the wallpaper i want? Thanks.
kpkimmel said:
Thank you very much..finally...one last question, where do i put the wallpaper so when the system is fully booted it shows the wallpaper i want? Thanks.
Click to expand...
Click to collapse
There's an xml edit for it... but forgot it off the top of my head... quickest way is to replace system/customize/resource/shows_over.jpg with your image.
preludedrew said:
There's an xml edit for it... but forgot it off the top of my head... quickest way is to replace system/customize/resource/shows_over.jpg with your image.
Click to expand...
Click to collapse
Thanks you, sorry about the stupid framework-res question...i knew the answer but had been so long forget the simplest of steps....instead of normal compression i was using store instead.....duh.......thank you though for the reminder because 7zip will automatically restore the same it was decompressed with, unlike that crap winrar. Have a good one man and thank you again.

Recompling an apk questions

Trying to modify contacts.apk to make the dialer multi-dpi compatible. Did that and it works.
My issue is recompiling the apk. Everytime I recompile the apk with apktool it looses over a megabyte in size. In my case went from 4.49MB to 3.19MB after rebuilding. Only file modified was dialer_app.xml and it's size stayed about the same.
I've brought framework-res.apk and twframework.apk into apktool. After copying the resulting contacts.apk back to the device it is not recognized.
I've also tried copying the META-INF directory from the original apk over to the new one. Still no luck. I'm new to this and if anyone has some help for me it would be greatly appreciated!
Did you sign your new apk after recompiling it ?
Do you have classes.dex and resources.arsc files in your new apk ?
since its a system apk I've read it shouldn't be signed. Only thing I did was copy the META-INF folder to the new apk. In the new apk I do see classes.dex and resources.arsc. All the files appear to be there but the apk has shrunken in size.
I'm guessing I'm missing something simple here. But I'm new to this. Been at it for a few hours haven't had any luck.
I am new in development field. I have two questions 1. Is there same meaning for building and recompiling using apk tool? 2. I know framework-res.apk is needed for apktool d com, but where and the what is the use of twframework.apk file. Please explain anyone .
Recompiled apks will be quite a bit smaller as they will have more compression applied, this is normal, just be careful as if the tool compresses it to much you will get fc's. But it should work fine.
idhbar said:
I am new in development field. I have two questions 1. Is there same meaning for building and recompiling using apk tool? 2. I know framework-res.apk is needed for apktool d com, but where and the what is the use of twframework.apk file. Please explain anyone .
Click to expand...
Click to collapse
Read the apktool website for info about framework files, as far as which one to use, if you are decompiling a la2 or la4 base use a kl2 or kk5 framework without jkays built in as the laX frameworks are kinda buggy.
Sent from my GT-I9100 using Tapatalk

Categories

Resources