开发者

Android project becomes terribly slow after adding HtmlUnit JARs to eclipse buildpath

I am trying to develop an android application which includes login functionality. To achieve this I used the HtmlUnit package and added the relevant JARs to the eclipse buildpath. After that my eclipse becomes quite slow and unresponsive. When I try to build the project and run it, it got stuck during the building pr开发者_运维百科ocess and reports the following:

Problem occurred: Unable to execute dex: Java heap space

And then: An out of memory error has occurred.

So I guess it might got stuck in some infinite loops when building. Has anyone met similar problems like mine? Or is it a common problem that Android projects can get very troublesome after importing some java libraries that are not known to be fully compatible with Android? Thanks!


This is due to an out of memory error encountered by Eclipse because of the large amount of .jars. This can easily be fixed by increasing the heap space allocated to Eclipse as seen here. For windows, just go to the program -> properties, and in the "target" box, add an extra param like -Xmx1024m.

Cheers.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