In fact, there is another reason for this question: When we use gradle build with:
compile 'com.google.android.gms:play-services:xxxx'
We had to collect the entire API package into our application. In some cases, this made it difficult to maintain the number of methods in our application (including front-end APIs, library methods, and native code) under the 65,536 limit. So, the solution: we should build only with the packages we use: Example:
compile 'com.google.android.gms:play-services-analytics:xxx' compile 'com.google.android.gms:play-services-gcm:xxx'
More details: https://developers.google.com/android/guides/setup
source share