On Sat, May 21, 2016 at 8:45 PM, Markus Koschany <a...@debian.org> wrote: > Am 21.05.2016 um 14:38 schrieb Paul Wise: >> Package: apktool >> Version: 2.1.1+dfsg-1 >> Severity: normal >> Usertags: cruft >> >> For some reason apktool seems to think it is appropriate to create >> files in my home directory even though I didn't give permission. > > [...] > > This is intentional but I must admit I don't like it too. Normally > apktool copies the framework files to this directory or, if it is not > available, to java.io.tmpdir. We probably could change that to > ~/.apktool or ~/.local/share/apktool. Thoughts? > > https://ibotpeaches.github.io/Apktool/documentation/#framework-files > > However before you can decode apk files you need to install those > framework files. > > Question to team members: > > Are they included in src:android-platform-frameworks-base or can we make > them available somehow? >From what I can tell by looking at the source, they aren't. However, it can be easily made available given that 'framework-res.apk' is a "basic" package with just resources.
A one-line command `aapt package -x -M core/res/AndroidManifest.xml -S core/res/res -A core/res/assets -F framework-res.apk` makes an apk which apktool happily installs. It worked with a random apk I had lying around. Note: The debian aapt package didn't work, I would get a " aapt: tools/aapt/Images.cpp:811: void checkNinePatchSerialization(android::Res_png_9patch*, void*): Assertion `outPatch->getXDivs()[i] == inPatch->getXDivs()[i]' failed. aapt: tools/aapt/Images.cpp:811: void checkNinePatchSerialization(android::Res_png_9patch*, void*): Assertion `outPatch->getXDivs()[i] == inPatch->getXDivs()[i]' failed. aapt: tools/aapt/Images.cpp:811: void checkNinePatchSerialization(android::Res_png_9patch*, void*): Assertion `outPatch->getXDivs()[i] == inPatch->getXDivs()[i]' failed. " error when trying to run the same command with that. Installed version is: 1:6.0.1+r16-1+b1 I wasn't able to build it from source either, with a complaint about missing expat.h, though that might be the configuration of my local system. I'll investigate those and then properly file bug reports afterwards. Till then, I used the prebuilt binaries google distributes for testing the compile. > > The original apktool.jar embeds framework-res.apk from the Android Open > Source Project but they are not part of apktool's sources. > > This bug is also related to > > https://bugs.debian.org/824933 > > Markus > > > > _______________________________________________ > Android-tools-devel mailing list > android-tools-de...@lists.alioth.debian.org > http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/android-tools-devel