Fix GCM provider registration event. Fix gradle build.