[英]import google-play-service: Resource '/HomeActivity' already exists
Ok... this is my problem. 好吧...这是我的问题。 When I try to import google-play-service, Eclipse show me this error:
当我尝试导入google-play-service时,Eclipse向我显示此错误:
Resource '/HomeActivity' already exists. 资源“ / HomeActivity”已存在。
Reason: 原因:
Resource '/HomeActivity' already exists. 资源“ / HomeActivity”已存在。
Then, all the projects that are imported, have red globes with X (some error). 然后,所有导入的项目都有带有X的红色地球仪(有些错误)。 And the library is not usefull.
而且该库没有用。
can someone help me? 有人能帮我吗?
Package_A= "Is Library" is checked. Package_A =“正在存储库”已检查。
Package_B= "Is Library" is checked. Package_B =“正在存储库”已检查。 References Package_A.
参考Package_A。
Package_C= "Is Library" is checked. Package_C =“正在存储库”已检查。 References Package_B.
参考Package_B。
Package_D= "Is Library" is NOT checked. Package_D =“不是库”未选中。 References Package_C.
参考Package_C。
If you have HomeActivity inside both Package_B and Package_C = ERROR 如果Package_B和Package_C都包含HomeActivity =错误
If the way you reference the package is not what I described above= ERROR 如果您引用软件包的方式不是我上面描述的=错误
This error is caused because Eclipse tries to import samples of Google Play Services that have the same Activities/Project names. 造成此错误的原因是,Eclipse尝试导入具有相同“活动/项目”名称的Google Play服务示例。
To avoid these errors, just import the google-play-services_lib instead of the google_play_services folder. 为避免这些错误,只需导入google-play-services_lib而不是google_play_services文件夹。
Example: adt-bundle-linux-x86_64-20131030/sdk/extras/google/google_play_services/libproject/google-play-services_lib 示例:adt-bundle-linux-x86_64-20131030 / sdk / extras / google / google_play_services / libproject / google-play-services_lib
The reason why this is happening is because HomeActivity is present both in your project as well as in Google Play library. 发生这种情况的原因是,您的项目以及Google Play库中都存在HomeActivity。 Rename your HomeActivity to another name which is not the in play library project
将您的HomeActivity重命名为不在游戏库项目中的其他名称
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.