首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >android -“您的设备与此版本不兼容”

android -“您的设备与此版本不兼容”
EN

Stack Overflow用户
提问于 2012-09-07 15:49:40
回答 7查看 7K关注 0票数 5

我在play商店中放置了一个应用程序,我的朋友正在运行4.1(Nexus 7),在尝试安装我的应用程序时收到以下消息:“您的设备与此版本不兼容”。为什么会出现这种情况?请任何人都能帮助我。

代码语言:javascript
运行
复制
Manifeast file

< ?xml version="1.0" encoding="utf-8"?>

< manifest xmlns:android="http://schemas.android.com/apk/res/android"
      package="com.ibkr.pcg"
      android:versionCode="3"
      android:versionName="1.1">

< uses-sdk android:minSdkVersion="7"  
      android:targetSdkVersion="8"/>
<uses-permission android:name="android.permission.INTERNET"></uses-permission> 
<uses-permission android:name="android.permission.CAMERA" />        
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" ></uses-permission>  

<!-- C2DM Permissions Start -->
 <!-- Only this application can receive the messages and registration result --> 
<permission android:name="com.ibkr.pcg.permission.C2D_MESSAGE" android:protectionLevel="signature" />
<uses-permission android:name="com.ibkr.pcg.permission.C2D_MESSAGE" /> 

 <!-- This app has permission to register and receive message -->
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
<!-- End of the C2DM Permissions -->

<application android:icon="@drawable/pcgicon" 
    android:label="@string/app_name" 
    android:theme="@android:style/Theme.NoTitleBar.Fullscreen" 
    android:name="MyApplication"
    android:debuggable="true">
    <activity android:name=".PriceCheckGuruSplash"
              android:label="@string/app_name">      
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />    
        </intent-filter>  
    </activity>

     <!-- Only C2DM servers can send messages for the app. If permission is not set - any other app can generate it --> 
    <receiver
     android:name=".C2DMMessageReciever" android:permission="com.google.android.c2dm.permission.SEND" >
      <!-- Receive the actual message -->
     <intent-filter >
            <action android:name="com.google.android.c2dm.intent.RECEIVE" >  
            </action>
            <category android:name="com.ibkr.pcg" /> 
        </intent-filter>
    </receiver>

   <receiver
        android:name=".C2DMRegistrationReceiver"
        android:permission="com.google.android.c2dm.permission.SEND" >
        <intent-filter >
            <action android:name="com.google.android.c2dm.intent.REGISTRATION" >
            </action>
            <category android:name="com.ibkr.pcg" />
        </intent-filter>
    </receiver>

    <activity android:name="MessageReceivedActivty" android:screenOrientation="portrait"/>
    <activity android:name="LoginScreen" android:screenOrientation="portrait"> </activity>
    <activity android:name="RegistrationScreen" android:screenOrientation="portrait"> </activity>
    <activity android:name="ForgotPasswordScreen" android:screenOrientation="portrait"> </activity>
    <activity android:name="UserPreferences" android:screenOrientation="portrait"> </activity>
    <activity android:name="TrackedItems" android:screenOrientation="portrait"> </activity> 
    <activity android:name="WebPage" android:screenOrientation="portrait"> </activity>
    <activity android:name="CustomTabActivity" android:screenOrientation="portrait"> </activity>
    <activity android:name="TabGroup1Activity" android:screenOrientation="portrait"> </activity>
    <activity android:name="TabGroup2Activity" android:screenOrientation="portrait"> </activity>
    <activity android:name="TabGroup3Activity" android:screenOrientation="portrait"> </activity>
    <activity android:name="TabGroup4Activity" android:screenOrientation="portrait"> </activity>
    <activity android:name="SearchScreen" android:screenOrientation="portrait"> </activity>
    <activity android:name="SearchResultsScreen" android:screenOrientation="portrait"></activity>
    <activity android:name="ProductDisplay" android:screenOrientation="portrait"></activity>
    <activity android:name="VendorsDisplay" android:screenOrientation="portrait"></activity>
    <activity android:name="Filter" android:screenOrientation="portrait"></activity>
    <activity android:name="barcodeScanner" android:screenOrientation="portrait"></activity>
    <activity android:name="ScannerPage" android:screenOrientation="portrait"></activity> 
    <activity android:name="Linegraphpage" android:screenOrientation="landscape"></activity>        
    <activity android:name="org.achartengine.GraphicalActivity" android:screenOrientation="landscape"/> 
    <activity android:name="org.acra.CrashReportDialog"
    android:theme="@android:style/Theme.Dialog"
    android:launchMode="singleInstance"
    android:excludeFromRecents="true"
    android:finishOnTaskLaunch="true" />
</application>

< /manifest>

EN

回答 7

Stack Overflow用户

回答已采纳

发布于 2012-09-07 15:59:04

//删除此android:targetSdkVersion="8“

而且Nexus7没有后置摄像头功能。

代码语言:javascript
运行
复制
<uses-permission android:name="android.permission.CAMERA" />

注意:如果您通过意图使用摄像头,则您的应用程序不需要请求此权限。摄像头功能-您的应用程序还必须声明摄像头功能的使用,例如:

代码语言:javascript
运行
复制
  <uses-feature android:name="android.hardware.camera" />

有关相机功能的列表,请参阅清单功能参考。将摄像头功能添加到清单中会导致Google Play阻止将您的应用程序安装到不包含摄像头或不支持您指定的摄像头功能的设备。For more information

如果您的应用程序可以使用摄像头或摄像头功能进行正常操作,但不需要它,您应该在清单中指定它,包括android:required属性,并将其设置为false:

注意:您需要提到supports-screens

票数 5
EN

Stack Overflow用户

发布于 2012-09-07 16:00:36

这是因为您的'android.permission.ACCESS_NETWORK_STATE‘权限-该设备没有手机调制解调器,您需要在权限中输入android:required="false“才能允许将其安装在不支持它的设备上

为了控制过滤,

总是在元素中显式声明硬件功能,而不是依靠Google Play来“发现”元素中的需求。然后,如果要禁用对特定功能的过滤,可以向声明添加android:required="false“属性。

http://developer.android.com/guide/topics/manifest/uses-permission-element.html

票数 5
EN

Stack Overflow用户

发布于 2012-09-07 16:01:09

就像其他人已经建议的那样-相机可能是这里的一个问题。android开发者博客上有一篇关于Nexus7的好文章,基本上它只有一个前置摄像头,所以你的应用程序请求默认摄像头要求将会失败……

基本上,你需要扩展请求,说它不是关键的,然后在你的应用程序中处理细节...

代码语言:javascript
运行
复制
<uses-feature android:name="android.hardware.camera" 
              android:required="false"/>

有关更多信息,请访问链接http://android-developers.blogspot.com.au/2012/07/getting-your-app-ready-for-jelly-bean.html

票数 2
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/12313927

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档