I recently downloaded the newest GoogleAdMobAdsSDK-4.0.2.jar to use in my Android project. My project also uses the gson-1.5.jar library. After importing the GoogleAdMobAdsSDK-4.0.2.jar and build, the Console reports this error:
[2011-03-25 11:28:37 - <appname>] Error generating final archive:
Found duplicate file for APK: assembly-descriptor.xml
Origin 1: C:\Users\<myusername>\Documents
\admob4\GoogleAdMobAdsSDK-4.0.2.jar
Origin 2: C:\Users\<myusername>\Documents\gson\gs开发者_高级运维on-1.5.jar
When i remove the gson-1.5.jar from the project, this error goes away. I would like to use GSON in my project.
What is the problem here? How can i use both GSON and GoogleAdMobAdsSDK-4.0.2.jar?
edit: just updated GSON to 1.6, same problem
I am having the same problem as you.
I couldn't fix it so I go back to an older version. You can get the jar that I am using from my github repo.
This is totally an admob issue and I hope they fix it soon. Someone should answer your question.
Admob includes GSON internally so you should probably use theirs. Other than that you can play around with the classpath and hope it doesn't break admob.
Although in the latest 4.1.0 it seems they removed it.
精彩评论