2

I've an APK that I'm trying to publish on the play store. After uploading it I see that there are no supported devices. I've tried removing all the permissions and re-uploading and activating the APK, I still get 0 supported devices.

I'm wondering, what other caveats are there that will cause the supported devices to go down to zero. I've read that if I'm not including libraries correctly this type of thing will happen, but I'm not quite sure and need some clarification. Also, if there are any tools that exist to help check APK compatibility.

Here's a bit of my manifest:

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />

<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />

<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.READ_CONTACTS"/>

<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS"/>
<uses-permission android:name="android.permission.RECORD_AUDIO"/>

<uses-permission android:name="android.permission.VIBRATE" />
<uses-permission android:name="android.permission.MANAGE_ACCOUNTS"/>

<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES"/>

<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.USE_CREDENTIALS"/>
<uses-permission android:name="android.permission.WAKE_LOCK" />

<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
<permission android:name="com.my.app.permission.C2D_MESSAGE"
            android:protectionLevel="signature" />
<uses-permission android:name="com.my.app.permission.C2D_MESSAGE" />


<uses-feature android:name="android.hardware.camera"
        android:required="false"/>
<uses-feature
    android:name="android.hardware.location"
    android:required="false" />
<uses-feature
    android:name="android.hardware.location.network"
    android:required="false" />
<uses-feature android:name="android.hardware.location.gps"
        android:required="false"/>
<uses-feature
    android:name="android.hardware.wifi"
    android:required="false" />

<uses-feature
    android:glEsVersion="0x00020000"
    android:required="true" />
<uses-sdk
    android:minSdkVersion="8"
    android:targetSdkVersion="17" />

Thanks!

EDIT

Output of

aapt dump badging app.apk

package: name='com.my.app' versionCode='16' versionName='0.5.0'
uses-permission:'android.permission.INTERNET'
uses-permission:'android.permission.ACCESS_WIFI_STATE'
uses-permission:'android.permission.ACCESS_COARSE_LOCATION'
uses-permission:'android.permission.ACCESS_NETWORK_STATE'
uses-permission:'android.permission.ACCESS_FINE_LOCATION'
uses-permission:'android.permission.WRITE_EXTERNAL_STORAGE'
uses-permission:'android.permission.READ_EXTERNAL_STORAGE'
uses-permission:'android.permission.READ_CONTACTS'
uses-permission:'android.permission.MODIFY_AUDIO_SETTINGS'
uses-permission:'android.permission.RECORD_AUDIO'
uses-permission:'android.permission.VIBRATE'
uses-permission:'android.permission.MANAGE_ACCOUNTS'
uses-permission:'com.google.android.providers.gsf.permission.READ_GSERVICES'
uses-permission:'android.permission.GET_ACCOUNTS'
uses-permission:'android.permission.USE_CREDENTIALS'
uses-permission:'android.permission.WAKE_LOCK'
uses-permission:'com.google.android.c2dm.permission.RECEIVE'
uses-permission:'com.my.app.permission.C2D_MESSAGE'
uses-feature-not-required:'android.hardware.camera'
uses-feature-not-required:'android.hardware.location'
uses-feature-not-required:'android.hardware.location.network'
uses-feature-not-required:'android.hardware.location.gps'
uses-feature-not-required:'android.hardware.wifi'
uses-gl-es:'0x20000'
sdkVersion:'8'
targetSdkVersion:'17'
application-label:'myApp'
application-label-ca:'myApp'
application-label-da:'myApp'
application-label-fa:'myApp'
application-label-ja:'myApp'
application-label-nb:'myApp'
application-label-be:'myApp'
application-label-de:'myApp'
application-label-af:'myApp'
application-label-bg:'myApp'
application-label-th:'myApp'
application-label-fi:'myApp'
application-label-hi:'myApp'
application-label-vi:'myApp'
application-label-sk:'myApp'
application-label-uk:'myApp'
application-label-el:'myApp'
application-label-nl:'myApp'
application-label-pl:'myApp'
application-label-sl:'myApp'
application-label-tl:'myApp'
application-label-am:'myApp'
application-label-in:'myApp'
application-label-ko:'myApp'
application-label-ro:'myApp'
application-label-ar:'myApp'
application-label-fr:'myApp'
application-label-hr:'myApp'
application-label-sr:'myApp'
application-label-tr:'myApp'
application-label-cs:'myApp'
application-label-es:'myApp'
application-label-ms:'myApp'
application-label-et:'myApp'
application-label-it:'myApp'
application-label-lt:'myApp'
application-label-pt:'myApp'
application-label-hu:'myApp'
application-label-ru:'myApp'
application-label-zu:'myApp'
application-label-lv:'myApp'
application-label-sv:'myApp'
application-label-iw:'myApp'
application-label-sw:'myApp'
application-label-en_GB:'myApp'
application-label-zh_CN:'myApp'
application-label-pt_BR:'myApp'
application-label-es_US:'myApp'
application-label-pt_PT:'myApp'
application-label-zh_TW:'myApp'
application-icon-120:'res/drawable-ldpi/ic_launcher.png'
application-icon-160:'res/drawable-mdpi/ic_launcher.png'
application-icon-240:'res/drawable-hdpi/ic_launcher.png'
application-icon-320:'res/drawable-xhdpi/ic_launcher.png'
application: label='myApp' icon='res/drawable-mdpi/ic_launcher.png'
launchable-activity: name='com.my.app.myApp_fragment_pager'  label='myApp' icon=''
uses-feature:'android.hardware.microphone'
uses-implied-feature:'android.hardware.microphone','requested android.permission.RECORD_AUDIO permission'
uses-feature:'android.hardware.touchscreen'
uses-implied-feature:'android.hardware.touchscreen','assumed you require a touch screen unless explicitly made optional'
uses-feature:'android.hardware.screen.landscape'
uses-implied-feature:'android.hardware.screen.landscape','one or more activities have specified a landscape orientation'
main
other-activities
other-receivers
other-services
supports-screens: 'small' 'normal' 'large' 'xlarge'
supports-any-density: 'true'
locales: '--_--' 'ca' 'da' 'fa' 'ja' 'nb' 'be' 'de' 'af' 'bg' 'th' 'fi' 'hi' 'vi' 'sk' 'uk' 'el' 'nl' 'pl' 'sl' 'tl' 'am' 'in' 'ko' 'ro' 'ar' 'fr' 'hr' 'sr' 'tr' 'cs' 'es' 'ms' 'et' 'it' 'lt' 'pt' 'hu' 'ru' 'zu' 'lv' 'sv' 'iw' 'sw' 'en_GB' 'zh_CN' 'pt_BR' 'es_US' 'pt_PT' 'zh_TW'
densities: '120' '160' '240' '320'

