7

I've created a demo wear project with android studio without touching anything. In build.Gradle this error occurs, although I find curious that it lets the app compile.

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

enter image description here

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'
}
user2983041
  • 1,761
  • 4
  • 19
  • 31

1 Answers1

12

Just add

provided com.google.android.wearable:wearable:2.0.2

to your dependencies

EDIT:

provided is deprecated now, use compileOnly like so:

compileOnly com.google.android.wearable:wearable:2.0.2

Jozef Dochan
  • 926
  • 10
  • 27