title: Error: Multiple dex files define Landroid/support/annotations/AnimRes with Admob and Facebook Cordova plugins
body: <p>I'm building an app using cordova and the Ionic framework. </p>
  
  <ul>
  <li>I'm using the Wizcorp facebook plugin:<br>
  <a href="https://github.com/Wizcorp/phonegap-facebook-plugin" rel="nofollow noreferrer">https://github.com/Wizcorp/phonegap-facebook-plugin</a> .  </li>
  <li>and I recently added the google admob plugin:<br>
  <a href="https://github.com/floatinghotpot/cordova-admob-pro" rel="nofollow noreferrer">https://github.com/floatinghotpot/cordova-admob-pro</a></li>
  </ul>
  
  <p>However now when I build my project I'm met with the error:</p>
  
  <pre><code>UNEXPECTED TOP-LEVEL EXCEPTION:
  com.android.dex.DexException: Multiple dex files define Landroid/support/annotations/AnimRes;
  </code></pre>
  
  <p>Other SO solutions mention multiple <code>android-support-v4.jar</code> files conflicting, however the only <code>android-support-v4.jar</code> file I can find is within the facebook plugin.</p>
  
  <p>Another solution mentioned conflicting versions (i.e <code>android-support-v4.jar</code> conflicting with <code>android-support-v13.jar</code>) - again, I cannot see any references to <code>android-support-v13.jar</code> within my project.</p>
  
  <p>Another solution was conflicting <code>android-support-annotations.jar</code> and <code>android-support-v4.jar</code>: <a href="https://stackoverflow.com/questions/26342444/multiple-dex-files-define-landroid-support-annotation-animres">multiple dex files define landroid/support/annotation/AnimRes</a> . I cannot find any <code>android-support-annotations.jar</code> files within my project, except something that is created in: <code>myProject\platforms\android\build\intermediates\pre-dexed\debug</code>
  <a href="https://i.stack.imgur.com/qiSkr.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/qiSkr.png" alt="enter image description here"></a></p>
  
  <p>However I don't understand how this is getting created.</p>
  
  <p>How can I solve this problem? The problem can be easily reproduced:</p>
  
  <pre><code>&gt;ionic start myApp tabs
  &gt;cd myApp
  &gt;cordova plugin add https://github.com/Wizcorp/phonegap-facebook-plugin.git --variable APP_ID="123456789" --variable APP_NAME="myApplication"
  &gt;cordova plugin add cordova-plugin-admobpro
  &gt;ionic platform android
  &gt;ionic build android 
  </code></pre>
  
  <p>(where APP_ID and APP_NAME are the ID and name of a facebook application)</p>