What does “Failure [INSTALL_FAILED_OLDER_SDK]” mean in Android Studio?

Asked
5 years, 9 months ago

Viewed
120k times

I got this Froyo (2.2) device that I am using to make an app.
When I try to run the app directly to the device it shows an error saying

pkg: /data/local/tmp/com.example.HelloWorldProject
Failure [INSTALL_FAILED_OLDER_SDK]

and in another window there’s an error saying

Unable to attach test reporter to test framework or test framework quit unexpectedly

What seem to make the said errors?

EDIT:

AndroidManifest.xml








asked Dec 16 ’13 at 22:29

Abel CallejoAbel Callejo

5,37466 gold badges3838 silver badges5353 bronze badges

After I changed

defaultConfig {
applicationId “com.example.bocheng.myapplication”
minSdkVersion 15
targetSdkVersion ‘L’ #change this to 19
versionCode 1
versionName “1.0”
}

in build.gradle file.

it works

answered Jul 2 ’14 at 17:11

chengbochengbo

3,59344 gold badges2222 silver badges3838 bronze badges

This error

Failure [INSTALL_FAILED_OLDER_SDK]

Means that you’re trying to install an app that has a higher minSdkVersion specified in its manifest than the device’s API level. Change that number to 8 and it should work. I’m not sure about the other error, but it may be related to this one.

answered Dec 16 ’13 at 22:33

hichris123hichris123

7,6151212 gold badges4545 silver badges6464 bronze badges

Besides checking the right minSdkVersion in build.gradle, make sure you have installed all necessary tools and correct SDK Platform for your preferred Android Version in SDK Manager. In Android Studio klick on Tools -> Android -> SDK Manager. Then install at minimum (for Android 2.2 without emulator):

  • Android SDK Tools
  • Android SDK Platform-tools
  • Android SDK Build-tools (latest)
  • Android 2.2 (API 8)
    • SDK Platform
    • Google APIs

This is what worked for me.

answered Jul 7 ’14 at 17:25

iBaffiBaff

39633 silver badges77 bronze badges

Make sure you don’t have a minSdkVersion set in your build.gradle with a value higher than 8. If you don’t specify it at all, it’s supposed to use the value in your AndroidManfiest.xml, which seems to already be properly set.

answered Dec 17 ’13 at 0:32

Scott BartaScott Barta

72.2k2323 gold badges163163 silver badges151151 bronze badges

Just removing uses-sdk tag works for me for such problems.

Veedrac

42.3k1111 gold badges8888 silver badges140140 bronze badges

answered Jun 1 ’14 at 16:54

Failure [INSTALL_FAILED_OLDER_SDK] basically means that the installation has failed due to the target location (AVD/Device) having an older SDK version than the targetSdkVersion specified in your app.

N/B Froyo 2.2 API 8

To fix this simply change

targetSdkVersion=”17″ to targetSdkVersion=”8″

cheers.

answered Aug 18 ’14 at 9:36

Make Sure the Select Run/Debug Configuration is wear or mobile as per your installation in android studio…

answered Apr 18 ’15 at 4:56

Nirav BhavsarNirav Bhavsar

94011 gold badge99 silver badges1616 bronze badges

Failure [INSTALL_FAILED_OLDER_SDK]

For Sumsung note3 I just edit the AndroidManifest.xml file and add the following code:

Raein Hashemi

3,17144 gold badges1818 silver badges3232 bronze badges

answered May 19 ’15 at 6:26

In your manifest file package attribute is set to com.test.helloworld however your activity class is under different package. Change your MyActivity class package to com.example.helloworld

answered Dec 16 ’13 at 23:42

HellboyHellboy

88255 silver badges1111 bronze badges

This is because you mobile has older sdk version than your application..!!!
It means your application need sdk version suppose Lollipop but you mobile has version kitkat.

answered Apr 19 ’15 at 18:49

Fix your gradle file the following way

defaultConfig {
applicationId “package.com.app”
minSdkVersion 8 //this should be lower than your device
targetSdkVersion 21
versionCode 1
versionName “1.0”
}

answered Jun 30 ’15 at 14:38

medameda

40.9k1111 gold badges7575 silver badges115115 bronze badges

In android studio: reduce minSDKversion. It will work…

apply plugin: ‘com.android.application’

android {
compileSdkVersion 23
buildToolsVersion “23.0.1”

defaultConfig {
applicationId “healthcare.acceliant.trianz.com.myapplication”
minSdkVersion 11
targetSdkVersion 23
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:appcompat-v7:23.1.1’
}

answered Nov 23 ’15 at 9:23

gnganpathgnganpath

61799 silver badges1515 bronze badges

I fixed this problem.The device system version is older then the sdk minSdkVersion。
I just modified the minSdkVersion from android_L to 19
to target my nexus 4.4.4.

buildscript {
repositories {
jcenter()
}
dependencies {
classpath ‘com.android.tools.build:gradle:0.12.2’
}
}
apply plugin: ‘com.android.application’

repositories {
jcenter()
}

android {
**compileSdkVersion ‘android-L’** modified to 19
buildToolsVersion “20.0.0”

defaultConfig {
applicationId “com.antwei.uiframework.ui”
minSdkVersion 14
targetSdkVersion ‘L’
versionCode 1
versionName “1.0”
}
buildTypes {
release {
runProguard false
proguardFiles getDefaultProguardFile(‘proguard-android.txt’), ‘proguard-rules.pro’
}
}
}

dependencies {
compile fileTree(dir: ‘libs’, include: [‘*.jar’])
**compile ‘com.android.support:support-v4:21.+’** modified to compile ‘com.android.support:support-v4:20.0.0’
}

how to modified the value by ide.
select file->Project Structure -> Facets -> android-gradle and then modified the compile Sdk Version from android_L to 19

sorry I don’t have enough reputation to add pictures

answered Oct 18 ’14 at 6:21

Ant小波Ant小波

4744 bronze badges

Change file AndroidManifest.xml

answered Jul 18 ’14 at 7:41

Not the answer you’re looking for? Browse other questions tagged android android-studio android-2.2-froyo or ask your own question.

Source

Sharing is caring!