Can anyone tell me why I'm getting this error with AndroidStudio?
Execution failed for task ':sampleapp:preBuild'. > Build Tools Revision 19.0.0+ is required.
I have installed Android Build-tools 19.0.1 from the Android SDK manager
In some cases when your Gradle files are deleted or corrupted you will not be able to download new Gradle files in android studio. In this case, we have to delete the Gradle files which are present already and then again sync your project to download our Gradle files again.
Open your gradle. properties file in Android Studio. Restart Android Studio for your changes to take effect. Click Sync Project with Gradle Files to sync your project.
Check all your build.gradle
files whether they are using the 19.0.x version or not.
buildToolsVersion
will be defined under the android
tag inside the build.gradle
file, like this:
android { compileSdkVersion 19 buildToolsVersion '19.0.3' // Other Configuration }
You can find a list of versions for the Android Build Tools here as well as in the SDK Manager.
Go to Window->Android SDK Manager and run it
You will see Android Build-Tools version installed...
Change build.gradle to reflect the installed version of build tools
This worked for me
OR
Install the version which is shown in error
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