我采用了android 2.3.1工作室,在机器人的build.gradle的Android程序兼容性-V7错误
编译 'com.android.support:appcompat-v7:23.4.0'
有错误
所有com.android.support库必须使用完全相同的版本规范(混合版本可能会导致运行时崩溃)。发现版本24.0.0,23.4.0。例子包括
com.android.support:support-v4:24.0.0
和com.android.support:animated-vector-drawable:23.4.0
这是我的build.gradle
apply plugin: 'com.android.application'
android {
compileSdkVersion 23
buildToolsVersion '25.0.0'
useLibrary 'org.apache.http.legacy'
defaultConfig {
applicationId "com.wsolus.chathuranga.simplifya"
minSdkVersion 16
targetSdkVersion 23
versionCode 22
versionName "2.0.1"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions {
exclude 'META-INF/DEPENDENCIES.txt'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/notice.txt'
exclude 'META-INF/license.txt'
exclude 'META-INF/dependencies.txt'
exclude 'META-INF/LGPL2.1'
} } dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile('org.apache.httpcomponents:httpmime:4.3') {
exclude module: "httpclient"
}
compile 'com.android.support:appcompat-v7:23.4.0'
compile 'com.android.support:design:23.4.0'
compile 'com.android.support:support-v4:23.4.0'
}
请帮我 感谢
这是gradle产出的屏幕截图:
我喜欢这样,然后它告诉buildToolsVersion“24.0.0”太旧,需要更新“25.0.0”我这样做,但问题是相同的 –
现在它的工作对我来说,错误消失了,谢谢Sathya Baman –
不客气 –