[Android-development] Need support for including Google Play APK Expansion & Licensing Library package to QT project in Android platform

Tim Day timday at bottlenose.demon.co.uk
Wed May 2 13:38:26 CEST 2018


On Thu, 2018-04-26 at 09:35 +0000, Sethy, Rasmi (GE Healthcare) wrote:
> > I want to download the expansion file from play store as there is a
> > limitation of 100MB of application size in Android.
> > I facing difficulty in adding Android Google Play APK Expansion &
> > Licensing Library to QT application.

*Delurk*.  

This is something I have a bit of an interest in, as I have a >1GByte
"ebook" style app.  So far our (only) solution for Android has been to
distribute it via the Amazon Appstore (which has a limit more like
2GByte on apks I think), but obviously this isn't ideal for reaching
the real mass market.  (I note iOS apps can go up to a couple of GByte
I think, and we've had no similar size issues there... well apart from
>1GByte seems an insane size for an app, although I'm assured there are
plenty of other ebooks of that size out there).

I haven't tried doing anything with the Play "Expansion" stuff
yet.  Did start a thread at https://forum.qt.io/topic/84504/qt-and-goog
le-play-apk-expansion-files-any-experiences/ but it didn't lead
anywhere but a pointer to this list.

There's various issues I'm aware of (besides the fact I don't know a
lot about Android's Java-ey world at all or how to even start adding
that Play Expansion Library thing to the Qt template app):

- The obvious thing would be to have the expansion file be a big rcc
file.  But there's another issue that the memory-mapping used to access
resource files can fail to find a big enough contiguous address space
which that limits this approach to maybe 200MByte files (and you only
get to deploy one or at most two expansion files... so might be enough
for some apps but not mine).  See https://bugreports.qt.io/browse/QTBUG
-48591 and https://stackoverflow.com/questions/33897711/android-mmap-fa
ils-with-out-of-memory; I haven't explored the multiple-rccs-
concatenated-in-a-single-file-approach proposed at the end of the Jira
issue thread any further but think it should probably work (changes to
Qt source code for QResource needed).

- An alternative would be for the resource file to be a zip or similar
and unpack it.  But that's kind of evil because it doubles the amount
of space needed (although presumably the zip could be deleted when
finished with... but there's still a significant "high water mark" of
disk usage needed).

I'm currently leaning more towards just skipping the Expansion Library
(unless anyone has any success stories to make me think it's easy?),
keeping the app minimal (sub-100MByte) and having it download most of
the "content" which forms the bulk of it as rccs from... somewhere (AWS
S3 or something similar; would make it my client's problem) on first
startup... and coming up with a "pure Qt" solution (the app content
would become progressively more rich as rccs were
downloaded).  However, I'm not sure what view the appstore reviewers
have of apps which subsequently download a lot of unreviewed content
from elsewhere (where there's no guarantee it can't be changed after
the app has been released).

Be interested to hear of any other experiences/ideas in this area.
Tim
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/android-development/attachments/20180502/945acf25/attachment.html>


More information about the Android-development mailing list