Many fixes and some improvements to prepare for the android UI module

Notes:
* Not all pthreads features are supported on Android, thus the changes.
* Changing the `data_store` signature is enough to support nulls because the APIs of both underlying implementations already supported them.
* Declaring the lines for <activity> in the modules allows for non-fullscreen and non-orientation-locked apps!