[我正在尝试使用Gradle将ActionBarSherlock(ABS)导入我的Android应用程序,但不幸的是,在构建时,我收到了以下错误列表:
/Users/kramer65/dev/repos/android-official/OurPackage/build/res/all/debug/values/values.xml:248: error: Attribute "titleTextStyle" has already been defined
/Users/kramer65/dev/repos/android-official/OurPackage/build/res/all/debug/values/values.xml:250: error: Attribute "subtitleTextStyle" has already been defined
/Users/kramer65/dev/repos/android-official/OurPackage/build/res/all/debug/values/values.xml:256: error: Attribute "divider" has already been defined
/Users/kramer65/dev/repos/android-official/OurPackage/build/res/all/debug/values/values.xml:258: error: Attribute "background" has already been defined
[etc. etc.]
* What went wrong:
Execution failed for task ':processDebugResources'.
> Could not call IncrementalTask.taskAction() on task ':processDebugResources'
我正在尝试使用build.gradle中的以下内容导入ABS:
dependencies {
compile 'com.actionbarsherlock:actionbarsherlock:4.4.0@aar'
compile 'com.android.support:support-v4:18.0.+'
compile 'com.google.android.gms:play-services:4.0.30'
instrumentTestCompile(files('libs/espresso-1.0-SNAPSHOT-bundled.jar'))
}
并且在我的settings.gradle中,我有以下一行:
include ':OurPackage', ':Libraries:ActionBarSherlock'
有人知道我在做什么错吗?欢迎所有提示!
[在两个不同的库中定义了相同的属性titleTextStyle
,subtitleTextStyle
,divider
,background
。
'com.actionbarsherlock:actionbarsherlock:4.4.0@aar'
和支持库'com.android.support:support-v4:18.0.+'
,它们一起引入了v7 appcompat库无法使用。