0
我在構建一個使用2個插件和google-maps plugin的科爾多瓦應用程序。科爾多瓦庫版本之間的Android衝突
事實是,谷歌地圖插件需要
com.google.android.gms:play-services-maps:7.8.0
com.google.android.gms:play-services-location:7.8.0
而推插件需要com.google.android.gms:play-services:6.1.11
所以當我嘗試構建應用程序,gradle這個抱怨:
Error: more than one library with package name 'com.google.android.gms'
這裏是gradle dependencies
輸出:
compile - Classpath for compiling the main sources.
+--- com.android.support:appcompat-v7:22.+ -> 22.2.1
| \--- com.android.support:support-v4:22.2.1
| \--- com.android.support:support-annotations:22.2.1
+--- org.jboss.aerogear:aerogear-android-core:2.1.0
+--- org.jboss.aerogear:aerogear-android-pipe:2.1.0
| +--- org.jboss.aerogear:aerogear-android-core:2.1.0
| \--- com.google.code.gson:gson:2.2.2
+--- org.jboss.aerogear:aerogear-android-push:2.2.0
| +--- org.jboss.aerogear:aerogear-android-core:2.1.0
| +--- org.jboss.aerogear:aerogear-android-pipe:2.1.0 (*)
| +--- com.google.android.gms:play-services:6.1.11
| \--- com.google.code.gson:gson:2.2.2
+--- com.google.android.gms:play-services-maps:7.8.0
| \--- com.google.android.gms:play-services-base:7.8.0
| \--- com.android.support:support-v4:22.2.0 -> 22.2.1 (*)
\--- com.google.android.gms:play-services-location:7.8.0
+--- com.google.android.gms:play-services-base:7.8.0 (*)
\--- com.google.android.gms:play-services-maps:7.8.0 (*)
從build.gradle
提取:
apply from: "org.jboss.aerogear.cordova.push/hellocordova-dependencies.gradle"
dependencies {
compile fileTree(dir: 'libs', include: '*.jar')
// SUB-PROJECT DEPENDENCIES START
debugCompile project(path: "CordovaLib", configuration: "debug")
releaseCompile project(path: "CordovaLib", configuration: "release")
compile ("com.google.android.gms:play-services-maps:7.8.0")
compile ("com.google.android.gms:play-services-location:7.8.0")
// SUB-PROJECT DEPENDENCIES END
}
我不知道我怎麼能解決這個版本衝突...任何想法?