and Support screens tag

<supports-screens android:smallScreens="true"
                  android:anyDensity="true"
                  android:largeScreens="true"
                  android:normalScreens="true"
                  android:resizeable="true">
</supports-screens>
kevswanberg
  • 2,079
  • 16
  • 21

3 Answers3

1

If your going to use GCM

  1. you must have enabled Google Cloud Messaging for Android in Google API Console
  2. installed on the server generated keys of the Google APIs Console

Or remove these permissions

<uses-feature android:name="android.hardware.camera"
        android:required="false"/>
<uses-feature
    android:name="android.hardware.location"
    android:required="false" />
<uses-feature
    android:name="android.hardware.location.network"
    android:required="false" />
<uses-feature android:name="android.hardware.location.gps"
        android:required="false"/>
<uses-feature
    android:name="android.hardware.wifi"
    android:required="false" />

<uses-feature
    android:glEsVersion="0x00020000"
    android:required="true" />
Raul
  • 61
  • 6
  • Removing the permissions you suggested didn't have any effect. Could you explain point 2 further for me? Do I need to reference the keys in my manifest file or put them in a keystore somewhere? I followed these instructions (http://developer.android.com/google/gcm/gs.html) and GCM push messages have been working in my app. – kevswanberg Aug 05 '13 at 20:00
  • You could put all the Manifest? – Raul Aug 05 '13 at 21:14
  • But if you can receive notifications. the problem is the Manifest. The manifest has a bad line and therefore rejects the Strore Play... check your code, may be that a line is bad. example. .Wifi or .wifi – Raul Aug 05 '13 at 21:22
  • Look, the same problem http://stackoverflow.com/questions/14020237/android-app-is-supported-by-0-devices the manifest is the problem ;) – Raul Aug 05 '13 at 21:26
  • That's what I thought too, but even when removing all the permissions, same thing. I'm using Android studio, the permissions I have put are getting auto-filled so I don't think they are incorrect. – kevswanberg Aug 06 '13 at 15:30
1

I had the same problem -

I've had some images in the lib/ directory and the play store said my application was compatible with 0 devices - after renaming the directory and republishing the apk this was not an issue anymore.

  • In my case there was no permission error or any targetsdk issues. Just had to remove compile 'org.apache.directory.studio:org.apache.commons.io:2.4' – Suyash Dixit Sep 20 '15 at 08:17
0

There was a couple of things wrong with what I was doing. When I updated my version of android studio I had to fix a couple of things. Now my issues are fixed,

  1. I was uploading a debug version of the app. To fix it I had to to create a new keystore and project and upload the APK. I thought that this error would be caught by the play store but I guess not.
  2. Some of the jars that I was referencing weren't in the /libs folder of my project. Even if this wasn't causing the issue, its still good practice to do this from the start.

Hopefully this information can help some other souls that are getting started with publishing on Android.

kevswanberg
  • 2,079
  • 16
  • 21