I am trying to update my appcompat-v7 in Android Studio project from v20.0.0 to 21.0.0 for use material design component but I allways get the same error:
"Error:Attribute "color" has already been defined"
I have not idea about what to do for fix this error, I searched in internet but I cant get the answer. Here is my gradle:
android {
compileOptions.encoding = "iso-8859-1"
compileSdkVersion 21
buildToolsVersion "21.1.1"
defaultConfig {
applicationId "com.test"
minSdkVersion 11
targetSdkVersion 22
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:support-v4:20.0.0'
compile 'com.google.http-client:google-http-client-gson:1.19.0'
compile 'com.google.code.gson:gson:2.2.4'
compile "com.android.support:appcompat-v7:21.0.+"
}
Here is the path where the conflict exist
C:\Users\Abel Dominguez\Documents\PROYECTOS_ANDROID\definitivos\d2\app\build\intermediates\exploded-aar\com.android.support\appcompat-v7\21.0.3\res\values\values.xml
and this is other error:
Error:Execution failed for task ':app:processDebugResources'.
> com.android.ide.common.internal.LoggedErrorException: Failed to run command:
C:\Users\Abel Dominguez\AppData\Local\Android\sdk1\build-tools\build-tools-21.1.1\aapt.exe package -f --no-crunch -I C:\Users\Abel Dominguez\AppData\Local\Android\sdk1\platforms\android-21\android.jar -M C:\Users\Abel Dominguez\Documents\PROYECTOS_ANDROID\definitivos\d2\app\build\intermediates\manifests\full\debug\AndroidManifest.xml -S C:\Users\Abel Dominguez\Documents\PROYECTOS_ANDROID\definitivos\d2\app\build\intermediates\res\debug -A C:\Users\Abel Dominguez\Documents\PROYECTOS_ANDROID\definitivos\d2\app\build\intermediates\assets\debug -m -J C:\Users\Abel Dominguez\Documents\PROYECTOS_ANDROID\definitivos\d2\app\build\generated\source\r\debug -F C:\Users\Abel Dominguez\Documents\PROYECTOS_ANDROID\definitivos\d2\app\build\intermediates\res\resources-debug.ap_ --debug-mode --custom-package com.wherefriend -0 apk --output-text-symbols C:\Users\Abel Dominguez\Documents\PROYECTOS_ANDROID\definitivos\d2\app\build\intermediates\symbols\debug
Error Code:
1
Output:
C:\Users\Abel Dominguez\Documents\PROYECTOS_ANDROID\definitivos\d2\app\build\intermediates\res\debug\values\values.xml:94: error: Attribute "color" has already been defined