码迷,mamicode.com
首页 > 移动开发 > 详细

android工程下不能运行java main程序的解决办法

时间:2016-03-01 12:44:43      阅读:150      评论:0      收藏:0      [点我收藏+]

标签:

我在 android环境下写了一个测试Java类,带有main方法,可是无法运行,如下提示:

Invalid layout of java.lang.String at value
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (javaClasses.cpp:136), pid=88924, tid=89728
#  fatal error: Invalid layout of preloaded class
#
# JRE version:  (7.0_72-b14) (build )
# Java VM: Java HotSpot(TM) 64-Bit Server VM (24.72-b04 mixed mode windows-amd64 compressed oops)
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
#
# An error report file with more information is saved as:
# D:\Android\AndroidAdt\workspace\Test01\hs_err_pid88924.log
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.sun.com/bugreport/crash.jsp

 


解决方法:run as --->  Run Configurations  -->  classPath remove掉Bootstrap Entries下的android.jar 

              然后 Add Library -->JRE System Libray  完成后  在运行就OK了!

 

android工程下不能运行java main程序的解决办法

标签:

原文地址:http://www.cnblogs.com/veer-273/p/5230222.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!