[英]Android Studio-INSTALL_FAILED_OLDER_SDK
In Android studio bulid is successful but while running the project I got the following error- 在Android Studio中,bulid成功,但是在运行项目时出现以下错误-
pkg: /data/local/tmp/com.facebooklogin Failure [INSTALL_FAILED_OLDER_SDK] pkg:/data/local/tmp/com.facebooklogin失败[INSTALL_FAILED_OLDER_SDK]
I am trying to run project in my mobile which has API 16 我正在尝试在具有API 16的手机中运行项目
My build.gradle file is- 我的build.gradle文件是-
apply plugin: 'com.android.library'
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:0.12.+'
}
}
android {
compileSdkVersion 19
buildToolsVersion "20.0.0"
defaultConfig {
applicationId "com.facebook.android"
minSdkVersion 14
targetSdkVersion 19
}
dependencies {
compile 'com.android.support:support-v4:20.0.0'
compile files('libs/bolts.jar')
}
}
Another build.gradle file is- 另一个build.gradle文件是-
apply plugin: 'android'
android {
compileSdkVersion 'android-L'
buildToolsVersion "20.0.0"
defaultConfig {
applicationId "com.facebooklogin"
minSdkVersion 14
targetSdkVersion 18
}
buildTypes {
release {
runProguard false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
}
}
dependencies {
compile project(':facebookSDK')
compile 'com.android.support:support-v4:20.0.0'
compile 'com.android.support:appcompat-v7:+'
}
and AnroidManifest.xml is- 和AnroidManifest.xml是-
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.facebooklogin"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="14"
android:targetSdkVersion="19" />
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.USE_CREDENTIALS" />
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<meta-data
android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version" />
<activity
android:name="info.androidhive.google.SplashScreen"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="info.androidhive.google.ViewFlipperSampleActivity"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="info.androidhive.google.MainFragment"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="info.androidhive.google.MainActivity"
android:label="@string/app_name" >
</activity>
<meta-data android:name="com.facebook.sdk.ApplicationId" android:value="@string/app_id"/>
<activity android:label="@string/app_name" android:name="com.facebook.LoginActivity"></activity>
<activity
android:name="info.androidhive.google.slidingmenu.SlidingMenu"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
You device is API 16 corresponding to Jelly Bean. 您的设备是与Jelly Bean对应的API 16。 Your build.gradle file has the following statement
您的build.gradle文件具有以下语句
android {
compileSdkVersion 'android-L'
Try changing to a version compatible with your device or upgrade your device to a higher API level. 尝试更改为与设备兼容的版本,或将设备升级到更高的API级别。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.