yashsingh1/xdaforums huggingface dataset:
[Android Software Development] Spannaa:
You can decompile them, but they may not work on your device when you've edited and compiled them again.
[Android Software Development] Sensible_Smarty:
I dont use recompiled files,,, just copy the modified resources to the original file...

still there a problem with that,, in the new nougat?
[Android Software Development] Spannaa:
You'll need to try it for yourself but, since you're still replacing resources, the modified apk may not work.
[Android Software Development] djdarkknight96:
I've modified apps from playstore and used them on N no problem..haven't tried system apk but I did flash a themed hangouts to system successfully.
[Android Software Development] Sensible_Smarty:
U are a big dev,, we still noobs

:p
[Android Software Development] TONY6669:
A very helpful big dev....

Sent from Gurple Tapatalk
[Android Software Development] surdu_petru:
Ok !

Thank you very much for your effort to help me !

Here it is -> in archive system.zip :good:

...sorry , I'll upload now on rapidshare , because I think you need to wait 30 min for the second download ! Here it is on rapidshare !
[Android Software Development] surdu_petru:
Hi!

...seems to be some issue when you try this command > apktool if com.htc.resources.apk ! -> it decompile successfuly Phone.apk but with some issue ....that's why you can not recompile Phone !

- first you need to eliminate any issue on > apktool if com.htc.resources.apk !

Take a look here : decompiled/recompiled your files -> seems to be the same error when try to recompile Phone !

I hope that someone will find a solution ! Good luck ! :good:
[Android Software Development] zozor:
You are right.I installed the com.ressources.apk with some error.I didnt find way to come accross it.
[Android Software Development] surdu_petru:
Hi iBotPeaches !

... do you think that you could find a solution to my problem ( re-compile SystemUI ) ?

...expect an update to aapt.exe or apktool.jar for solving issue on decompile/compile SystemUI - Android JB ...:confused:

Thanks for your great work ! :good:
[Android Software Development] cowsquad:
What jb ROM are you using?
[Android Software Development] surdu_petru:
Hi!

I gave all the details a little above ! Thanks !

( Official Stock Android 4.1.1 on Asus Transformer TF300T ! )
[Android Software Development] Lozone:
Is there any update on aapt for Mac?

Thx for the great work.

Sent from my HTC VLE_U using DroiDevs Premium Plus
[Android Software Development] ronak.super:
Hello people,

I have Decompiled CM9 systemUI.apk and while compiling I am getting this error

I am using Apktool of this thread(1.50) and also aapt posted in op.

Please can someone help me!?
[Android Software Development] jozka.1:
And why you don't compile directly from CM source?
[Android Software Development] ronak.super:
Have made some changes in xml's. btw I don't have cm source on my comp!
[Android Software Development] iBotPeaches:
Not fixable. That apk has been modified before. I've only encountered the issue below

(new resource id notification_popup_menu from /home/peaches/Downloads/system/deodexed/SystemUI/res/menu/notification_popup_menu.xml)
(new resource id recent_popup_menu from /home/peaches/Downloads/system/deodexed/SystemUI/res/menu/recent_popup_menu.xml)
Segmentation fault (core dumped)

On APKs that had been modified previously poorly. I have no information to go by, just a seg fault. Nothing I can do. Feel free to do any research and aid me in fixing it.

Nope. I don't have ROOT have University so I cannot use their computers to build Mac aapt. Someone with a MAC will have to do that for me.
[Android Software Development] surdu_petru:
Hi !

SystemUI.apk is the stock one ....so has not been modified before ! ....maybe Asus modified this .apk ...but how they managed to recompile :confused:

anyway thank you very much for your help ! I hope one day to be a solution :good:
[Android Software Development] rtfpessoa:
@iBotPeaches, when i decompile and recompile framework-miui-res.apk i still need to patch the apktool.yml by adding the extra frameworks.

Is this fixed and i'm doing something wrong or is still a bug?

