I know similar question is posted here. I uploaded an app to Google Play Store but it is incompatible with all the devices. The app is actually a SignalR based chat applicat
As default, any android feature has android:required="true". Hence, when you upload apk to Google Play, bots see android:required="true". It assumes that your app won't work unless that feature is available. Hence, you get this "0 devices supported".
Simply making android:required="false" solves the problem.
I had faced same situation last week.
And I found the main problem is the "signalr-client-sdk.jar" was packed not correct for android.
folder inside the "signalr-client-sdk.jar"
signalr-client-sdk.jar
|
|-lib
| |
| |-getLibs.ps1
| |-getLibs.sh
| |-gson-2.2.2.jar
These three file will be pack into apk "lib" folder. It will work fine when your app with armeabi,x86,x86_64 native supprot library(*.so), but wrong with none. And make google developer console web to filter qualifier support device wrong.
put this code to fix the problem
packagingOptions {
exclude 'lib/getLibs.ps1'
exclude 'lib/getLibs.sh'
exclude 'lib/gson-2.2.2.jar'
}
Hope this helps
I solved this issue by fixing the conflicting jar files. I posted them on github. https://github.com/eak65/FixedSignalRJar
We've had some success and been able to successfully integrate SignalR into our Android application and have an APK that operates correctly across multiple devices. However, whenever we attempt to upload our APK to the Play Store it always reports 0 Support Devices.
This number returns again if we remove the SignalR Java/Android Cient .JAR Files.
Through discussion with Google Play Support, we were able to get the following insight:
Thanks for your patience. My tools have confirmed that the issue is being caused by the following which are declared as native platforms: getLibs.ps1, getLibs.sh, gson-2.2.2.jar
While we are able to determine the permission or feature that is causing a compatibility conflict, we are unable to provide technical development support to explain why the conflict is occurring, or how to resolve the conflict. I'm sorry we can't provide a specific resolution.
The issue is definitely caused by using the libraries as native platforms.
Only a partial answer, but just want to share for anyone else that is facing this issue
We have been able to get the APK to generate once we use .AAR file, but then the SignalR Connection no longer works. Note sure how @Jhonny managed to get this working, but we have only been able to generate the one .AAR file (for android), but the general java module doesn't compile into .AAR.
Finally i solved the problem.Here two solutions have been posted.
Solution 1 : using aar files
Step 1
First i convert my eclipse project into Gradle.
Step 2
Downloading latest SignalR from this link.Generate the aar files. Add these files as dependencies.
Step 3
Updated my Manifest file.I missed some permissions for location support. Now this is the new AndroidManifest.xml
<uses-feature
android:glEsVersion="0x00020000"
android:required="false"/>
<uses-feature
android:name="android.permission.INTERNET"
android:required="false" />
<uses-sdk
android:minSdkVersion="11"
android:targetSdkVersion="19"
android:maxSdkVersion="21" />
<supports-screens
android:anyDensity="true"
android:largeScreens="true"
android:normalScreens="true"
android:smallScreens="true"
android:resizeable="true" />
<compatible-screens>
<!-- small size screens -->
<screen android:screenSize="small" android:screenDensity="ldpi" />
<screen android:screenSize="small" android:screenDensity="mdpi" />
<screen android:screenSize="small" android:screenDensity="hdpi" />
<screen android:screenSize="small" android:screenDensity="xhdpi" />
<!--Only hdpi and xhdpi for normal size screens -->
<screen android:screenSize="normal" android:screenDensity="ldpi" />
<screen android:screenSize="normal" android:screenDensity="mdpi" />
<screen android:screenSize="normal" android:screenDensity="hdpi" />
<screen android:screenSize="normal" android:screenDensity="xhdpi" />
<!-- all large size screens -->
<screen android:screenSize="large" android:screenDensity="ldpi" />
<screen android:screenSize="large" android:screenDensity="mdpi" />
<screen android:screenSize="large" android:screenDensity="hdpi" />
<screen android:screenSize="large" android:screenDensity="xhdpi" />
<!-- all xlarge size screens -->
<screen android:screenSize="xlarge" android:screenDensity="ldpi" />
<screen android:screenSize="xlarge" android:screenDensity="mdpi" />
<screen android:screenSize="xlarge" android:screenDensity="hdpi" />
<screen android:screenSize="xlarge" android:screenDensity="xhdpi" />
<!-- Special case for Nexus 7 -->
<screen android:screenSize="large" android:screenDensity="213" />
</compatible-screens>
<permission android:name="com.test.permission.MAPS_RECEIVE" android:protectionLevel="signature"/>
<uses-permission android:name="com.test.permission.MAPS_RECEIVE"/>
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES"/>
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
Ofcourse it have application tag and activities as well.
Solution 2: using jar files
Step 1
Create a directory named "libs" inside your main package and paste all the jar files.You can download jar files from this link
Step 2
Add dependencies in build.gradle of main package/app
Step 3
Now this how my project's main build.gradle looks like.
Step 4
This is how my settings.gradle looks like
Step 5
After doing all these steps you still have import errors.So invalidate cache and restart
Final Output on Google Play
Now it supports over 7K devices
Cheers :)