After upgrading to Android Developer Tools version 22, compiling fails

◇◆丶佛笑我妖孽 提交于 2019-12-29 03:53:26

问题


Today, I upgraded ADT to version 22. After that, my projet wouldn't compile resources at all. My "gen" folder was empty and as such all my java files that require "R" wouldn't compile.


回答1:


After a few non-full time hours, I restarted the "Android SDK Manager" and this time, I noticed these: - "Android SDK Platform Tools" (upgrade) - "Android SDK built-tools" (new)

After installing those, I was finally able to fully compile my project.




回答2:


ADT22 use Android Private Libraries show project/libs'jar, add Exported feature, if you wannt reference library projects' private libraries, you must check the Exported

https://plus.google.com/photos/117122118961369445953/albums/5878509263473846433/5878509268379848162?authkey=CL3Frb-S_qj-fQ




回答3:


If you are using some libraries or/and dependencies with other projects, you may also experience errors at execution time. In my case I had problems with Sherlock "Unable to execute dex: Multiple dex files define Lcom/actionbarsherlock/R$attr" and with some other jar file I am using "VFY: unable to find class referenced in signature" In that case, you must go to project properties, Java Build Path section, and remove Android Dependencies and Android Private Libraries, both in the main project and also in the dependent projects like for example Sherlock. After that you perform Clean on all projects. Everything should be restored. That worked for me, after a hard battle!



来源:https://stackoverflow.com/questions/16578147/after-upgrading-to-android-developer-tools-version-22-compiling-fails

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