If is fixed can you give me a little help?
[Android Software Development] iBotPeaches:
Theres nothing I can do about that :(

Those are dummy frameworks and theres no way to detect their usage during decompile because there never needed. They were made as a fix around in previous apktool versions. Xiaomi still uses v1.4.3 though. They haven't used mine yet. Then we shouldn't need it.
[Android Software Development] rtfpessoa:
Have you tried to tell them about it?

Your apktool is a very good work. Fixes a lot of bugs and brought back the lost project.

Try with MIUIAndroid to make them know better about this version of apktool so they use can it.

---------- Post added at 11:34 PM ---------- Previous post was at 11:03 PM ----------

BTW, anybody here deodexes roms?

Can you tell me the command you use with baksmali.jar?

I'm having some issues with the classpath.

Thanks,

Rodrigo
[Android Software Development] djmatt604:
Thanks for this. Just getting started in this world and happy to have access to such talented devs who can supply these tools. Appreciated!
[Android Software Development] iBotPeaches:
Deodex is a 3 step procedure.

1) java -jar /home/peaches/tools/baksmali.jar -a 16 -d "../framework" -x Antispam.odex

(That takes the ODEX file and decompiles it into raw form into the /out folder. Leave the ROM in its setup form. So you can handle it.)

2) java -jar /home/peaches/tools/smali.jar -a 16 -o classes.dex out

(This takes the /out folder, and builds it into a classes.dex file).

3) You merge that classes.dex file into AntiSpam.apk, using no compression. Just drop it into root of APK. So it has resources.arsc and classes.dex, and manifest etc.

There is no classpath needed as of 1.3.4 which you can get from here: http://miui.connortumbleson.com/other/jf/
[Android Software Development] michfood:
iBotPeaches

