android:我如何构建我的应用程序,在具有Intel CPU的设备上工作?

时间:2015-04-16 09:01:27

标签: android arm cpu intel abi

如何构建适用于采用Intel CPU的设备的应用程序?我的应用程序在带有arm技术的设备上工作,但是当我尝试在装有Intel CPU的设备上安装我的应用程序时,它会显示以下消息:

  

兼容Devicenot

并在日志中显示此消息:

  

失败[INSTALL_FAILED_CPU_ABI_INCOMPATIBLE]

这是我的项目build.gradle文件:

apply plugin: 'com.android.application'

android {
compileSdkVersion 19
buildToolsVersion "19.1.0"

defaultConfig {
    applicationId "com.test.test"
    minSdkVersion 16
    targetSdkVersion 19
    versionCode 1
    versionName "0.0.1"
}
buildTypes {
    release {
        minifyEnabled  false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}


}

dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
// You must install or update the Google Repository through the SDK manager        to use this dependency.
compile 'com.google.android.gms:play-services:6.1.71'
compile 'com.android.support:appcompat-v7:20.0.0'
compile 'com.squareup.picasso:picasso:2.4.0'
compile 'com.pkmmte.view:circularimageview:1.1'
compile 'org.apache.directory.studio:org.apache.commons.io:2.4'
compile 'com.wefika:flowlayout:0.4.0'
compile 'com.github.navasmdc:MaterialDesign:1.+@aar'
}

我将android studio IDE用于我的项目。 我如何构建可在arm和Intel CPU上运行的设备上运行的APK文件? 感谢

2 个答案:

答案 0 :(得分:1)

您应该使用gradle拆分,以便为不同的平台轻松构建应用。更多阅读here

答案 1 :(得分:0)

我终于找到了问题!我删除了这个库

  

' org.apache.directory.studio:org.apache.commons.io:2.4'

然后我的应用程序在具有Intel cpu的设备上运行