yashsingh1/xdaforums huggingface dataset:
[Android Software Development] iBotPeaches:
1.5.1 Pre-Release 2

Closed file-handler when writing frameworks to file system.

Updated to Gradle 1.3

Properly deleted tmp files after building apk (issue #365)

Added support for renamed packages via --renamed-manifest-package (issue #252)

Prevents removal of <uses-sdk> on decompile, but then throws warning on rebuild (issue #366)

Option to specify framework folder (issue #175)

Prevents removal of configChanges in AndroidManifest (issue #304)

Updated snakeyaml to 1.11 to fix "unacceptable character" errors. (issue #360)

Android 4.2 support? I hope :p

Github destroyed repo downloads due to users raping their bandwidth. The iOS jailbreak guys started hosting their packages and would use upwards of 3TB of bandwidth a day (is my guess).

So here it is.

http://miui.connortumbleson.com/other/apktool/test_versions/apktool_1.5.1PR2.jar

I spent a lot of time on this release. Please test 4.2 APKs a lot.

Features that are NOT here.

- injecting orginals (for /system apps)

- Proguard (to make smaller jar)

- SmaliDebugging
[Android Software Development] maxrdlf95:
Hey iBot thanks for your work I get this trying to compile 4.2 Settings APK already installed Framework and SystemUI with success but not the compile :P

Exception in thread "main" brut.androlib.AndrolibException: brut.androlib.AndrolibException: brut.common.BrutException: could not exec command: [aapt, p, --min-sdk-version, 17, --target-sdk-version, 17, -F, C:\Users\VMax\AppData\Local\Temp\APKTOOL3708278412144753685.tmp, -I, C:\Users\VMax\apktool\framework\1.apk, -S, C:\Users\VMax\Desktop\Android\Herramientas\APK-Multi-Tool\other\..\projects\Settings.apk\res, -M, C:\Users\VMax\Desktop\Android\Herramientas\APK-Multi-Tool\other\..\projects\Settings.apk\AndroidManifest.xml]
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:355)
at brut.androlib.Androlib.buildResources(Androlib.java:280)
at brut.androlib.Androlib.build(Androlib.java:203)
at brut.androlib.Androlib.build(Androlib.java:176)
at brut.apktool.Main.cmdBuild(Main.java:214)
at brut.apktool.Main.main(Main.java:74)
Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could not exec command: [aapt, p, --min-sdk-version, 17, --target-sdk-version, 17, -F, C:\Users\VMax\AppData\Local\Temp\APKTOOL3708278412144753685.tmp, -I, C:\Users\VMax\apktool\framework\1.apk, -S, C:\Users\VMax\Desktop\Android\Herramientas\APK-Multi-Tool\other\..\projects\Settings.apk\res, -M, C:\Users\VMax\Desktop\Android\Herramientas\APK-Multi-Tool\other\..\projects\Settings.apk\AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:335)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:333)
... 5 more
Caused by: brut.common.BrutException: could not exec command: [aapt, p, --min-sdk-version, 17, --target-sdk-version, 17, -F, C:\Users\VMax\AppData\Local\Temp\APKTOOL3708278412144753685.tmp, -I, C:\Users\VMax\apktool\framework\1.apk, -S, C:\Users\VMax\Desktop\Android\Herramientas\APK-Multi-Tool\other\..\projects\Settings.apk\res, -M, C:\Users\VMax\Desktop\Android\Herramientas\APK-Multi-Tool\other\..\projects\Settings.apk\AndroidManifest.xml]
at brut.util.OS.exec(OS.java:89)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:333)
... 6 more
[Android Software Development] CosmicDan:
Unless aapt is missing from your path, that doesn't help.
[Android Software Development] maxrdlf95:
aapt it's there I downloaded it from this post btw I'm using windows.
[Android Software Development] CosmicDan:
What I meant was, post the full log. All that's saying is that it can't execute aapt. Either aapt is missing *or* APKTool had an error earlier on.

EDIT: Try doing it manually in shell instead of whatever APK Multitool is.
[Android Software Development] masterex567:
Any help on my case?
[Android Software Development] xxhorseriderxxx:
I wish I could thank this post 15 times! PR2 seems to install a 4.2 framework-res.apk normally, and I was able to decompile and recompile LatinIME.apk without a problem. I'll be testing on other Nexus 10 apks as I get around to modifying them.
[Android Software Development] cbd dvd:
Please help!!

Instruction for installing in windows 7???

Thanks!!

puedo volar, puedo volar!!!

ya se que no puedo volar, pero puedo planear!!
[Android Software Development] Alunduyn:
I can confirm it is working with Android 4.2. aapt.exe from OP, lastest preview ( PR2 ). framework-res.apk from a JB ROM, decompiled and recompiled 4.2 keyboard ( finally my own smileies!!! I was becoming quite mad :) ). Many many thanks iBotPeaches

EDIT : Doh one question : I made changes in smali. Which folders I have to move to the old apk from the new recompiled one?

EDIT 2 : There seem to be a problem : I moved resources.arasc and res/ from the recompiled apk to the original apk ( so I keep the classes.dex and the signature ). The new keyboard FCs. Am I doing wrong anything?

EDIT 3 : The problem looks to be related with res. I have a 4.1.2 ROM ( too lazy to update right now ). If I decompile the apk with my ROM's framework-res apk recompilation does not work. If I do with JB 4.2 framework-res everything works fine but then the keyboard can't find what is needed in my ROM's framework-res. Duh. I'll have to keep writing with those ugly android stock smileies.
[Android Software Development] xxhorseriderxxx:
I had the same FC problem with editing the stock N10 keyboard. (assumingly the same as the keyboard you're using). I kindof sidestepped that problem by downloading a free market version of the keyboard: https://play.google.com/store/apps/...wsMSwxLDEwMiwiamVsbHliZWFua2V5Ym9hcmQuZi5nIl0.

Everything seems to be working okay with it so far; I was able to add whatever I wanted to the keyboard. Changing the smilies is only the first thing I did. I added my emails and passwords as key popups on the two of the keyboard keys.
[Android Software Development] 1982Strand:
If you edit smali, you need to copy classes.dex too.
[Android Software Development] mjkute:
it works for me (cm 10.1)
[Android Software Development] Alunduyn:
Thanks, I'll see what I can do :) (have you found how to edit the standard keyboard layout? The Pop-up smileies are in smali/com/android/input/inputmethod/common/KeyboardTextSet.smali or something similar. The standard layout? If I want to have a q in place of a p or just edit the short-press ugli :) to a new :). Many thanks if you know)

Forgot about that, many thanks. Only on deodexed roms, right?
[Android Software Development] creeve4:
Found it
[Android Software Development] janis605:
Recompiling Nexus 4 Stock, 4.2.1:
[Android Software Development] spdwiz18:
spdwiz18@spdwiz18-desktop:~/Desktop/trial$ apktool b SystemUI

I: Checking whether sources has changed...

I: Smaling...

I: Checking whether resources has changed...

I: Building resources...

/home/spdwiz18/Desktop/trial/SystemUI/AndroidManifest.xml:100: error: Error parsing XML: no element found

Exception in thread "main" brut.androlib.AndrolibException: brut.common.BrutException: could not exec command: [aapt, p, --min-sdk-version, 17, --target-sdk-version, 17, -F, /tmp/APKTOOL971520654449542316.tmp, -I, /home/spdwiz18/apktool/framework/1.apk, -S, /home/spdwiz18/Desktop/trial/SystemUI/res, -M, /home/spdwiz18/Desktop/trial/SystemUI/AndroidManifest.xml]

at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:270)

at brut.androlib.Androlib.buildResourcesFull(Androlib.java:337)

at brut.androlib.Androlib.buildResources(Androlib.java:284)

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

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

at brut.apktool.Main.cmdBuild(Main.java:213)

at brut.apktool.Main.main(Main.java:72)

Caused by: brut.common.BrutException: could not exec command: [aapt, p, --min-sdk-version, 17, --target-sdk-version, 17, -F, /tmp/APKTOOL971520654449542316.tmp, -I, /home/spdwiz18/apktool/framework/1.apk, -S, /home/spdwiz18/Desktop/trial/SystemUI/res, -M, /home/spdwiz18/Desktop/trial/SystemUI/AndroidManifest.xml]

at brut.util.OS.exec(OS.java:83)

at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:268)

... 6 more

spdwiz18@spdwiz18-desktop:~/Desktop/trial$

This is the errror im getting on linux. i made no changes. Just simply decompiled and recompiled. Decompile works fine. Recompile errors out.
[Android Software Development] ÜBER™:
aapt, p, --min-sdk-version, 17, --target-sdk-version, 17, -F,

Is the error, you need the latest aapt for Linux.
[Android Software Development] asrock37:
@iBotPeaches

I know this is just a warning message when compiling.

Thanks

asrock
[Android Software Development] iBotPeaches:
Yeah some users complained that the <uses-sdk> clause wasn't in AndroidManifest during decompile, which I fixed but then this warning appears. I guess I'll undo the fix and keep it the same. As aapt re-inserts the <uses-sdk> on build.

@spdwiz18

I want that APK. Looks like a bug.
[Android Software Development] A_U:
hello

i am sorry but if anyone already asked this please forgive me.

I am currently using 4.2.1. I am able to decompile the framework-related stuff, but its throwing errors when recompiling.

Yes i am on latest aapt both in adb and windows directory.

Also using latest Pr-2.

Also if'd it...i know my apktool :p..

But i dont have latest SDK supporting 4.2.1..is that the matter ? I am on limited connectivity, so before downloading all that, if any way to resolve, please help :)
[Android Software Development] varun.chitre15:
To get help from us you need to post your recompilation error
[Android Software Development] plegdroid:
no, you don't need sdk, just use the aapt from the op :)

