eclipse   Unable to execute dex: GC overhead limit exceeded GC overhead limit exceeded解決辦法

有個老APP在eclipse上,以前打包都很順利,今天好幾次就是打不出來包,總是報錯,而且eclipse還經常未響應,非常噁心這軟件。

後來仔細看了下英文報錯內容,大概意思是:無法執行dex,GC空間不足,超額

網上查了些資料找到了解決辦法,需要對eclipse做相關配置,增加空間,如下:


1、關閉Eclipse 打開D:\eclipse\eclipse.ini

-startup

plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar

--launcher.library

plugins/org.eclipse.equinox.launcher.win32.win32.x86_64_1.1.200.v20120913-144807

-product

org.eclipse.epp.package.jee.product

--launcher.defaultAction

openFile

--launcher.XXMaxPermSize

512M

-showsplash

org.eclipse.platform

--launcher.XXMaxPermSize

512m

--launcher.defaultAction

openFile

-vmargs

-Dosgi.requiredJavaVersion=1.5

-Dhelp.lucene.tokenizer=standard

-Xms40m

-Xmx512m

2、之後進行修改:修改如下

-vm

C:\Program Files\Java\jdk1.7.0_21\bin\javaw.exe

-startup

plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar

--launcher.library

plugins/org.eclipse.equinox.launcher.win32.win32.x86_64_1.1.200.v20120913-144807

-product

org.eclipse.epp.package.jee.product

--launcher.defaultAction

openFile

--launcher.XXMaxPermSize

512M

-showsplash

org.eclipse.platform

--launcher.XXMaxPermSize

512m

--launcher.defaultAction

openFile

-vmargs

-Dosgi.requiredJavaVersion=1.5

-Dhelp.lucene.tokenizer=standard

-Xms256m

-Xmx1024m

3、保存,打開Eclipse 


發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章