Basic steps for editing the APK system:
- Make a backup copy of the APK.
- Decompile the working APK.
- Makes a change.
- Recompile the working APK.
- Copy / paste both the META-INF folder and AndroidManifest.xml from the backup APK (which never decompiled) to the recompiled working APK. Done!
META-INF contains a signature: it makes sense. But what is the purpose of AndroidManifest.xml in keeping the original signature? I tested this myself, and Android did not load the APK with recompiled AndroidManifest.xml (i.e., the original AndroidManifest.xml would not be)
Many manuals indicate the need to copy both META-INF and AndroidManfest.xml from the original APK to the modified APK.
The closest answer I found is that recompiling corrupts AndroidManifest.xml (see http://rootzwiki.com/topic/268-guide-newbies-how-to-port-themes/ ), but I compared the original and the message -recompiling AndroidManifest.XML, and they are identical (says WinMerge, and they have the same MD5 and SHA1 hashes). Another person ( http://miuiandroid.com/community/threads/q-remove-miui-torch-app.16013/ ) suggests that META-INF and AndroidManifest.xml are somehow related to each other.
Everyone does this, but does anyone know why?
source share