after I added the fb library in the gradle dependences:
dependencies {
compile 'com.mixpanel.android:mixpanel-android:4.5.2'
compile 'com.android.support:multidex:1.0.0'
compile 'com.facebook.android:facebook-android-sdk:3.22.0'
}
I started getting an error on gradle build:
dexDebug
UNEXPECTED TOP-LEVEL EXCEPTION:
com.android.dex.DexException: Multiple dex files define Landroid/support/annotation/AnimRes;
thanks
com.facebook.android:facebook-android-sdk:3.22.0This usually occurs because of a library getting referred to twice in the dependencies.
You can run the following command to see all the dependent libraries:
You may need to do something like this to prevent the support library from being included twice:
*** Updated to reflect comment
See this related question: Building OutsystemsNow for android on Android Studio getting dexException