I'm getting the following error after updating to build tools 25.0.2 (with 23.0.2 it was working just fine):
Error:target API level '25' is out of range ('11' - '24')
Error:Execution failed for task ':app:compileDevDebugRenderscript'.
> com.android.ide.common.process.ProcessException: Error while executing process /usr/local/opt/android-sdk/build-tools/25.0.2/llvm-rs-cc with arguments {-O 3 -I /usr/local/opt/android-sdk/build-tools/25.0.2/renderscript/include/ -I /usr/local/opt/android-sdk/build-tools/25.0.2/renderscript/clang-include/ -p /<redacted>/app/build/generated/source/rs/dev/debug -o /<redacted>/app/build/generated/res/rs/dev/debug/raw -target-api 25 /<redacted>/app/src/main/rs/<redacted>.rs}
I have the following in app/build.gradle:
android {
compileSdkVersion 25
buildToolsVersion '25.0.2'
defaultConfig {
minSdkVersion 21
targetSdkVersion 25
renderscriptTargetApi 21
renderscriptSupportModeEnabled false
...
}
...
}
As you can see renderscriptTargetApi is set to 21, but the new build tools forces it to be 25 regardless. I can't turn on support mode due to a dependency to a library which requires it to be turned off.
Should I just revert back to build tools 23.0.2 and wait for a fix or is there any workarounds to get renderscript to work with the latest build tools?
Seems it bug in build tools r25. I've submitted a ticket to Android tracker: https://code.google.com/p/android/issues/detail?id=260929&thanks=260929&ts=1490175869
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With