Which apktool ???????? - Moto G7 Power Guides, News, & Discussion

Hey I have a g7 power
I use super RS kitchen to extract the payload.bin files and then it automatically opens the .IMG files
So when I go to decompiles an app it's fine works like a charm
But when recomiling
It throws out errors about the pip_ scrim9 png and will not recompile does anyone know what to do to fix this or
Another tool that is completely successful in decompiling and recompiling.. .???????

Related

Sign apk's on mac os x

First of all: I'M SORRY FOR ASKING THIS!
But, I'm trying to edit some drawables in the framework-res and in a couple other apk's but my problem is resigning them. I followed this tutorial http://www.androiddevelopment.org/tag/apk/
I changed the .apk to .zip to open it and access the drawables but when I open the .zip file it opens it in another folder, not like winrar or whatever for windows. So after I edit what I need and recompress the file, I can't change it back to .apk. So I try signing the apk as a .zip but the signing tool thinks it's a update.zip and signs it that way.
Basically, is anyone able to successfully resign apk's on a mac? If so, how?
Thanks
make sure you rezip the files inside the folder, then either sign that zip or open the info window (command+i) and rename the extension to apk there.
circa85 said:
make sure you rezip the files inside the folder, then either sign that zip or open the info window (command+i) and rename the extension to apk there.
Click to expand...
Click to collapse
Yeah I just figured out I have to open the info window to rename to .apk. And now the signing goes smoothly.
This thread is a waste, sorry, I'm an idiot.
Actually, I'm still having an issue. Here is an example of what happens:
Say I rename framework-res.zip to framework-res.apk (after editing, and recompressing) and then I use the signing tool to sign framework-res.apk. If I change it back to .zip and decompress it, there are two files in it. There is a folder called "framework-res" and a folder called "META-INF". Nothing else. The AndroidManifest.xml is inside the framework-res folder. This happens with every apk I try to sign
what are u using to sign apk's on mac? I was tryin to get this working long time ago but gave up. them I found the method using automator and it resigns them but idk if it actually wrks. i tried editing stuff resigning and flashing but i got like 770 files unsigned. unless I just didn't know how to resign an update.zip properly..
jroid said:
what are u using to sign apk's on mac? I was tryin to get this working long time ago but gave up. them I found the method using automator and it resigns them but idk if it actually wrks. i tried editing stuff resigning and flashing but i got like 770 files unsigned. unless I just didn't know how to resign an update.zip properly..
Click to expand...
Click to collapse
I'm using the script in the tutorial I posted in the original post
The script just uses the Jarsigner tool. So I'm using Jarsigner to sign my apks
Oh ok. I might have to try this out. Question: what is the proper way of signing an update.zip after u edited framework.Res or. Apks? I'm confused when it comes to that. Must u resign every single file in the. Zip for it to work?
I went as far as rebuilding the apk, but not sure how to resign. I tried to install anyway without signing, but the installer hangs while checking for version and gives network error after some time. I found a http://code.google.com/p/signapk and tried to use it on mac, but seems like it needs to be run on android itself. When I tried to run it on android, I get permission error, though I did a chmod +x as su. Could you give some more details on where to get the tool and use it?

edit framework-res.apk no boot!

