项目依赖于 com.google.android.support:wearable:2.0.2
Project depends on com.google.android.support:wearable:2.0.2
我用 android studio 创建了一个演示服装项目,但没有接触任何东西。在 build.Gradle 中发生了这个错误,尽管我很好奇它允许应用程序编译。
Project depends on com.google.android.support:wearable:2.0.2, so it
must also depend (as a provided dependency) on
com.google.android.wearable:wearable:2.0.2
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.google.android.support:wearable:1.4.0'
compile 'com.google.android.gms:play-services-wearable:9.4.0'
}
只需添加
provided com.google.android.wearable:wearable:2.0.2
你的依赖关系
编辑:
provided
现在已弃用,请像这样使用 compileOnly
:
compileOnly com.google.android.wearable:wearable:2.0.2
我用 android studio 创建了一个演示服装项目,但没有接触任何东西。在 build.Gradle 中发生了这个错误,尽管我很好奇它允许应用程序编译。
Project depends on com.google.android.support:wearable:2.0.2, so it must also depend (as a provided dependency) on com.google.android.wearable:wearable:2.0.2
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.google.android.support:wearable:1.4.0'
compile 'com.google.android.gms:play-services-wearable:9.4.0'
}
只需添加
provided com.google.android.wearable:wearable:2.0.2
你的依赖关系
编辑:
provided
现在已弃用,请像这样使用 compileOnly
:
compileOnly com.google.android.wearable:wearable:2.0.2