ⓐⓝⓓⓡⓞⓢⓘⓓⓔ ⓘⓢ ⓝⓞⓣ ⓐ ⓢⓘⓝ
[Android Software Development] A_U:
CM 10.1
[Android Software Development] plegdroid:
does your installed framework need to be in the same drive as apktool?

framework is installed to your c drive, but your using apktool in D?

ideally I'd be running apktool from within C.

ⓐⓝⓓⓡⓞⓢⓘⓓⓔ ⓘⓢ ⓝⓞⓣ ⓐ ⓢⓘⓝ
[Android Software Development] iBotPeaches:
I coded support for RTL/LTR. That directory structure is whack. Your backslash is forward slash and that messes everything up. Don't think Apktool caused that. I've been testing that RTL stuff for weeks without a problem.
[Android Software Development] A_U:
i always do dat..get no errors wat so ever..but untill now :p

@ibotpeaches = so it has to be backward ?
[Android Software Development] plegdroid:
hope you sort It :) :D O:)

ⓐⓝⓓⓡⓞⓢⓘⓓⓔ ⓘⓢ ⓝⓞⓣ ⓐ ⓢⓘⓝ
[Android Software Development] fisha21:
Just tried this with the latest Playstore.apk (3.10.9), get the following recompile error

EDIT: has been pointed out that latest version is 3.10.10 - still get the same error

