Android Studio中失败[INSTALL_FAILED_OLDER_SDK]?

时间:2015-03-02 09:36:15

标签: android android-studio

我在Android Studio中导入了一个项目并让我发出错误信息:

pkg: /data/local/tmp/mindmine.com.welcometol
Failure [INSTALL_FAILED_OLDER_SDK]

Bellow是我的build.gradle,我将minSdkVersion 21更改为minSdkVersion 8,但我还是错误了:

apply plugin: 'com.android.application'

android {
    compileSdkVersion 21
    buildToolsVersion "21.1.2"

    defaultConfig {
        applicationId "mindmine.com.welcometol"
        minSdkVersion 21
        targetSdkVersion 21
        versionCode 1
        versionName "1.0"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    compile 'com.android.support:recyclerview-v7:21.0.3'
    compile 'com.android.support:cardview-v7:21.0.3'
}

1 个答案:

答案 0 :(得分:1)

我认为您在“清单”中将minSdkVersion 21更改为minSdkVersion 8

在Gradle中更改

defaultConfig {
        applicationId "mindmine.com.welcometol"
        minSdkVersion *<Put yoru min SDK here>*
        targetSdkVersion 21
        versionCode 1
        versionName "1.0"
    }