I am doing some research on the workloads of SQLite, the de facto database for Android, on mobile devices. And at the beginning, I wanted to write a wrapper for SQLiteDatabase.java and trace all relevant transactions. The amount of code refactoring is too huge for me to finish on my own. Then I tried the official SQLite android package on their website. Same problem here since all these open-source applications use SQLite in their OWN WEIRD WAYS. It takes an eternity for me to figure out how to port the package. The only way out, as I could see at that time, is to modify the Android kernel code, build it from source and flash it to my testbed, a used Nexus 6p succeeded by Xiaomi Mix, which is a great phone by the way. And that is how my last post came out.
Recently I just know the AOSP version on my Nexus 6p could see the debug log messages, while I don’t think it would work on the factory image. Now I could just build those open-source applications on Android studio and see all these loggings! After all these strugglings there seems to be finally a way out. During my experimental builds on those applications I found out the setup guides for those applications are not very straightforward and decided to mark some of the tips down here.
- Wordpress is a perfect application in terms of matching my research purposes. Clean builds, massive usages on SQLite and easy to see through. The only problem is when I try to build it with the newest version of Gradle, which is not a good idea. Except that, you would be all set.
- Telegram suckssssssssssssssssssss. Since it would connect to its own server with your own build, which makes it impossible to see the SQLite trace.
- Download the source: git clone --recursive-submodules https://github.com/DrKLO/Telegram.git
- Get your own
- The whole signingConfigs section
signingConfig signingConfigs.debug signingConfig signingConfigs.release signingConfig signingConfigs.release
- in the module-level build.gradle file. Then you will be all set.
- K9 Mail
- Just remember to clone recursively on all sub-modules. K9 mail is not a good target since it use SQLite in a very light way
- Same as K9-mail, Easy to make and not so many useful traces. The only thing funny is that this open-source app is actually not-free on Google play store. Touche to be such a crappy app and charge users money for using it.