Android gradle问题解决: This app has been built with an incorrect configuration. Please configure your build for VectorDrawableCompat
2016-10-18 16:30
906 查看
1. 问题描述:
Android Studio在运行模拟器某些机型或者真机某些机型的时候发生闪退。
错误如下:
Java.lang.RuntimeException: Unable to start activity ComponentInfo{com.xxx.MainActivity}: java.lang.IllegalStateException: This app has been built with an incorrect configuration. Please configure your build for VectorDrawableCompat.
产生的原因是:com.android.support:appcompat-v7与rasterized vectors不兼容,gradle2.0及其之上,library的资源没有栅格化,所以不会发生这个问题
2. 解决方案:
1.在projectgradle中将gradle版本改为2.0或者之上
2. 再次运行,此时控制台输出异常:Warning:Gradle version 2.10 is required. Current version is 2.8. If using the gradle wrapper, try editing the distributionUrl in xxx\bbb\gradle-wrapper.properties to gradle-2.10-all.zip
按照路径所指出的地址,找到文件gradle-wrapper.properties,编辑最后一句版本号为日志中所输出的版本
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
3. 再次运行,还是错误,原因是你还没有下载gradle-2.10
这时可以从网上下载一个gradle-2.10.zip并解压,然后放到AndroidStudiodd的默认gradle配置目录
然后再在AndroidStudio中做一下设置,如下图
最后再运行IDE, Ok一切搞定!!
Android Studio在运行模拟器某些机型或者真机某些机型的时候发生闪退。
错误如下:
Java.lang.RuntimeException: Unable to start activity ComponentInfo{com.xxx.MainActivity}: java.lang.IllegalStateException: This app has been built with an incorrect configuration. Please configure your build for VectorDrawableCompat.
产生的原因是:com.android.support:appcompat-v7与rasterized vectors不兼容,gradle2.0及其之上,library的资源没有栅格化,所以不会发生这个问题
2. 解决方案:
1.在projectgradle中将gradle版本改为2.0或者之上
2. 再次运行,此时控制台输出异常:Warning:Gradle version 2.10 is required. Current version is 2.8. If using the gradle wrapper, try editing the distributionUrl in xxx\bbb\gradle-wrapper.properties to gradle-2.10-all.zip
按照路径所指出的地址,找到文件gradle-wrapper.properties,编辑最后一句版本号为日志中所输出的版本
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
3. 再次运行,还是错误,原因是你还没有下载gradle-2.10
这时可以从网上下载一个gradle-2.10.zip并解压,然后放到AndroidStudiodd的默认gradle配置目录
然后再在AndroidStudio中做一下设置,如下图
最后再运行IDE, Ok一切搞定!!
相关文章推荐
- 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
- 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 VectorDrawa
- java.lang.IllegalStateException: This app has been built with an incorrect configuration. Please co
- 解决问题:IllegalStateException - configure your build for VectorDrawableCompat
- Please configure your build for VectorDrawableCompat问题
- Caused by: java.lang.IllegalStateException: This app has been built with an incorrect configuration.
- This app has been built with an incorrect configuration
- RuntimeException-- Please configure your build for VectorDrawableCompat问题
- 导入pullloadmorerecyclerview库出现错误:Please configure your build for VectorDrawableCompat
- 使用环信开发项目遇到错误提示 configure your build for VectorDrawableCompat
- android真机测试报错:Please configure your build for VectorDrawa
- android studio DEX 方法超过64K限制和gradle编译OOM问题解决,异常名:Error:Execution failed for task ':app:dexDebug'. >
- code:block运行遇到It seems that this project has not been built yet.问题解决
- 【我的Android进阶之旅】解决bug:You need to use a Theme.AppCompat theme (or descendant) with this activity.
- Android build.gradle 问题:transformClassesWithPreJackPackagedLibrariesForDebug