无法使用 Android Studio 构建项目 [英] Failed to build project with Android studio

查看:46
本文介绍了无法使用 Android Studio 构建项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

谁能告诉我为什么我在使用 AndroidStudio 时会出现这个错误?

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.

我已经从 Android SDK 管理器安装了 Android Build-tools 19.0.1

I have installed Android Build-tools 19.0.1 from the Android SDK manager

推荐答案

检查所有 build.gradle 文件是否使用 19.0.x 版本.

Check all your build.gradle files whether they are using the 19.0.x version or not.

buildToolsVersion 将在 build.gradle 文件内的 android 标签下定义,如下所示:

buildToolsVersion will be defined under the android tag inside the build.gradle file, like this:

android {
     compileSdkVersion 19
     buildToolsVersion '19.0.3'

     // Other Configuration
}

您可以在此处找到 Android 构建工具的版本列表 以及SDK 管理器.

这篇关于无法使用 Android Studio 构建项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