迁移到 Play Services v7.5+ 的新 GCM 协议时无法解析 AndroidManifest.xml 中的 'gcm'
Cannot resolve 'gcm' in AndroidManifest.xml when migrating to new GCM protocol for Play Services v7.5+
当遵循 instructions to migrate an existing app 'that extend a WakefulBroadcastReceiver' 时,我收到 com.google.android.gms.gcm.GcmReceiver
的错误 cannot resolve gcm
。
Google 省略了说明,以确保如果您正在编译单个 play-services
包(按照建议),您需要将
compile 'com.google.android.gms:play-services-gcm:7.x.x'
添加到 build.gradle
当遵循 instructions to migrate an existing app 'that extend a WakefulBroadcastReceiver' 时,我收到 com.google.android.gms.gcm.GcmReceiver
的错误 cannot resolve gcm
。
Google 省略了说明,以确保如果您正在编译单个 play-services
包(按照建议),您需要将
compile 'com.google.android.gms:play-services-gcm:7.x.x'
添加到 build.gradle