我有一个已部署到 Play 并与运行 2.1 或更高版本的任何设备兼容的应用程序; AndroidManifest.xml 中没有定义特殊的限制或要求。
尝试通过 Google Play 安装该应用程序但收到不兼容消息的用户曾多次投诉。在所有这些情况下,旁加载应用程序都能完美运行。
更深入地研究问题后发现,在所有情况下,报告问题的人都使用未安装 Google Play 的设备。 IE。该设备可能未通过 Google 的 CTS。
话虽如此,他们可以通过 Google Play 安装其他应用程序,但不能安装我们的应用程序。同样,将我们的应用程序侧载到这些设备上效果很好。有人知道为什么会这样吗?我认为这一定是我在 AndroidManifest.xml 中做错了什么,但我没有发现任何可疑之处。
编辑:这里是 AndroidManifest.xml,为了保护无辜者的姓名而改变:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.foo.bar"
android:versionCode="1"
android:versionName="@string/global_app_version">
<uses-sdk android:minSdkVersion="7" android:targetSdkVersion="10"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<application android:label="@string/global_app_short_name" android:icon="@drawable/app">
<activity android:name=".HomeActivity"
android:theme="@android:style/Theme.Black.NoTitleBar">
<intent-filter android:label="@string/global_app_short_name">
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
<activity android:name=".AActivity"
android:theme="@android:style/Theme.Black.NoTitleBar">
<intent-filter android:label="@string/global_app_short_name">
<action android:name="android.intent.action.VIEW"/>
</intent-filter>
</activity>
<activity android:name=".BActivity"
android:theme="@android:style/Theme.Black.NoTitleBar">
<intent-filter android:label="@string/global_app_short_name">
<action android:name="android.intent.action.VIEW"/>
</intent-filter>
</activity>
<activity android:name=".CActivity"
android:launchMode="singleTask"
android:theme="@android:style/Theme.Black.NoTitleBar"
android:windowSoftInputMode="stateHidden">
<intent-filter android:label="@string/global_app_short_name">
<action android:name="android.intent.action.VIEW"/>
</intent-filter>
</activity>
<activity android:name=".DActivity"
android:launchMode="singleTask"
android:theme="@android:style/Theme.Black.NoTitleBar">
<intent-filter android:label="@string/global_app_short_name">
<action android:name="android.intent.action.VIEW"/>
</intent-filter>
</activity>
<activity android:name=".EActivity"
android:theme="@android:style/Theme.Black.NoTitleBar">
<intent-filter android:label="@string/global_app_short_name">
<action android:name="android.intent.action.VIEW"/>
</intent-filter>
</activity>
<activity android:name=".FActivity"
android:theme="@android:style/Theme.Black.NoTitleBar">
<intent-filter android:label="@string/global_app_short_name">
<action android:name="android.intent.action.VIEW"/>
</intent-filter>
</activity>
<!-- This activity is invoked whenever an xxx is opened -->
<activity android:name=".GActivity"
android:theme="@android:style/Theme.Black.NoTitleBar">
<intent-filter android:label="@string/global_app_short_name">
<action android:name="android.intent.action.VIEW"/>
<action android:name="android.intent.action.EDIT"/>
<category android:name="android.intent.category.DEFAULT"/>
<category android:name="android.intent.category.BROWSABLE"/>
<data android:mimeType="application/xxx"/>
<data android:mimeType="application/yyy"/>
<data android:mimeType="application/zzz"/>
<data android:mimeType="application/aaa"/>
<data android:mimeType="application/bbb"/>
</intent-filter>
</activity>
</application>
</manifest>
最佳答案
我找到了罪魁祸首 - 复制保护已启用。来自谷歌关于设置的注释: http://developer.android.com/guide/google/play/filters.html
To copy protect an application, set copy protection to "On" when you configure publishing options for your application. Google Play will not show copy-protected applications on developer devices or unreleased devices.
换句话说,必须旁加载 Google Play 只是作为未通过 Google CTS 的“未发布设备”/设备的副作用。无论如何,禁用复制保护解决了这个问题。
关于Android 应用与旁加载 Google Play 的设备不兼容,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11158710/