Android Wear new (unwanted) permissions

巧了我就是萌 提交于 2019-12-06 20:57:26
String

The extra permissions are probably being added by some part of Google Play Services - and which probably doesn't need them for what you're doing.

Solution #1 is to only use the pieces of Google Play Services that you actually need. In your Wear module's build.gradle file, you might have an entry that looks like this:

dependencies {
    compile com.google.android.gms:play-service:8.4.0
}

However, that will bring in the entire Play Services library - which requires a number of extra permissions. It might well be that all you need is this:

    compile com.google.android.gms:play-services-wearable:8.4.0

...or perhaps other specific modules. But the point is, don't include more than you need.

If you've pared the dependencies back as far as you can, and you're still getting extra permissions in your merged manifest, then you may need Solution #2 - which I described in detail in a different answer: https://stackoverflow.com/a/31017339/252080

Make sure you read all the way to the bottom, because there are some important caveats.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!