Guest oldmanhouse Posted November 3, 2011 Report Posted November 3, 2011 I'm trying to make a small change to the layout of a keyboard app with comes pre-installed on a ROM I'm using (Mms.apk). Upon recompiling the files back into an apk (and signing them with jarsigner) and redeploying it with adb push, the app always force closes. Checking logcat indicates that there's an error with an XML file (it says it's missing an android:layout_width attribute - which it is.. but adding it makes no difference, as another error will pop up elsewhere. The problem seems to lie with the recompilation process, as the app (in its original form) works just fine without these attributes which are causing a RuntimeException with the edited apk.. Just for the record, even if I make no changes - merely decompile the original apk and then compile it again straight away, the problem remains. If I don't sign the apk, then it doesn't install at all. Perhaps my signing is causing the problem? Here's what I do: apktool d Mms.apk //decompile the original apk (Mms.apk) apktool b Mms //make no alterations and recompile it again cd Mms/dist //change into the directory where the new apk is generated jarsigner -verbose -keystore jspapps.keystore Mms.apk jspapps.keystore //sign the apk with keystore (jspapps.keystore) adb remount //connect to phone.. adb push Mms.apk /system/app //push the apk adb reboot //reboot..... Force close everytime! Any help would be much appreciated. I've been at this for hours now!
Guest oldmanhouse Posted November 3, 2011 Report Posted November 3, 2011 Turns out it's an error in the current build of APKTool (1.41). See the thread here for a resolution: Download new build and overwrite your old apktool.jar with it.
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now