Help- Not able to sucessfully recompile samsungcamera apk - Galaxy S III Q&A, Help & Troubleshooting

Hi.
I extracted samsungcamera from qsrom 4.4.2 i9300 nl1, and decompiled it using apktool.
then I modified smali files and replaced
"com.sec.android.gallery3d" to "com.alensw.PicFolder"
"com.sec.android.gallery3d.app.Gallery" to "com.alensw.PicFolder.GalleryActivity"
but after recompiling it with some error I got new modified class ,resourceses, and other xmls,
then I opened original samsungcamera.apk and replaced inside with new class, recources and xmls, and then pushed new samsungcamera.apk in system app gave proper permissions , installed quickpic and restarted,
after restart camera icon shows in app drawer but when opened it force-closes.
if someone with knowledge could could modify samsungcamera the it would be great help, ThankYou
files used
quickpic- http://forum.xda-developers.com/android/apps-games/app-quickpic-v4-5-2-classic-version-t3204543
samsung camera apk decompiled and modified - http://d-h.st/IdeC
samsungcamera original in attachment

Related

howto de/compile systemui.apk without any error

Hello,
I wanted to de/compile the systemui.apk and got errors.
I installed framework-res.apk with apktool.
After installation I used apktool (Win7) and decompiled the systemui.apk.
But I got the same errors as many others have gotten them.
brut.blahblahblah..
So I tried other apktool.jar (apktoolICS.jar) and it worked fine!
I opened the new systemui folder and there are the following folders:
res and assets
no smali folder. is it right and normal?
Because the compiling with old apktool (not apktoolICS) didn't work, I compiled with the ICS file and it worked. I got the translation message (airplane_mode).. Not interesting for me atm.
When I look at the new built systemui.apk, I wondered about the file size.
The new file: 1.009kb
The old file: 1.338kb
I signed the new file. Now the file size is 1.044kb.
I edited only a xml file (styles.xml)..
The file didn't work on the sgs2..
Could someone tell me what I did wrong?
Please help me
Best regards
Marcus
*push* after moving to correct section
maybe no need to sign your new file,
try to drag the META-INF folder and the AndroidManifest.xml from the older file to the new file you build
BTW, is your old systemui file a deodex one?
if no deodex, the smali code wil include in the odex file~

[Q] Problem with apks (de)compiled with apktool

I made some changes to my SystemUI.apk, and I pushed it back, then rebooted, only to find my status bar had disappeared.
So, I restored to my backup, and made 4 copies of the SystemUI.apk to try to find out where the problem lay.
Copy 1: No change
Copy 2: Decompiled and Compiled with apktool. No other change.
Copy 3: Decompiled with apktool. Changed one png. Compiled with apktool
Copy 4: Decompiled with apktool. Edited text in strings.xml and changed a few colours. Compiled with apktool.
Out of these 4, only the first one worked. The rest had my status bar gone. Hence I have arrived at the conclusion that something had gone wrong in either the compiling or decompiling stages. I didn't sign the apk because I read that system apps should not be signed.
Just to make sure, these were the steps I took.
1. Retrieve SystemUI.apk, framework-res.apk, and SemcGenericUxpRes.apk
2. Install frameworks with apktool
3. Decompile SystemUI.apk
4. Make any changes
5. Compile
6. Place on SD card
7. Change \system\ to be RW
8. Copy SystemUI.apk from sd card, and overwrite the one in \system\app
9. Ensure permissions are set to rw-r-r (644)
I have not much idea what else could have gone wrong, but then again, I'm just a newbie who follows others' guides and might have missed out on doing something. Perhaps some kind soul would be able to point that out?
Well, apktool is using smali/baksmali to compile/decompile classes.dex/apk_name.odex file.
The problem can occur when you use different baksmali version when you decompile and also not the right version to compile (as the system expects it to be). You can also experience issues if the apk is not zipaligned properly (check down who to do that)
apktool has the smali/baksmali code inside it so you will need to get the newest version for it for JB for example.
You can check why the status bar is not there when you monitor the logcat and look for DEX related logs in the beginning.
You can also use smali/baksmali on your own: http://code.google.com/p/smali/wiki/DeodexInstructions
and just place the generated classes.dex in the apk
then zipalign -f 4 filein.apk fileout.apk (http://developer.android.com/tools/help/zipalign.html)
then push back fileout.apk (sytemui.apk in your case)

[DEV][REQ]Decompile systemui.apk

Hello, i would like to modify this systemui.apk but everytime i decompile and then recompile the apk it is no longer functional and is of a smaller size.For example, i decompiled and recompiled the apk without any modifications and then signed it but the file was 2.25mb instead of 2.53mb and didn't function
so can you please decompile the apk and recompile the apk, if it is about 2.5mb please upload the decompiled folder
I have uploaded the systemui.apk nd framework-res.apk
thank you

[Q] change the background Toggle the status bar notifications

Hi
Very please help
The rom 4.1.2 I could using winrar for simple to change png to another png
Now I'm on 4.4.2 (DittoNote 5.2).
I want to change the png (tw_quick_panel_quick_setting_button_bg_normal.9 ???)
I think it is png a background toogles
I change my png i using winrar but nothing changes.
It is still the old png and no new png.
For what is this happening?
png's ending with 9 are not ordinary png's, they are 9-patch png's and in order to edit them you must DECOMPILE the APK, edit and then RECOMPILE. Anyway, simple adding with winRAR is nota good idea if you don't do ZIPALIGN because it slows down the reading of images....
Ah, and why post a question in app section, isn't Q&A more logical choice?
So I should do this in the Q & A - my mistake.
Ok thanks for the information.
delanik - this is just an example:
I'm trying to change the png in Note 5.2 Ditto 4.4.2
Is the file is tw_quick_panel_quick_setting_button_bg_normal.9 is background switches?
I exchange tw_quick_panel_quick_setting_button_bg_normal.9 another png
with another theme rom Note 2 but nothing has changed.
As I said - pngs with 9 at the end CAN'T be edited without recompiling. Use APKTOOL to decompile APK, then edit, then RECOMPILE. Then from recmpiled APK, copy PNGs (or whole res\drawable folder) to original APK.
If it doesn't change (and it should even when you don't do recompile - it should show BAD image) then you are not editing correct image.
Thank you very much dalanik
I SystemUi decompile framework-res.apk and now the rom DN4 v2.
It will be very difficult for me because there is a lot of files QMG
There is no custom QMG files (icons, button ....) in other roms or themes
to replace them in my rom DN4 v2

Help! troubles compiling framework-res (oreo)

I need some help after editing the framework res of my device to change the round icon bool value system wide, it is quite simple following this guide
But, I got errors when trying to recompile. I already installed all the framework apk's found inside system/framework (I will include them 2 apks + the logs and decompiled files in the link below)
https://drive.google.com/open?id=1TPuMyHh9hgjt6ev0g2feJc_Od5m_wvrY
Device is: HTC U11 stock Oreo ROM

Categories

Resources