For anyone encountering this issue using Android Studio / Gradle, you just need to make sure that you have the right dependency in your grade file.
You need to setup Google Play Services – https://developers.google.com/android/guides/setup
(1. Debes configurar Google Play Services)
If you already completed previous step then (si ya completaste ese paso entonces)…
Let say that you have this Gradle: (suponiendo que ya tienes un archivo Gradle asi:)
dependencies {
compile fileTree(dir: ‘libs’, include: [‘*.jar’])
compile ‘com.google.android.gms:play-services-gcm:7.5.0’
}
you need to add a single line for Gradle to include the Google Play Services library
(solo necesitas agregar un solo renglon para que Gradle incluya la libreria de Google Play Services library)
dependencies {
compile fileTree(dir: ‘libs’, include: [‘*.jar’])
compile ‘com.android.support:appcompat-v7:21.0.3’
compile ‘com.google.android.gms:play-services-gcm:7.5.0’ }
Is a bad practice to hardcode this value into the versions.xml file (se considera una mala practica “quemar” o dejar fijo este valor en el archivo mencionado)