Had this error with 1.5.0 and thought the "error: No resource identifier found for attribute 'singleUser' in package 'android'' " was related to the renamed-manifest-package error, but seems not? Deleting that entire line from manifest will allow the apk to build and install, but then Play force closes when trying to install an app

Did already redownload the latest aapt from the OP
[Android Software Development] iBotPeaches:
Seems to be one little issue left that you and some others encountered. If you could send me that playstore apk, and along w/ the others I got. I should be able to figure this last niggle out (after Christmas) :p
[Android Software Development] einrae214:
ok im a so a noob at theming but im getting the hang of things. so i know that 4.1.2 apps give a hard time when recompiling because it gives me fits when i want to theme system apps. so i tired to theme 4.1.1 system app and it compiled and it didnt give me errors but it spit out something else instead. and was hoping some one could give me a hand please and thank you.

Warning: AndroidManifest.xml already defines minSdkVersion (in http://schemas.an

droid.com/apk/res/android); using existing value in manifest.

Warning: AndroidManifest.xml already defines targetSdkVersion (in http://schemas

.android.com/apk/res/android); using existing value in manifest.

aapt: warning: string 'desk_cradle_enable_popup_summary' has no default translat

ion in C:\ics apktool\ICS Apktool\secsettings\res; found: es_US

aapt: warning: string 'desk_cradle_enable_popup_title' has no default translatio

n in C:\ics apktool\ICS Apktool\secsettings\res; found: es_US

aapt: warning: string 'scloud_disable_wifi_only_body' has no default translation

