[Android] AdMob plugin does not work with GooglePlay IAP

When AdMob plugin is used together with SDKBOX-IAP then this compilation error occurs:

com.android.dex.DexException: Multiple dex files define Lcom/google/ads/AdRequest$ErrorCode;

This topic talks about the fix: http://stackoverflow.com/questions/20198956/using-admob-in-android-app-multiple-dex-files-define

But when I change the package import to com.google.android.gms.ads. in cocos/3.5/frameworks/js-bindings/cocos2d-x/plugin/plugins/admob/proj.android/src/org/cocos2dx/plugin/AdsAdmob.java then I receive many compilation errors that the new package name is not found.

The googlePlay dependency is already in my project.properties

android.library.reference.5=../../../../../../../Applications/adt-bundle-mac-x86_64-20130729/sdk/extras/google/google_play_services/libproject/google-play-services_lib/

I’ve tried:

  1. add the same dependency to cocos/3.5/frameworks/js-bindings/cocos2d-x/plugin/plugins/admob/proj.android/project.properties
  2. copied the google-play-services.jar directly to my project’s libs folder
  3. copied the google-play-services.jar directly to admob plugin’s libs folder

None works…