Why can't I add mopub-android-sdk as library?

谁说我不能喝 提交于 2019-12-24 16:17:42

问题


I want to use MoPub for putting ads in my Android app. I have downloaded the required resources and set-up a library project (mopub-android-sdk) in Eclipse. Now I want to add this project as a library to my Android app. But when I try to do that it gives this error:


回答1:


Are the mopub-android-sdk files in the same parent folder as your project? This seems like the same problem addressed in this question/answer:

In eclipse, unable to reference an android library project in another android project

Place the referencing project in the same physical folder and see if the error persists.




回答2:


To get around this, don't set up the mopub-sdk as a library project.

You can simply import it as a standard project.

Go to File > Import >Existing Projects Into Workspace, find the right project and click finish.

Right click your actual project and then click Build Path. Go to Link Source and then select the location of the project you just imported.

That should resolve the issue for you without requiring you to build a JAR.

-Franklin



来源:https://stackoverflow.com/questions/9762265/why-cant-i-add-mopub-android-sdk-as-library

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!