i have all frameworks and apps deodexed
i made some changes on a framework-res.apk then i have repacked it, signed, flash on my rom.
but it no boot, stay ever on "HERO" screen!
i try to modify com.htc.resource.apk , flashing it, and all ok!!
anyone can help me?
M
You can't sign the framework file with a test key! Same applies to Rosie - don't try to re-sign it, or it'll just bootloop.
Just edit the files directly in the zip using 7-zip or something like that
Woops ^^, sounds like your implementing Manup456 SenseHero theme...
Stickman89 said:
Woops ^^, sounds like your implementing Manup456 SenseHero theme...
Click to expand...
Click to collapse
yes but with some changes to color map.. and maybe to components
M
nprussell said:
You can't sign the framework file with a test key! Same applies to Rosie - don't try to re-sign it, or it'll just bootloop.
Just edit the files directly in the zip using 7-zip or something like that
Click to expand...
Click to collapse
yayyyy haha i don't like working on a theme
M
i am on a mac.. i have 7zip ecc ecc but i can't edit without unrar the archive!
help!
just repack the framework-res.apk,dont sign it and it will flash fine
it wont work if you repack framework-res.apk as the classes.dex cannot be compressed, youll notice if you extract a 3mb framework-res, recompressing it makes it 1.5mb
ok so:
1- rename framework-res.apk to framework-res.zip
2- unarchive it
3- do changes
4- recompress all? file into a .zip
5- mv ./framework-res.zip ./framework-res.apk
6- push into the /system/framework directory
right?
mr.bang said:
ok so:
1- rename framework-res.apk to framework-res.zip
2- unarchive it
3- do changes
4- recompress all? file into a .zip
5- mv ./framework-res.zip ./framework-res.apk
6- push into the /system/framework directory
right?
Click to expand...
Click to collapse
Yes, but you must choose to pack in a zip without compression
after renaming to .zip and doing the work just rename to .apk no need to repack that
eriously, im getting pretty tierd of this....
I`ve followed your tutorial (slaved) and it seems to be working awsome, BUT I did it with my own ROM and called it Update.zip and I did everything you said, even let the 9. files alone, but when I'm restarting the system, the boot window is there constantly/for ever, what is wrong?
mr.bang said:
i am on a mac.. i have 7zip ecc ecc but i can't edit without unrar the archive!
help!
Click to expand...
Click to collapse
Make sure you have zip (the package) installed.
You should also install a MAC port of the midnight commander.
Browse to your framework apk and just enter it via mc. It should recognize the magic bytes as ZIP and enter VFS mode, allowing you to enter the apk just as if you were entering a folder.
After you make all your changes (I guess simply overwriting some pngs), just exit from the folder through ".." till you see the apk itself.
There. Done.
I do my cooking on a linux workstation, and this is one way of doing it.

[Q] Notepad++ help

How to configure notepad++ for editing XML files.
While trying to open XML file i got the way show in attached image
Please help...............
Thanks in advance.
chiragvagh said:
How to configure notepad++ for editing XML files.
While trying to open XML file i got the way show in attached image
Please help...............
Thanks in advance.
Click to expand...
Click to collapse
I suspect this xml is from an apk. I also had this problem, and it turns out that notepad++ only opens xml that are in NORMAL zips, and not from APKs
Press the thans button if I helped
Isnt there a way to edit xml files using Notepad++.
I had even tried xml from normal zips, I get the same screen
You need to decompile the apk first.
Dear,
I am not trying to edit APK, this file is AndroidManifest.xml from framework-res.apk.
I have decomplied framework-res.apk using winrar and than opened AndroidManifest.xml in Notepad++.
but as you can see attached image above i got.
Please help.......
chiragvagh said:
Dear,
I am not trying to edit APK, this file is AndroidManifest.xml from framework-res.apk.
Click to expand...
Click to collapse
So you are trying to edit an apk then, which has to be decompiled first, and doesn't look like you have. This is what my AndroidManifest looks like in NP+...
EDIT: Choose the second option under Encoding on the menu bar and see if that changes anything if you have decompiled.

How to reodex framework of stock rom ?

I wanted to increase number of volume step following this (http://forum.xda-developers.com/showthread.php?t=1411317&page=20)
I pulled the framework.odex and baksmali it but it didn't work because of dependency or something like that. Then I pulled all the odex file in there and succesfully baksmali framework.odex
I edited the smali file needed and then smali it to framework.dex. This is where I'm stuck.
The original framework use odex file, not dex file. So I guess I need to reodex the framework.dex to odex. But all the guides I found about reodex seem to be used for cooked rom, the jar files all have classes.dex in it and there 's no odex file.
Then I tried to put framework.dex into original framework.jar file (after change its name to classes.dex), use command "dexopt-wrapper framework.jar framework.odex", and overwrite the original framework.odex. The device coudn't start, it stuck at "nokia" text (is it called bootloop?)
So what is the proper way to do it ? Thanks
PS: I did it. There is a very similar example here, I missed a few thing: http://www.jordanhotmann.com/2011/08/how-to-change-default-orientation-of.html
MarryJ said:
I wanted to increase number of volume step following this (http://forum.xda-developers.com/showthread.php?t=1411317&page=20)
I pulled the framework.odex and baksmali it but it didn't work because of dependency or something like that. Then I pulled all the odex file in there and succesfully baksmali framework.odex
I edited the smali file needed and then smali it to framework.dex. This is where I'm stuck.
The original framework use odex file, not dex file. So I guess I need to reodex the framework.dex to odex. But all the guides I found about reodex seem to be used for cooked rom, the jar files all have classes.dex in it and there 's no odex file.
Then I tried to put framework.dex into original framework.jar file (after change its name to classes.dex), use command "dexopt-wrapper framework.jar framework.odex", and overwrite the original framework.odex. The device coudn't start, it stuck at "nokia" text (is it called bootloop?)
So what is the proper way to do it ? Thanks
PS: I did it. There is a very similar example here, I missed a few thing: http://www.jordanhotmann.com/2011/08/how-to-change-default-orientation-of.html
Click to expand...
Click to collapse
It's really great that you created something for yourself. But what will be even more greater, if you shared it withe community. So I advise that when you finish with this project and if successful, upload it so that we can also admire your work.

[Q] xml problem

hey guys i want to edit twstatusbar.xml with notepad++ but every time I open the file i just get this weird wording or lettering is something wrong?
Note this also happens with other xml files too!
here is a screenshot:
View attachment 2792773
JT1510365 said:
hey guys i want to edit twstatusbar.xml with notepad++ but every time I open the file i just get this weird wording or lettering is something wrong?
Note this also happens with other xml files too!
here is a screenshot:
View attachment 2792773
Click to expand...
Click to collapse
You have to de-compile the apk first, then you can edit it in plain text; then you must re-compile the apk.
gr8nole said:
You have to de-compile the apk first, then you can edit it in plain text; then you must re-compile the apk.
Click to expand...
Click to collapse
okay i have been having trouble at getting apktool setup on my computer. i have looked at all the guides but still can't get it to work!
would you be so kind as to help me set it up on my computer via this messaging way?
also I want to edit .9 pngs and how would i do that properly?
apktool
also do i need the java sdk for apktool because everytime I download from the java website and try to install it it says that its not a valid file
JT1510365 said:
okay i have been having trouble at getting apktool setup on my computer. i have looked at all the guides but still can't get it to work!
would you be so kind as to help me set it up on my computer via this messaging way?
also I want to edit .9 pngs and how would i do that properly?
Click to expand...
Click to collapse
JT1510365 said:
also do i need the java sdk for apktool because everytime I download from the java website and try to install it it says that its not a valid file
Click to expand...
Click to collapse
Any of the toolkits for de-compiling apks should work fine. I still use a very old one (APK Manager 5.0.2). I just update the apktool, baksmali, and smali jar files when an updated version is released.
You will need java installed, but I don't think you need the entire sdk.
As for editing .9 pngs...you have to make sure that you don't change the 1 pixel border around the outer edge of the image.
now what
gr8nole said:
Any of the toolkits for de-compiling apks should work fine. I still use a very old one (APK Manager 5.0.2). I just update the apktool, baksmali, and smali jar files when an updated version is released.
You will need java installed, but I don't think you need the entire sdk.
As for editing .9 pngs...you have to make sure that you don't change the 1 pixel border around the outer edge of the image.
Click to expand...
Click to collapse
okay where do i go to download the tool and those files like backsmali?
Also I heard you can't decompile systemui.apk unless you put your devices framework-res.apk in the apktool folder, where would that go?
thanks for your help!
JT1510365 said:
okay where do i go to download the tool and those files like backsmali?
Also I heard you can't decompile systemui.apk unless you put your devices framework-res.apk in the apktool folder, where would that go?
thanks for your help!
Click to expand...
Click to collapse
Give this a try...it should work http://forum.xda-developers.com/showthread.php?t=2536073
latest Smali and baksmali here https://bitbucket.org/JesusFreke/smali/downloads
gr8nole said:
Give this a try...it should work http://forum.xda-developers.com/showthread.php?t=2536073
latest Smali and baksmali here https://bitbucket.org/JesusFreke/smali/downloads
Click to expand...
Click to collapse
I downloaded the tool and when i tried to open the tool it just crashed

Categories

Resources