java.lang.IllegalAccessError: Method 'void android.support.v4.content

前端 未结 4 555
心在旅途
心在旅途 2020-12-03 05:11

I updated playservice in my sdk and I got this error. And I am not able to access GCM Token. Before update sdk my project work perfectly.

I waste my whole day in i

4条回答
  •  情话喂你
    2020-12-03 05:53

    I had the same problem after some digging I found out that facebook sdk was depending on the new version of google support libraries than I have compiled on.

    You can check the dependencies with gradle command

    ./gradlew app:dependencies
    

    Ensure that all the dependency libraries has same version. If not then you can exclude that dependency using

    compile ('com.facebook.android:facebook-android-sdk:[4,5)'){
        exclude module: 'support-v4'
        exclude group: 'com.android.support'
    }
    

    then later add the required the dependency you have compiled your project on, In my case

    compile 'com.android.support:support-v4:23.1.0'

提交回复
热议问题