in C:\ics apktool\ICS Apktool\secsettings\res; found: es_US

aapt: warning: string 'scloud_disable_wifi_only_title' has no default translatio

n in C:\ics apktool\ICS Apktool\secsettings\res; found: es_US

I: Building apk file...

i didnt even touch the app itself all i did was decompile it and then recompile it to see what would happen. im also using version 1.5.2 test release apktool.
[Android Software Development] iBotPeaches:
The first 2 warnings are fixed, the next 4 warnings just mean there is no default translation. Which means your have a translation in es_US that isn't in /values. Newer Android Eclipse plugins prevent you from building w/ problems like that, but its not a problem.

The apktool rebuilt fine. Its just warnings.
[Android Software Development] einrae214:
Ok just checking thanks.
[Android Software Development] iBotPeaches:
Actually, this isn't a bug :p

Just use a framework-res thats from a 4.2 ROM. I pulled AOSP source, built it. Then used that framework-res.apk (apktool if framework-res.apk) and got this.

ibotpeaches@raganok:~/Desktop$ apktool d -f com.android.vending-3.10.9.apk
I: Baksmaling...
I: Loading resource table...
I: Loaded.
I: Decoding AndroidManifest.xml with resources...
I: Loading resource table from file: /home/ibotpeaches/apktool/framework/1.apk
I: Loaded.
I: Regular manifest package...
I: Decoding file-resources...
I: Decoding values */* XMLs...
I: Done.
I: Copying assets and libs...
ibotpeaches@raganok:~/Desktop$ apktool b com.android.vending-3.10.9
I: Checking whether sources has changed...
I: Smaling...
I: Checking whether resources has changed...
I: Building resources...
I: Building apk file...
ibotpeaches@raganok:~/Desktop$
[Android Software Development] fisha21:
By thor's hammer, I'm such a numbskull! Thanks, will try that later
[Android Software Development] Mach3.2:
Able to decompile the framework-res.apk for CM10.1(Galaxy Nexus), but i'm not able to compile it back, installed framework before hand too.

D:\Users\*\Downloads\Galaxy Nexus\apktoolsJB>java -jar apktool.jar b f
ramework-res
W: Could not find sources
I: Checking whether resources has changed...
I: Building resources...
invalid resource directory name: D:\Users\*\Downloads\Galaxy Nexus\apk
toolsJB\framework-res\res/drawable-ldrtl-xhdpi
Exception in thread "main" brut.androlib.AndrolibException: brut.androlib.Androl
ibException: brut.common.BrutException: could not exec command: [aapt, p, --min-
sdk-version, 17, --target-sdk-version, 17, -F, C:\Users\Mach\AppData\Local\Temp\
APKTOOL5915212430105829213.tmp, -x, -S, D:\Users\*\Downloads\Galaxy Ne
xus\apktoolsJB\framework-res\res, -M, D:\Users\*\Downloads\Galaxy Nexu
s\apktoolsJB\framework-res\AndroidManifest.xml]
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:355)
at brut.androlib.Androlib.buildResources(Androlib.java:280)
at brut.androlib.Androlib.build(Androlib.java:203)
at brut.androlib.Androlib.build(Androlib.java:176)
at brut.apktool.Main.cmdBuild(Main.java:214)
at brut.apktool.Main.main(Main.java:74)
Caused by: brut.androlib.AndrolibException: brut.common.BrutException: could not
exec command: [aapt, p, --min-sdk-version, 17, --target-sdk-version, 17, -F, C:
\Users\Mach\AppData\Local\Temp\APKTOOL5915212430105829213.tmp, -x, -S, D:\Users\
*\Downloads\Galaxy Nexus\apktoolsJB\framework-res\res, -M, D:\Users\*
\Downloads\Galaxy Nexus\apktoolsJB\framework-res\AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.jav
a:335)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:333)
... 5 more
Caused by: brut.common.BrutException: could not exec command: [aapt, p, --min-sd
k-version, 17, --target-sdk-version, 17, -F, C:\Users\Mach\AppData\Local\Temp\AP
KTOOL5915212430105829213.tmp, -x, -S, D:\Users\*\Downloads\Galaxy Nexu
s\apktoolsJB\framework-res\res, -M, D:\Users\*\Downloads\Galaxy Nexus\
apktoolsJB\framework-res\AndroidManifest.xml]
at brut.util.OS.exec(OS.java:89)
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.jav
a:333)
... 6 more

D:\Users\*\Downloads\Galaxy Nexus\apktoolsJB>
[Android Software Development] iBotPeaches:
Not a bug.

invalid resource directory name: D:\Users\*\Downloads\Galaxy Nexus\apk

toolsJB\framework-res\res/drawable-ldrtl-xhdpi

Shouldn't have /, it should be a \. I even tried to replicate on Windows. Someone is just passing around a malformed APK :(
[Android Software Development] Mach3.2:
I couldn't figure out why it was a forward slash instead of a back slash, i guess it's like what you said.

Anyway, i'm having issues with my sdcard(Deleted stuff did not get deleted) so i'm reflashing a newer version of cm10.1 anyway, will report back later on.:good:

Edit: Happened again, anyway to edit some files to change it from a forward slash to a back slash?

I appreciate you helping me with this.
[Android Software Development] iBotPeaches:
I have fixed this. It was an outdated aapt. I need to update my copies of aapt.
[Android Software Development] iBotPeaches:
Changes in PR1 - http://xdaforums.com/showpost.php?p=34090869&postcount=828

Changes in PR2 - http://xdaforums.com/showpost.php?p=35664185&postcount=1084

v1.5.1 Pre-Release 3

Reverted "Prevents removal of <uses-sdk> on decompile, but then throws warning on rebuild (issue #366)"

Added -a / -aapt command on rebuild to specify location of aapt

Updated internal framework

Updated unit tests for 4.2 support

Please grab new AAPT here: http://code.google.com/p/android-apktool/downloads/list

I plan on going live w/ this version on December 28 (unless someone finds a big problem).

http://miui.connortumbleson.com/other/apktool/test_versions/apktool_1.5.1PR3.jar
[Android Software Development] bgcngm:
Uh oh... something wrong with the new release. Every compile is failing:

D:\HTC T528w\mod\app>apktool b SystemUI
I: Checking whether resources has changed...
I: Building resources...
Exception in thread "main" java.lang.NullPointerException
at brut.androlib.res.AndrolibResources.aaptPackage(AndrolibResources.java:274)
at brut.androlib.Androlib.buildResourcesFull(Androlib.java:335)
at brut.androlib.Androlib.buildResources(Androlib.java:282)
at brut.androlib.Androlib.build(Androlib.java:205)
at brut.androlib.Androlib.build(Androlib.java:176)
at brut.apktool.Main.cmdBuild(Main.java:218)
at brut.apktool.Main.main(Main.java:74)

After reverting to PR2 works just fine:

D:\HTC T528w\mod\app>apktool b SystemUI
I: Checking whether resources has changed...
I: Building resources...
I: Building apk file...
[Android Software Development] iBotPeaches:
My bad. That was an upload problem from local -> server :( I updated on my server literally minutes later. You must of gotten it right after release. Sorry.

MD5 of real one: 3b9ff0b9a21f7e368d1bb471b85627bd apktool_1.5.1PR3.jar
[Android Software Development] bgcngm:
Yeap, I had downloaded the broken one. It's working now. Thanks!
[Android Software Development] asrock37:
@iBotPeaches

in compilation, invalid resource directory name in the following folder names:

values-hugeui-hdpi

values-hugeui-xhdpi

values-largeui-hdpi

values-largeui-xhdpi

thanks
[Android Software Development] iBotPeaches:
Not a bug. Those are customized resources made by Xiaomi (MIUI) which are not standard. Since I left my MIUI role, I no longer am going out of my way to support it. You will have to use the aapt provided by Xiaomi here (https://github.com/MiCode/patchrom_tools), which only has support for Linux / Windows and is pretty out of date.

Here is the DIFF report for AAPT.

diff --git a/tools/aapt/AaptAssets.cpp b/tools/aapt/AaptAssets.cpp
index 3d6537a..e4c069c 100644
--- a/tools/aapt/AaptAssets.cpp
+++ b/tools/aapt/AaptAssets.cpp
@@ -1019,6 +1019,18 @@ bool AaptGroupEntry::getUiModeTypeName(const char* name,
(out->uiMode&~ResTable_config::MASK_UI_MODE_TYPE)
| ResTable_config::UI_MODE_TYPE_TELEVISION;
return true;
+ } else if (strcmp(name, "smallui") == 0) {
+ if (out) out->uiMode = (out->uiMode&~ResTable_config::MASK_UI_MODE_TYPE) | 0x0c;
+ return true;
+ } else if (strcmp(name, "mediumui") == 0) {
+ if (out) out->uiMode = (out->uiMode&~ResTable_config::MASK_UI_MODE_TYPE) | 0x0d;
+ return true;
+ } else if (strcmp(name, "largeui") == 0) {
+ if (out) out->uiMode = (out->uiMode&~ResTable_config::MASK_UI_MODE_TYPE) | 0x0e;
+ return true;
+ } else if (strcmp(name, "hugeui") == 0) {
+ if (out) out->uiMode = (out->uiMode&~ResTable_config::MASK_UI_MODE_TYPE) | 0x0f;
+ return true;
}

return false;

I'm no longer building those changes into aapt. Its not my responsibility anymore to cater for the closed source MIUI product. I'm sorry. Feel free to build your own up to date aapt (like I did for MIUIAndroid's build scripts), using the AOSP source and that DIFF above.
[Android Software Development] asrock37:
Good, actually I already made a script for those folders that will be added.

Thank you
[Android Software Development] CosmicDan:
I did not know you left, how sad :( I understand the widespread political loath of Xiaomi and their closed-source development and various breaches of GNU, but it doesn't escape the fact that their ROM products are great. At least, 2.10.26 was great... everything after was just a mess. And it is pretty annoying that because it's closed source, we have to wait for them to fix bugs (but instead they add new stupid features).

But oh well, as you said we can always use Xiaomi's aapt for MIUI ROM's. Since MIUI5 is not out yet it's no big deal. THanks for all the hard work iBot, you are a legend.
[Android Software Development] DaOldMan:
I have this ancient problem with any apktool/aapt:

1. I can't recompile ClockPackage from the Samsung JB leaked i9100 Rom (but it seems the same for the S3 clock)

2. I can't recompile keyboards, like SwiftKey where we wanted to add hebrew to the translations

The problems seem to be the same - No resource identifier found. Any1 has suceeded just to decompile and recompile those ?

Thanks a lot,

Thomas
[Android Software Development] iBotPeaches:
Well without an error output, an apk, or any details. Not much I can do.
[Android Software Development] fisha21:
Yup, that did it. Thx again
[Android Software Development] Mach3.2:
Thanks, it compiled now without issues;)
[Android Software Development] denversc:
I have (what I think is) a bug report, probably in the dex -> smali translation (as opposed to the apktool wrapper itself). When I attempt to decompile WordsWithFriends.apk I get 233 classes that fail to decompile due to a NullPointerException at org.jf.dexlib.Code.Analysis.MethodAnalyzer.analyzeAgetObject(MethodAnalyzer.java:2508).

private void analyzeAgetObject(AnalyzedInstruction analyzedInstruction) {
ThreeRegisterInstruction instruction = (ThreeRegisterInstruction)analyzedInstruction.instruction;

RegisterType arrayRegisterType = analyzedInstruction.getPreInstructionRegisterType(instruction.getRegisterB());
assert arrayRegisterType != null;

if (arrayRegisterType.category != RegisterType.Category.Null) {
assert arrayRegisterType.type != null;
if (arrayRegisterType.type.getClassType().charAt(0) != '[') { // <-------------- this is line 2508 where the NPE is thrown
throw new ValidationException(String.format("Cannot use aget-object with non-array type %s",
arrayRegisterType.type.getClassType()));
}

I tried with both apktool1.5.0.tar.bz2 and with apktool_1.5.1PR3.jar and it occurred with both. I just upgraded aapt.exe with my SDK platform-tools to v16.0.1 this morning, and also tried the aapt.exe bundled with apktool-install-windows-r05-ibot.tar.bz2, both exhibiting this NPE.

I have attached the full output from apktool in "apktool_output.txt". The APK was too large to attach directly to a post in XDA, so it's available for download at http://www.mediafire.com/?1hfp53tb70h47mt

Thanks so much for creating this incredibly useful app! Any help you can provide would be appreciated, but this is definitely not a "critical" issue for me. It just means I can't tweak Words With Friends to my liking :)