简体   繁体   English

当我的minSDKVersion为21时,发生了内置错误“目标21+目前不支持Renderscript支持模式”

[英]A built error “Renderscript support mode is not currently supported with target 21+” happened when my minSDKVersion is 21

It is the build.gradle on project 它是项目的build.gradle

dependencies { 依赖{

    classpath 'com.android.tools.build:gradle:2.1.0-alpha1'
 .....
}

It is the build.gradle on app 它是app上的build.gradle

android { android {

compileSdkVersion 23
buildToolsVersion '23.0.2'
defaultConfig {
    minSdkVersion 21
    targetSdkVersion 23
    .......
    //Renderscript support mode is not currently supported with renderscript target 21+
    renderscriptTargetApi 19
    renderscriptSupportModeEnabled true
}

When I built it , I met a error, 当我构建它时,我遇到了一个错误,

Renderscript support mode is not currently supported with renderscript target 21+ Renderscript目标21+目前不支持Renderscript支持模式

If I change minSdkVersion as 19, it can be built successfully. 如果我将minSdkVersion更改为19,则可以成功构建它。

But I need to set minSDKVersion as 21. Any one know what's going wrong ? 但我需要将minSDKVersion设置为21.任何人都知道出了什么问题?

Yep, this is a bug. 是的,这是一个错误。 The bug related to renderscriptTargetApi has been fixed in gradle-plugin 2.1.0 and Build-Tools 23.0.3. 有关错误renderscriptTargetApi已被固定在gradle这个-插件2.1.0和内置工具23.0.3。 Please try it out: 请尝试一下:

buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.1.0-alpha5'
    }
}


android {
    compileSdkVersion 23
    buildToolsVersion "23.0.3"
    ...
}

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 当应用程序的minSdkVersion为21时,我的活动应该扩展什么? - What should my activity extend when application's minSdkVersion is 21? 由于minSdkVersion从21更改为14而导致的错误 - Error due to Changing minSdkVersion from 21 to 14 Gradle 错误更新:预期 minSdkVersion &gt;= 21 但发现 1 - Error at Gradle Update: Expected minSdkVersion >= 21 but found 1 生物识别提示适用于 API 21+,但 API 19 显示错误 - Biometrics prompt works with API 21+ but API 19 shows error 我的应用程序的minSdkVersion为14,targetSdkVersion为21,但是Google Play判断它仅支持Android 4.0〜4.4 - My app's minSdkVersion is 14 and targetSdkVersion is 21 but Google Play judge it just support Android 4.0~4.4 例外 minSdkVersion &gt;= 21 但发现 1 - Excepted minSdkVersion >= 21 but found 1 不必要; SDK_INT始终&gt; = 21,而我的minSdkVersion为16 - Unnecessary; SDK_INT is always >= 21, while my minSdkVersion is 16 是否可以在&lt;21上使用camera,在21+上使用camera2? - Is it possible to use camera on < 21 and camera2 on 21+? minSdkVersion 21,但在6.0上仍然崩溃 - minSdkVersion 21 but still crashing on 6.0 Robolectric 3.0不适用于AppCompat 21+ - Robolectric 3.0 not working with AppCompat 21+
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM