【发布时间】:2014-11-18 11:24:48
【问题描述】:
我正在尝试解决此异常。我在 intellij 有 2 个 android 项目。 图书馆和样本。
图书馆的部门如下:
compile('com.inepex.simpleclient:SimpleClientImpl:0.9.4') {
exclude module: 'guice-assistedinject'
exclude module: 'guice'
exclude module: 'ormlite-core'
}
compile 'org.roboguice:roboguice:3.0.1@jar'
compile 'com.google.inject:guice:3.0:no_aop'
compile 'com.fasterxml.jackson.core:jackson-databind:2.4.0'
compile 'org.slf4j:slf4j-android:1.6.1-RC1@jar'
compile 'com.j256.ormlite:ormlite-android:4.45'
compile 'com.android.support:support-v4:19.1.0'
compile 'com.google.code.gson:gson:2.2.+'
示例应用程序部门:
compile 'com.android.support:appcompat-v7:19.1.0'
compile 'com.android.support:gridlayout-v7:19.1.0'
compile project(':library')
示例的gradle依赖输出:
+--- com.android.support:appcompat-v7:19.1.0
| \--- com.android.support:support-v4:19.1.0
+--- com.android.support:gridlayout-v7:19.1.0
| \--- com.android.support:support-v4:19.1.0
\--- project :library
+--- com.inepex.simpleclient:SimpleClientImpl:0.9.4
| +--- com.j256.ormlite:ormlite-jdbc:4.45
| +--- io.netty:netty:3.5.7.Final
| \--- com.google.guava:guava:17.0
+--- org.roboguice:roboguice:3.0.1
+--- com.google.inject:guice:3.0
| +--- javax.inject:javax.inject:1
| +--- aopalliance:aopalliance:1.0
| \--- org.sonatype.sisu.inject:cglib:2.2.1-v20090111
| \--- asm:asm:3.1
+--- com.fasterxml.jackson.core:jackson-databind:2.4.0
| +--- com.fasterxml.jackson.core:jackson-annotations:2.4.0
| \--- com.fasterxml.jackson.core:jackson-core:2.4.0
+--- org.slf4j:slf4j-android:1.6.1-RC1
+--- com.j256.ormlite:ormlite-android:4.45
| \--- com.j256.ormlite:ormlite-core:4.45
+--- com.android.support:support-v4:19.1.0
\--- com.google.code.gson:gson:2.2.+ -> 2.2.4
问题是我一次找不到 com.google.inject.Module 并且异常告诉它是多次定义的。它在 guice.3.0-no_aop.jar 中。
提前致谢
巴林特
【问题讨论】:
-
尝试删除这个:compile 'com.android.support:support-v4:19.1.0' from sample app deps。
标签: android intellij-idea gradle dex