Hi, I`ve a problem with lenovo framework-res.apk.

It has been decompiled, but during compilation there is aapt.exe crash in windows and such log:

W: Could not find sources
I: Checking whether resources has changed...
I: Building resources...
Exception in thread "main" brut.androlib.AndrolibException: brut.common.BrutException: could not exec command: [aapt, p, --min-sdk-version, 15, --target-sdk-version, 15, -F, c:\Temp\APKTOOL6439396482208358489.tmp, -x, -S, C:\H7300_firmware_tool\firmware\4_decompiled_mod_to_edit\2_framework_decompiled_mod\framework-res\res, -M, C:\H7300_firmware_tool\firmware\4_decompiled_mod_to_edit\2_framework_decompiled_mod\framework-res\AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:255)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:324)
at brut.androlib.Androlib.buildResources(Androlib.java:269)
at brut.androlib.Androlib.build(Androlib.java:192)
at brut.androlib.Androlib.build(Androlib.java:174)
at brut.apktool.Main.cmdBuild(Main.java:188)
at brut.apktool.Main.main(Main.java:70)
Caused by: brut.common.BrutException: could not exec command: [aapt, p, --min-sdk-version, 15, --target-sdk-version, 15, -F, c:\Temp\APKTOOL6439396482208358489.tmp, -x, -S, C:\H7300_firmware_tool\firmware\4_decompiled_mod_to_edit\2_framework_decompiled_mod\framework-res\res, -M, C:\H7300_firmware_tool\firmware\4_decompiled_mod_to_edit\2_framework_decompiled_mod\framework-res\AndroidManifest.xml]
at brut.util.OS.exec(OS.java:83)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:253)
... 6 more

No matter which one - from sdk or yours.

What should I do?

And how can I use --verbose command?
[Android Software Development] cowsquad:
Did you installed framework-res.apk and all frameworks needed to find resources first?
[Android Software Development] Phone_Guru:
I've had lots of problems flashing themed apps on Nougat so it's a mixed bag.
[Android Software Development] djdarkknight96:
Also depends on if your odexed or not, stock or custom Rom..etc. I was testing DU, pure nexus and CM14 but never tried rooted stock.
[Android Software Development] Phone_Guru:
I had no problem in the alpha of JDC substratum ROM, could only flash play store to priv-app on JDC CM 14.1 and can't flash anything on JDC substratum beta 1
[Android Software Development] EMSpilot:
LG V20

I have tried deox, oxed Rom's on my V20 and if I change just one color code or one image the apk will fail. Seems I can mod non system apk's. Sure hope we can come up with a fix for this.

I am open to testing anything you all come up with.

Cheers
[Android Software Development] Ticklefish:
Have you tried disabling your signature checking? That should stop the v2 signature being checked.
[Android Software Development] EMSpilot:
Well here is my services.jar. http://d-h.st/YOwk I have attempted to disable it via smali with no success.

Any idea's on how to disable it?

Cheers
[Android Software Development] japeyk.gaming:
I managed to decompile, edit and recompile back to .apk a certain game that is 270mb size using the latest version of apktool. I tried to sign it using apk signer successfuly but when i tried to put in on my phone and install it, it says app not installed. What i am missing? Thanks
[Android Software Development] Ticklefish:
There's a guide here: http://xdaforums.com/showthread.php?t=2458144

I don't know if it'll work with Nougat though.

V2 signing works by creating a signature that's based on the contents of the APK. Change the contents of the APK and the signature's invalid. Google have released an 'apksigner' file in their latest Android Studio which can, in theory, sign APK files the V2 way but I haven't been able to get it to work yet.

As far as I'm aware (I don't have a Nougat rom to test it with), disabling signature verification should get around the issue of the V2 signature failing. Either that or you could resign every APK and JAR file in your system partition with something like testsign. In theory that should work but it's a lot of fuss.

Apktool's not really intended for modding apps from Google Play. It sounds like you needed to use the original signature but it could just be that there's something in the app itself that's stopping modded versions from running. It may even be the V2 signing at work.
[Android Software Development] djdarkknight96:
Did you uninstall the stock one first?
[Android Software Development] japeyk.gaming:
any other way to sort this out?

I tried both with and without the original game from playstore but got the same result...

anyone have an idea how they modified games like GTA on mobile? they changed the ingame surroundings,sound,image etc. and they able to recompile and rebuild the app.. thanks for the reply..
[Android Software Development] djdarkknight96:
Most games are mostly java based. Editing games with smali...Good luck lol

If you're unable to install the apk after signing then you might have signed it indirectly. Did you use test keys?
[Android Software Development] Phone_Guru:
Is it possible to Deodex a nougat ROM yet?
[Android Software Development] djdarkknight96:
I've seen comments of it being done but I haven't tried. I use AOSP.
[Android Software Development] Ab.Shaheen:
bto thanks for awesome tool, but i need some help, i want to know which framework shoild be used for id: 4

as framework-res is id: 1 and id 2 is SemcGenericUxpRes.apk,

i am decompiling xperia theme that i have created with xperia theme creator..
[Android Software Development] EMSpilot:
2.2.2

Does anyone have a 2.2.2 beta that works.

Cheers
[Android Software Development] Sh0X31:
Hi guys,

I decompile the framework-res.apk from my OnePlus 3 with Nougat (do I need the OnePlus Framework like from the HTC) and disable the Notification for Volume warning. After I recompile it and after I overwrite the framework-res.apk in my ROM. With the original framework-res.apk it does boot but the the edited one it do not but.
[Android Software Development] edzamber:
You can build it from source mate

https://ibotpeaches.github.io/Apktool/build/
[Android Software Development] WILMANS2M:
Hi,

I use apktool since a moment now but since Marshmallow i am not able to recompile a working apk. I own a samsung s5 neo and try to mod the mms apk. I change some smali code and xml file. I have (even without editing anything) when recompiling a warning: Failed resolving ResTable_map. ....when i copy (after signing it) the modded apk into the phone, rebooting and wiping cache/dalvik my apk FC. After the 3rd FC, i can use it until next reboot. I do not undersand as i had no problem when modding apk on Lollipop. Tried 2.2.0 ad 2.2.1: The same. Any suggestion ? Really thank you in advance.

Envoyé de mon SM-T800 en utilisant Tapatalk
[Android Software Development] Sh0X31:
in this case I do it with apktool v2.2.1 and with the oneplus framework but it do not help. I copy the meta folder from the original framework-res.apk in the new one and it stillt not boot up. With the original file works.
[Android Software Development] dhruvpatel_9880:
Please tell how you resolved the problem , I am also getting the same problem.
[Android Software Development] bovirus:
[MENTION=3801078]iboat[/MENTION]peaches

With latest update in the repository I got this error

:brut.apktool:apktool-lib:processTestResources

:brut.apktool:apktool-lib:testClasses

:brut.apktool:apktool-lib:test

brut.androlib.BuildAndDecodeTest > unicodeAssetTest FAILED

java.lang.AssertionError

at org.junit.Assert.fail(Assert.java:86)

at org.junit.Assert.assertTrue(Assert.java:41)

at org.junit.Assert.assertTrue(Assert.java:52)

at brut.androlib.BuildAndDecodeTest.compareBinaryFolder(BuildAndDecodeTest.java:435)

at brut.androlib.BuildAndDecodeTest.compareAssetsFolder(BuildAndDecodeTest.java:447)

at brut.androlib.BuildAndDecodeTest.unicodeAssetTest(BuildAndDecodeTest.java:382)

I tried to download it as fresh package, to compile with JDK 1.7 (is it right?) with JDK 1.8 but I always got this error.

---------- Post added at 12:54 PM ---------- Previous post was at 12:29 PM ----------

[/COLOR [MENTION=3801078]iboat[/MENTION]peaches

With latest update in the repository I got this error

:brut.apktool:apktool-lib:processTestResources

:brut.apktool:apktool-lib:testClasses

:brut.apktool:apktool-lib:test

brut.androlib.BuildAndDecodeTest > unicodeAssetTest FAILED

java.lang.AssertionError

at org.junit.Assert.fail(Assert.java:86)

at org.junit.Assert.assertTrue(Assert.java:41)

at org.junit.Assert.assertTrue(Assert.java:52)

at brut.androlib.BuildAndDecodeTest.compareBinaryFolder(BuildAndDecodeTest.java:435)

at brut.androlib.BuildAndDecodeTest.compareAssetsFolder(BuildAndDecodeTest.java:447)

at brut.androlib.BuildAndDecodeTest.unicodeAssetTest(BuildAndDecodeTest.java:382)

I tried to download it as fresh package, to compile with JDK 1.7 (is it right?) with JDK 1.8 but I always got this error.
[Android Software Development] iBotPeaches:
Looks like you need to update your environment a bit, its choking on unicode characters. Both Travis and my mac/unix computers are fine. I would look into your system.
[Android Software Development] bovirus:
[MENTION=3924617]iBotPeaches[/MENTION]

Before the last update (4 days ago) the developping system worked fine.

I'm using Windows 7 Professional 64bit.

Im using JDK 1.7.0.80 or 1.8.0.112 (both 64bit)

What are the changes that I need to use latest build?

Are you sure that the changes made in alst 4 days are compatible with Windows system (you tested them on Mac/Linux)
[Android Software Development] blackbile:
Hello!

I used apktool (on Windows 10 64bit machine) 2.2.1 and 2.2.2 and 2.2.2.a on Xiaomi MIUI v8 ROM.

The decompile and recompile is perfect with non framework files.

But I have problem recompiling framework files if I tried using 2.2.1 version: miui.apk, miuisystem.apk, smsextra.apk, etc.

Otherwise if I tried the 2.2.2a version I had to edit the yml file in the decompiled directory of the apk and insterted some more framework ids sometimes I could recompiled but there were warnings. I pushed all the files to the phone and didnt started.

Is there any solution to recompile the MIUI v8 framework files without any error and warning?
[Android Software Development] edzamber:
Build it under Cygwin [emoji6]
[Android Software Development] bovirus:
[MENTION=4507636]edzamber[/MENTION]

I believe that the tool should work fine under Windows without Linux emulation (as worked before latest changes).

The use of native Window just require JDK.

The use of cygwin require hdd space, knlowedge and other.
[Android Software Development] edzamber:
Hummm same problem with cygwin for me... Last build can't build...

My java version :

$ java -version
java version "1.8.0_112"
Java(TM) SE Runtime Environment (build 1.8.0_112-b15)
Java HotSpot(TM) 64-Bit Server VM (build 25.112-b15, mixed mode)

Building SNAPSHOT (master): 0571cc
:compileJava UP-TO-DATE
:processResources UP-TO-DATE
:classes UP-TO-DATE
:jar
:assemble
:compileTestJava UP-TO-DATE
:processTestResources UP-TO-DATE
:testClasses UP-TO-DATE
:test UP-TO-DATE
:check UP-TO-DATE
:build
:brut.apktool:compileJava UP-TO-DATE
:brut.apktool:processResources UP-TO-DATE
:brut.apktool:classes UP-TO-DATE
:brut.apktool:jar
:brut.apktool:assemble
:brut.apktool:compileTestJava UP-TO-DATE
:brut.apktool:processTestResources UP-TO-DATE
:brut.apktool:testClasses UP-TO-DATE
:brut.apktool:test UP-TO-DATE
:brut.apktool:check UP-TO-DATE
:brut.apktool:build
:brut.j.common:compileJavawarning: [options] bootstrap class path not set in conjunction with -source 1.7
1 warning

:brut.j.common:processResources UP-TO-DATE
:brut.j.common:classes
:brut.j.common:jar
:brut.j.common:assemble
:brut.j.common:compileTestJava UP-TO-DATE
:brut.j.common:processTestResources UP-TO-DATE
:brut.j.common:testClasses UP-TO-DATE
:brut.j.common:test UP-TO-DATE
:brut.j.common:check UP-TO-DATE
:brut.j.common:build
:brut.j.util:compileJavawarning: [options] bootstrap class path not set in conjunction with -source 1.7
Note: C:\cygwin64\home\Sandrine\Apktool\brut.j.util\src\main\java\brut\util\Duo.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
1 warning

:brut.j.util:processResources UP-TO-DATE
:brut.j.util:classes
:brut.j.util:jar
:brut.j.dir:compileJavawarning: [options] bootstrap class path not set in conjunction with -source 1.7
1 warning
[Android Software Development] bovirus:
[MENTION=3924617]iBotPeaches[/MENTION]

Compilation error using lates source version with Linux 16.04.1 64bit / JDK 1.8.0.102 64bit

brut.androlib.BuildAndDecodeTest > classMethod FAILED

brut.androlib.AndrolibException: java.io.FileNotFoundException: /tmp/BRUT1650582648425427830.tmp/testapp-orig/unknown/nonprintable.file (No such file or directory)

at brut.androlib.Androlib.buildUnknownFiles(Androlib.java:602)

at brut.androlib.Androlib.build(Androlib.java:318)

at brut.androlib.BuildAndDecodeTest.beforeClass(BuildAndDecodeTest.java:55)

Caused by:

java.io.FileNotFoundException: /tmp/BRUT1650582648425427830.tmp/testapp-orig/unknown/nonprintable.file (No such file or directory)

at java.io.FileInputStream.open0(Native Method)

at java.io.FileInputStream.open(FileInputStream.java:195)

at java.io.FileInputStream.<init>(FileInputStream.java:138)

at brut.util.BrutIO.copy(BrutIO.java:78)

at brut.androlib.Androlib.copyUnknownFiles(Androlib.java:655)

at brut.androlib.Androlib.buildUnknownFiles(Androlib.java:600)

... 2 more

15 tests completed, 1 failed

:brut.apktool:apktool-lib:test FAILED

FAILURE: Build failed with an exception.

* What went wrong:

Execution failed for task ':brut.apktool:apktool-lib:test'.

> There were failing tests. See the report at: file:///home/ubuntu/Desktop/Apktool-master/brut.apktool/apktool-lib/build/reports/tests/index.html

* Try:

Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED
[Android Software Development] edzamber:
Did you try with jdk 8u111 ?
[Android Software Development] bovirus:
[MENTION=4507636]edzamber[/MENTION]

I already tried with JDK 1.8.0.111 and 1.7.0.80.

Same error.
[Android Software Development] edzamber:
Ok so same for me.

With Cygwin i successfully build previous version 166bf5.

But now with version 0571cc its don't working anymore, same errors than you.

If i force to recompil with

./gradlew release fatjar

It build Succefully because bypassing tests that are run with build fatjar command, but if i try to compil SystemUI.apk for exemple, i can decompil but can't recompil, i have errors from public.xml. So something go wrong...

EDIT

I have modify Cygwin=false to Cygwin=true into gradlew script file and redone with

./gradlew release fatjar

Now Apktool working fine for decompil and recompil.

Tested on my SystemUI, no issue.
[Android Software Development] bovirus:
[MENTION=3924617]iBotPeaches[/MENTION]

Any news about the fix?

We cannot compile it under Windows/Cygwin/Linux.
[Android Software Development] iBotPeaches:
No, you are welcome to submit a pull request however. Those tests will remain to ensure a regression free built tool.
[Android Software Development] dnnz:
Please help when i recompile Google Play Books the app says " unfortunately app has stopped", i used the commands "apktool d -r ", "apktool b -c" and signed the apk, here is detailed post i did but nobody answered :(
[Android Software Development] Thebear j koss:
Cannot sign google apps. Need to use original signatures. Plus if you are on android 7 or above there are certain extra steps to work around the v2 signatures implemented on the newer builds. Try building with original signature and flashing it to system...

Those who cannot*remember*the past*are condemned to repeat it. The Dark Ages have returned...
[Android Software Development] dnnz:
I'm using KK

It's possible to build with the original signature? do you have some guide or is called another way bc i google it and i don't find anything.
[Android Software Development] Thebear j koss:
Use 7 zip or winrar to drag meta inf folder from original apk to new apk. Or 1st item in google search for apktool commands... https://ibotpeaches.github.io/Apktool/documentation/

Those who cannot*remember*the past*are condemned to repeat it. The Dark Ages have returned...
[Android Software Development] dnnz:
I'm already using -c to keep the original signature but still i can't install the app, it says: app not installed.

I tried with normal apps and they also don't get installed, but if then i sign them they work, not in the case of the google app (crashes).

I read that if you use -c you don't need to sign the app later so maybe is a bug?

When trying to install the apk with the original signature through adb it says "Failure [INSTALL_PARSE_FAILED_NO_CERTIFICATES]"

In the recovery with zip seems to fail too bc doesn't get installed.
[Android Software Development] Train88:
What type of app is it? Does it use location/maps API? Does it have a Google login option? What API is it built with (API 21+ probably has the v2 signature stuff)? There's SO many possibilities...
[Android Software Development] Thebear j koss:
Not a bug, i said before when you keep original signature the app needs to be flashed to system. You can't just use press to install when keeping original signature. [MENTION=5476501]Train88[/MENTION] it is google books.

Those who cannot*remember*the past*are condemned to repeat it. The Dark Ages have returned...

---------- Post added at 01:32 AM ---------- Previous post was at 01:32 AM ----------

Not a bug, i said before when you keep original signature the app needs to be flashed to system. You can't just use press to install when keeping original signature. [MENTION=5476501]Train88[/MENTION] it is google books.

Those who cannot*remember*the past*are condemned to repeat it. The Dark Ages have returned...
[Android Software Development] bovirus:
Done.

https://github.com/iBotPeaches/Apktool/issues/1414
[Android Software Development] WILMANS2M:
Hello tamirda. May i ask you how to find the necessary code to replace. I have the same error under MM 6.01 with SM-G903F. Thanks.
[Android Software Development] edzamber:
Hi,

Look here for fix SecSettings time Picker

https://xdaforums.com/showthread.php?p=67075887