I currently have this setting in my manifest:
<uses-sdk android:minSdkVersion="4" android:targetSdkVersion="16"/>
and it works for all users. But now I need to enable Google cloud messaging which requires minSdkVersion=”8″ so I am considering just making one version for versions less than 8, and aim the rest of the app to the versions 8 and up.
Is it enough to just have 2 apks, one of which has
<uses-sdk android:minSdkVersion="4" android:targetSdkVersion="16"/>
and the other apk which would have
<uses-sdk android:minSdkVersion="8" android:targetSdkVersion="16"/>
Is that essentially all I need to do? Or is there something else that needs to be configured? And I am assuming the android:targetSdkVersion=”16″ should be changed to 7 for the version targeting the older versions?
Thanks!
from the GCM documentation:
that means you can add a minSdkVersion lover than 8, GCM will just not work on these devices. of course you need to check the SDK version in the code and skip everything that is related to GCM. in that case there is no need for having 2 different APKs.