Google示例通用音乐播放器构建错误

时间:2015-06-01 20:08:06

标签: java android android-studio wear-os

我下载并导入示例后,我得到了这样的构建错误 https://github.com/googlesamples/android-UniversalMusicPlayer

Error:A problem occurred configuring project ':mobile'.
Could not resolve all dependencies for configuration ':mobile:_debugCompile'.
Could not find com.google.android.support:wearable:1.2.0.
     Searched in the following locations:

https ://jcenter.bintray.com/com/google/android/support/wearable/1.2.0/wearable-1.2.0.pom  
https ://jcenter.bintray.com/com/google/android/support/wearable/1.2.0/wearable-1.2.0.jar
         file:/Users/Jieyi/Downloads/android-UniversalMusicPlayer-master/mobile/libs/wearable-1.2.0.jar
         file:/Users/Jieyi/Downloads/android-UniversalMusicPlayer-master/mobile/libs/wearable.jar
         file:/Users/Jieyi/Library/Android/sdk/extras/android/m2repository/com/google/android/support/wearable/1.2.0/wearable-1.2.0.pom
         file:/Users/Jieyi/Library/Android/sdk/extras/android/m2repository/com/google/android/support/wearable/1.2.0/wearable-1.2.0.jar
         file:/Users/Jieyi/Library/Android/sdk/extras/google/m2repository/com/google/android/support/wearable/1.2.0/wearable-1.2.0.pom
         file:/Users/Jieyi/Library/Android/sdk/extras/google/m2repository/com/google/android/support/wearable/1.2.0/wearable-1.2.0.jar
     Required by:
         android-UniversalMusicPlayer-master:mobile:unspecified

1 个答案:

答案 0 :(得分:0)

确保您已通过SDK Manager安装了Google Repository,并确保它是最新的。在那里找到com.google.android.support:wearable的1.2.0版本。我猜,鉴于你的错误,你已经安装了它,但它不是最新的。