I'm trying to recompile my apk using apktool v4.2.0 once i decompile it i try to recompile it without touching anything then This is the error appears
PHP:
Log For : co.apk
Log Type : Recompiling
Log Recorded At : 02 2017-08- 16:30:32,42
Log Recorded By : Advanced ApkTool v4.2.0 By BDFreak
------------------------------------------------------
W: max res 24, skipping values-v25
W: C:\Users\zeekdp\Desktop\AdvancedApkTool\3-Out\co.apk\res\values\public.xml:1139: error: Public symbol style/Platform.V25.AppCompat declared here is not defined.
W: C:\Users\zeekdp\Desktop\AdvancedApkTool\3-Out\co.apk\res\values\public.xml:1140: error: Public symbol style/Platform.V25.AppCompat.Light declared here is not defined.
Exception in thread "main" brut.androlib.AndrolibException: brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [C:\Users\ABDELM~1\AppData\Local\Temp\brut_util_Jar_2951543882709119069.tmp, p, --forced-package-id, 127, --min-sdk-version, 9, --target-sdk-version, 25, --max-sdk-version, 24, --max-res-version, 24, --version-code, 1, --version-name, 1.0, -F, C:\Users\ABDELM~1\AppData\Local\Temp\APKTOOL3839981288265792103.tmp, -0, arsc, -0, arsc, -I, C:\Users\zeekdp\Desktop\AdvancedApkTool\1-BDFreak\Frameworks\1.apk, -S, C:\Users\zeekdp\Desktop\AdvancedApkTool\3-Out\co.apk\res, -M, C:\Users\zeekdp\Desktop\AdvancedApkTool\3-Out\co.apk\AndroidManifest.xml]
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:478)
at brut.androlib.Androlib.buildResources(Androlib.java:412)
at brut.androlib.Androlib.build(Androlib.java:311)
at brut.androlib.Androlib.build(Androlib.java:264)
at brut.apktool.Main.cmdBuild(Main.java:227)
at brut.apktool.Main.main(Main.java:84)
Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [C:\Users\ABDELM~1\AppData\Local\Temp\brut_util_Jar_2951543882709119069.tmp, p, --forced-package-id, 127, --min-sdk-version, 9, --target-sdk-version, 25, --max-sdk-version, 24, --max-res-version, 24, --version-code, 1, --version-name, 1.0, -F, C:\Users\ABDELM~1\AppData\Local\Temp\APKTOOL3839981288265792103.tmp, -0, arsc, -0, arsc, -I, C:\Users\zeekdp\Desktop\AdvancedApkTool\1-BDFreak\Frameworks\1.apk, -S, C:\Users\zeekdp\Desktop\AdvancedApkTool\3-Out\co.apk\res, -M, C:\Users\zeekdp\Desktop\AdvancedApkTool\3-Out\co.apk\AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:439)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:464)
... 5 more
Caused by: brut.common.BrutException: could not exec (exit code = 1): [C:\Users\ABDELM~1\AppData\Local\Temp\brut_util_Jar_2951543882709119069.tmp, p, --forced-package-id, 127, --min-sdk-version, 9, --target-sdk-version, 25, --max-sdk-version, 24, --max-res-version, 24, --version-code, 1, --version-name, 1.0, -F, C:\Users\ABDELM~1\AppData\Local\Temp\APKTOOL3839981288265792103.tmp, -0, arsc, -0, arsc, -I, C:\Users\zeekdp\Desktop\AdvancedApkTool\1-BDFreak\Frameworks\1.apk, -S, C:\Users\zeekdp\Desktop\AdvancedApkTool\3-Out\co.apk\res, -M, C:\Users\zeekdp\Desktop\AdvancedApkTool\3-Out\co.apk\AndroidManifest.xml]
at brut.util.OS.exec(OS.java:95)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:433)
... 6 more
------------------------------------------------------
Zeepdep said:
I'm trying to recompile my apk using apktool v4.2.0 once i decompile it i try to recompile it without touching anything then This is the error appears...
Click to expand...
Click to collapse
According to the header of the log, your using the Advanced Apktool by @BDFreak...
You should be posting this issue on that specific thread for the Advanced Apktool.
Please Note that it was just updated recently with the latest Apktool v2.2.4 release (a week +/- ago).
[Tool]Advanced ApkTool v4.2.0[Windows][10/02/2016] by BDFreak
I wish you the best of luck!
______________
PLEASE NOTE: I welcome any member to help with further valuable information/clarification for any of my posts.
×MY DEVELOPMENTS×
[APP][TOOL][4.2+]The SELinux Toggler
[ZIP][TOOL][AIO]BusyBox Stericson Binary Installer v1.26.2 {BB/TB Auto-Symlink}
×IN DEVELOPMENT×
[APP][TOOL][4.2+][OFFICIAL]The SELinux Switch
Will Supersede "The SELinux Toggler"
×IDEAS FOR DEVELOPMENT×
[APP][UNOFFICIAL][4.2+]XDA Forum {Classic}
[APP][UNOFFICIAL][4.2+]XDA Reader {Classic}
Related
Hi,
I'm trying to recompile an apk in debug mode (so no changes besides the one-liner in the manifest). But every time I execute "apktool b -d out" I get this error:
Code:
I: Using Apktool 2.0.0
I: Checking whether sources has changed...
I: Smaling smali folder into classes.dex...
I: Checking whether resources has changed...
I: Building resources...
Exception in thread "main" brut.androlib.AndrolibException: brut.androlib.AndrolibException: brut.common.BrutException: could not exec command: [C:\Users\Me\AppData\Local\Temp\brut_util_Jar_7477717139219658502.tmp, p, --out-mode, --forced-package-id, 127, --min-sdk-version, 16, --target-sdk-version, 19, --version-code, 26, --version-name, @string/versionname, -F, C:\Users\Me\AppData\Local\Temp\APKTOOL7991561937292063981.tmp, -0, arsc, -I, C:\Users\Me\apktool\framework\1.apk, -S, D:\out\res, -M, D:\out\AndroidManifest.xml]
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:458)
at brut.androlib.Androlib.buildResources(Androlib.java:396)
at brut.androlib.Androlib.build(Androlib.java:285)
at brut.androlib.Androlib.build(Androlib.java:256)
at brut.apktool.Main.cmdBuild(Main.java:225)
at brut.apktool.Main.main(Main.java:84)
Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could not exec command: [C:\Users\Me\AppData\Local\Temp\brut_util_Jar_7477717139219658502.tmp, p, --out-mode, --forced-package-id, 127, --min-sdk-version, 16, --target-sdk-version, 19, --version-code, 26, --version-name, @string/versionname, -F, C:\Users\Me\AppData\Local\Temp\APKTOOL7991561937292063981.tmp, -0, arsc, -I, C:\Users\Me\apktool\framework\1.apk, -S, D:\out\res, -M, D:\out\AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:419)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:444)
... 5 more
Caused by: brut.common.BrutException: could not exec command: [C:\Users\Me\AppData\Local\Temp\brut_util_Jar_7477717139219658502.tmp, p, --out-mode, --forced-package-id, 127, --min-sdk-version, 16, --target-sdk-version, 19, --version-code, 26, --version-name, @string/versionname, -F, C:\Users\Me\AppData\Local\Temp\APKTOOL7991561937292063981.tmp, -0, arsc, -I, C:\Users\Me\apktool\framework\1.apk, -S, D:\out\res, -M, D:\out\AndroidManifest.xml]
at brut.util.OS.exec(OS.java:89)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:413)
... 6 more
I tried this both on Windows and Ubuntu and I'm always getting this error. If I decode with -r (copy resources raw) everything recompiles just fine, but then I can't add the "android:debuggable"-value (for obvious reasons, I just wanted to test the recompiling). I googled this error and often there is a problem with "aapt" not beeing recognized, so I added the path to my PATH-variable, but I'm still getting the above output.
Anyone out there with a fix or am I doing something wrong?
Regards,
me113
I fixed it myself. There was a problem with the decompiling of the resources. Three images were exported as jpg instead of png. Re-saving them as png fixed everything. :victory:
Hi,
I have this strange problem... I took a certain apk, decompiled it using apktools, but when I tried to recompile it back I got lots of errors like this one:
C:\apkto\test\res\layout\activity_wordfall.xml:46: error: No resource identifie
r found for attribute 'textAlignment' in package 'android'
Exception in thread "main" brut.androlib.AndrolibException: brut.androlib.Androl
ibException: brut.common.BrutException: could not exec command: [C:\Users\johny\
AppData\Local\Temp\brut_util_Jar_3012068314543899025.tmp, p, --forced-package-id
, 127, --min-sdk-version, 9, --target-sdk-version, 19, --version-code, 34, --ver
sion-name, 1.2.2, -F, C:\Users\johny\AppData\Local\Temp\APKTOOL64664871173833496
10.tmp, -0, resources.arsc, -0, arsc, -I, C:\Users\johny\apktool\framework\1.apk
, -S, C:\apkto\test\res, -M, C:\apkto\testo\AndroidManifest.xml]
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:465)
at brut.androlib.Androlib.buildResources(Androlib.java:403)
at brut.androlib.Androlib.build(Androlib.java:291)
at brut.androlib.Androlib.build(Androlib.java:261)
at brut.apktool.Main.cmdBuild(Main.java:225)
at brut.apktool.Main.main(Main.java:84)
Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could not
exec command: [C:\Users\johny\AppData\Local\Temp\brut_util_Jar_3012068314543899
025.tmp, p, --forced-package-id, 127, --min-sdk-version, 9, --target-sdk-version
, 19, --version-code, 34, --version-name, 1.2.2, -F, C:\Users\johny\AppData\Loca
l\Temp\APKTOOL6466487117383349610.tmp, -0, resources.arsc, -0, arsc, -I, C:\User
s\johny\apktool\framework\1.apk, -S, C:\apkto\testo\res, -M, C:\apkto\test\Andr
oidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.jav
a:425)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:451)
... 5 more
Upon writing my question at XDA, I tried offhandedly to do the same thing in a virtual machine I own, not expecting much- but then BAM- apparently the process has ended just fine .
The only difference I see between my PC and my VM is that my PC has the latest Java update (1.8.0_66-b18) and the official android SDK, while my VM has only an older version of Java (1.8.0_31-b13).
So what's happening? and how can I fix it?
Thank you!
I have little to no knowledge of modifying APKs and all attempts in doing so in the past have resulted me in giving up, except now I really need this to work! looks fairly simply according to this old post using apktool and java outlined here https://www.reddit.com/r/Android/comments/11852r/how_to_modify_an_apk/
only issue is I can't get it to rebuild the apk from the folder even if I make no changes. I'm getting a bunch of "Error parsing XML: not well-formed (invalid token)" messages before it spits out the following exception
Code:
Exception in thread "main" brut.androlib.AndrolibException: brut.androlib.AndrolibException: brut.common.BrutException:could not exec (exit code = 1): [/tmp/brut_util_Jar_2053807626495926747.tmp, p, --forcedpackage-id, 127, --min-sdk-version, 14, --version-code, 708, --version-name, 3.1.3, -F, /tmp/APKTOOL6891156991859364727.tmp, -0, arsc, -0, arsc, -I, /home/nmok/.local/share/apktool/framework/1.apk, -S, /tmp/com.braksoftware.HumanJapanese-ca95c7eff15a41e99c94d68e5fe46a67/res, -M, /tmp/com.braksoftware.HumanJapanese-ca95c7eff15a41e99c94d68e5fe46a67/AndroidManifest.xml]
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:478)
at brut.androlib.Androlib.buildResources(Androlib.java:412)
at brut.androlib.Androlib.build(Androlib.java:311)
at brut.androlib.Androlib.build(Androlib.java:264)
at brut.apktool.Main.cmdBuild(Main.java:227)
at brut.apktool.Main.main(Main.java:84)
Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [/tmp/brut_util_Jar_2053807626495926747.tmp, p, --forced-package-id, 127, --min-sdk-version, 14, --version-code, 708, --version-name, 3.1.3, -F, /tmp/APKTOOL6891156991859364727.tmp, -0, arsc, -0, arsc, -I, /home/nmok/.local/share/apktool/framework/1.apk, -S, /tmp/com.braksoftware.HumanJapanese-ca95c7eff15a41e99c94d68e5fe46a67/res, -M, /tmp/com.braksoftware.HumanJapanese-ca95c7eff15a41e99c94d68e5fe46a67/AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:439)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:464)
... 5 more
Caused by: brut.common.BrutException: could not exec (exit code = 1): [/tmp/brut_util_Jar_2053807626495926747.tmp, p, --forced-package-id, 127, --min-sdk-version, 14, --version-code, 708, --version-name, 3.1.3, -F, /tmp/APKTOOL6891156991859364727.tmp, -0, arsc, -0, arsc, -I, /home/nmok/.local/share/apktool/framework/1.apk, -S, /tmp/com.braksoftware.HumanJapanese-ca95c7eff15a41e99c94d68e5fe46a67/res, -M, /tmp/com.braksoftware.HumanJapanese-ca95c7eff15a41e99c94d68e5fe46a67/AndroidManifest.xml]
at brut.util.OS.exec(OS.java:95)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:433)
... 6 more
any sort of help would be appreciated!
After decompiling this apk then immediatly attempting to recompile without changing anything I get this error log:
13/12/2017 19:22:55
java -Xmx1024m -jar "C:\Program Files (x86)\APK Easy Tool\Apktool\apktool_2.3.0.jar" b -f -o "C:\Users\James\Documents\2-Recompiled APKs\stick-fight-shadow-warrior-v1.04-mod-lenov.ru.apk" "C:\Users\James\Documents\1-Decompiled APKs\stick-fight-shadow-warrior-v1.04-mod-lenov.ru"
Compiling APK file...
I: Using Apktool 2.3.0
I: Smaling smali folder into classes.dex...
I: Building resources...
W: C:\Users\James\Documents\1-Decompiled APKs\stick-fight-shadow-warrior-v1.04-mod-lenov.ru\AndroidManifest.xml:3: error: No resource identifier found for attribute 'qihoo' in package 'android'
W:
Exception in thread "main" brut.androlib.AndrolibException: brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [C:\Users\James\AppData\Local\Temp\brut_util_Jar_3839531451092608287.tmp, p, --forced-package-id, 127, --min-sdk-version, 16, --target-sdk-version, 25, --version-code, 9, --version-name, 1.04, --no-version-vectors, -F, C:\Users\James\AppData\Local\Temp\APKTOOL9194040682419918563.tmp, -0, arsc, -0, bank, -0, appkey, -0, assets/Master Bank.strings.bank, -0, arsc, -I, C:\Users\James\AppData\Local\apktool\framework\1.apk, -S, C:\Users\James\Documents\1-Decompiled APKs\stick-fight-shadow-warrior-v1.04-mod-lenov.ru\res, -M, C:\Users\James\Documents\1-Decompiled APKs\stick-fight-shadow-warrior-v1.04-mod-lenov.ru\AndroidManifest.xml]
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:485)
at brut.androlib.Androlib.buildResources(Androlib.java:419)
at brut.androlib.Androlib.build(Androlib.java:318)
at brut.androlib.Androlib.build(Androlib.java:270)
at brut.apktool.Main.cmdBuild(Main.java:224)
at brut.apktool.Main.main(Main.java:75)
Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [C:\Users\James\AppData\Local\Temp\brut_util_Jar_3839531451092608287.tmp, p, --forced-package-id, 127, --min-sdk-version, 16, --target-sdk-version, 25, --version-code, 9, --version-name, 1.04, --no-version-vectors, -F, C:\Users\James\AppData\Local\Temp\APKTOOL9194040682419918563.tmp, -0, arsc, -0, bank, -0, appkey, -0, assets/Master Bank.strings.bank, -0, arsc, -I, C:\Users\James\AppData\Local\apktool\framework\1.apk, -S, C:\Users\James\Documents\1-Decompiled APKs\stick-fight-shadow-warrior-v1.04-mod-lenov.ru\res, -M, C:\Users\James\Documents\1-Decompiled APKs\stick-fight-shadow-warrior-v1.04-mod-lenov.ru\AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:454)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:471)
... 5 more
Caused by: brut.common.BrutException: could not exec (exit code = 1): [C:\Users\James\AppData\Local\Temp\brut_util_Jar_3839531451092608287.tmp, p, --forced-package-id, 127, --min-sdk-version, 16, --target-sdk-version, 25, --version-code, 9, --version-name, 1.04, --no-version-vectors, -F, C:\Users\James\AppData\Local\Temp\APKTOOL9194040682419918563.tmp, -0, arsc, -0, bank, -0, appkey, -0, assets/Master Bank.strings.bank, -0, arsc, -I, C:\Users\James\AppData\Local\apktool\framework\1.apk, -S, C:\Users\James\Documents\1-Decompiled APKs\stick-fight-shadow-warrior-v1.04-mod-lenov.ru\res, -M, C:\Users\James\Documents\1-Decompiled APKs\stick-fight-shadow-warrior-v1.04-mod-lenov.ru\AndroidManifest.xml]
at brut.util.OS.exec(OS.java:95)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:448)
... 6 more
------------------------------------------
Could anybody help me to understand this?
hi there iam decompiling the apk file and getting error anyone can guide me how to fix ? for this prupose i decompiled chegg study application apk and did a little tweak and recompiled the folder upon recompiling getting this error :
Tool used: APK Easy Tool
invalid resource directory name: C:\Users\fahad_satti22\Desktop\apktool\chegg_original\res navigation
brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [C:\Users\fahad_satti22\AppData\Local\Temp\brut_util_Jar_31928081245386695307597454261093548753.tmp, p, --forced-package-id, 127, --min-sdk-version, 23, --target-sdk-version, 29, --version-code, 294, --version-name, 10.0.4, --no-version-vectors, -F, C:\Users\fahad_satti22\AppData\Local\Temp\APKTOOL6994267000475427236.tmp, -e, C:\Users\fahad_satti22\AppData\Local\Temp\APKTOOL3529958739332127621.tmp, -0, arsc, -I, C:\Users\fahad_satti22\AppData\Local\apktool\framework\1.apk, -S, C:\Users\fahad_satti22\Desktop\apktool\chegg_original\res, -M, C:\Users\fahad_satti22\Desktop\apktool\chegg_original\AndroidManifest.xml]