Reputation: 1102
Newbie to android and android studio.. Trying to use Google Play Services for implementing GCM. Was following how to set up play-services
and Demo GCM Client
But got
01-01 21:01:25.094 11590-11590/com.abc.ads E/AndroidRuntime﹕ FATAL EXCEPTION: main
java.lang.NoClassDefFoundError: com/google/android/gms/common/GooglePlayServicesUtil
at com.abc.ads.DummyActivity.checkPlayServices(DummyActivity.java:101).
There are answers for this same issue in SO itself. But all of them are "ecclipse" related. How solve this in Android Studio?
Upvotes: 0
Views: 115
Reputation: 80020
Upgrade to Android Studio 0.4.0 or later, or clean and rebuild your project if you want to stay on 0.3.2. There's a bug in the 0.6 versions of the Gradle plugin (https://code.google.com/p/android/issues/detail?id=63366) that can cause newly-added dependencies to not get linked into your APK unless you clean your project after doing so.
Upvotes: 1