Please configure your build for VectorDrawableCompat问题
来源:互联网 发布:vb语言好学吗 编辑:程序博客网 时间:2024/05/15 10:06
转载自:http://blog.csdn.net/yulei52/article/details/52119832
运行第一个Android Stdio程序就出现下面这个问题,由于对Android Stdio不熟悉整了三个小时才解决,希望这篇博客能帮助更多的人。
问题:Caused by:java.lang.RuntimeException: Unable to start activity ComponentInfo{com.test.rx/com.test.rx.MainActivity}: java.lang.IllegalStateException: This app has been built with an incorrect configuration. Please configure your build for VectorDrawableCompat.
原因:Android 插件版本不兼容,需要gradle 2.0以上。
解决方法:
(1)将build.gradle中的版本改为2.0.0,如下图红框所示。
(2)选择工具栏上的Tools->Android->Sync Project with Gradle Files,同步一下Gradle, 此时会在控制台出错如下错误:
Warning:Gradle version 2.10 is required. Current version is 2.8. If using the gradle wrapper, try editing the distributionUrl in E:\RX\gradle\wrapper\gradle-wrapper.properties to gradle-2.10-all.zip
(3)此刻我们需要修改你的项目下的 \gradle\wrapper\gradle-wrapper.properties文件,将Gradle的版本改为2.10,如下图所示:
(4)点击工具栏上的File->Settings...->Build,Execution,Deployment->Build Tools->Gradle,查看Gradle home的路径是否是gradle-2.10,如果是则就可以运行程序了。
如果不是gradle-2.10,但已经下载了gradle-2.10.zip,将路径指向它,然后就可以运行程序了。
如果没下载,则需要下载gradle-2.10.zip,点击android stdio下面的Terminal,输入gradlew回车,android stdio会自动下载gradle-2.10.zip,如下图所示:
下载的gradle-2.10.zip会被保存到C:\Users\name.xing\.gradle\wrapper\dists\gradle-2.10-all\a4w5fzrkeut1ox71xslb49gst\gradle-2.10
需要将gradle-2.10复制到android stdio安装路径的gradle目录下,最后点击工具栏上的File->Settings...->Build,Execution,Deployment->Build Tools->Gradle,将Gradle home的路径修改为gradle-2.10的路径。
(5)运行程序,大功告成。
- Please configure your build for VectorDrawableCompat问题
- RuntimeException-- Please configure your build for VectorDrawableCompat问题
- Please configure your build for VectorDrawableCompat.
- 导入pullloadmorerecyclerview库出现错误:Please configure your build for VectorDrawableCompat
- 在导入com.android.support:design时的常见错误Please configure your build for VectorDrawableCompat
- This app has been built with an incorrect configuration. Please configure your build for VectorDra
- This app has been built with an incorrect configuration. Please configure your build for VectorDrawa
- This app has been built with an incorrect configuration. Please configure your build for VectorDrawa
- This app has been built with an incorrect configuration. Please configure your build for VectorDrawa
- This app has been built with an incorrect configuration. Please configure your build for VectorDrawa
- android真机测试报错:Please configure your build for VectorDrawa
- This app has been built with an incorrect configuration. Please configure your build for VectorDrawa
- This app has been built with an incorrect configuration. Please configure your build for VectorDra
- This app has been built with an incorrect configuration. Please configure your build for VectorDraw
- This app has been built with an incorrect configuration. Please configure your build for VectorDraw
- This app has been built with an incorrect configuration. Please configure your build for VectorDrawa
- Configure Your Build
- 安装PHPfailed---configure: error: build test failed. Please check the config.log for details
- Android 初学activity的启动模式
- java--动态单分派,静态多分派
- 16汇编 and和or实现大小写转换
- eclipse add and remove 找不到相关项目
- 【DirectX游戏开发】Direct3D初始化
- Please configure your build for VectorDrawableCompat问题
- 判断一个单链表是否为回文
- Cleanflight 之 Eclipse编译环境搭建
- iOS中一个视图上的多个控件同时点击同时响应的问题?
- Activity你真的熟悉吗?看了才知道
- 一天一个设计模式---分类与六大原则
- 5分钟搞懂字节对齐
- GridView中合并单元格
- 代码修改包shape背景文件的背景颜色