Failed to find the runtime libraries, required by MATLAB Builder JA, on system path
I could not solve it this time!!
---------------------------------------
01:28, 11.7, 2009
On last Thursday Danis let me compile a Matlab2009a version of Sparc, so I deleted Matlab2008a from my laptop, installing 09a, compiling the matlab2sparc in it. Then I could not work with sparc in netbeans anymore. The same error as that in weblcc:
Failed to find the runtime libraries, required by MATLAB Builder JA, on system path
Thousands of methods had been tried but none helps.
Yesterday I restored my computer and installed Matlab2008a again, and created a new project the same as matlab2sparc, and compiled it in 08a. Everything worked again!!
Yesterday Tom also helped me to restore the virtual server and installed 2008b on it which is the one I had used initially in the virtual server. Now everything works again!
Maybe the real problem is caused by Matlab version issues?
Anyway, I could make Raids happy again.
Yesterday I installed Windows 7 on my machine, and then the Matlab, JDK. The same JVM problem happens again!! Seems that it's not the problem of Java version, but the compatibility of Java version and Matlab.
ReplyDeleteActually the error occurred on Windows 7 is not the same as what has happened on the server. This is the error message on my machine:
ReplyDelete#
# A fatal error has been detected by the Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x6da435a4, pid=2836, tid=900
#
# JRE version: 6.0_17-b04
# Java VM: Java HotSpot(TM) Client VM (14.3-b01 mixed mode windows-x86 )
# Problematic frame:
# C [jvm.dll+0x1935a4]
#
# An error report file with more information is saved as:
# D:\Job\fpat\project\sparc\hs_err_pid2836.log
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
#
Opening log file: C:\Users\chenyang\AppData\Local\Temp\java.log.2836
Java Result: 1
and the log file:
Stack Trace:
[0] jmi.dll:void __stdcall mwJavaAbort(void)(0x088168d8, 1, 0x0884ffe8, 0x063f3748) + 21 bytes
[1] jvm.dll:0x0879fed5(0xc0000005, 0x0881f6b9, 0x06379400, 0x6da435a4)
[2] jvm.dll:0x087a0d21(0x06379400, 0xc0000005, 0, 0)
[3] jvm.dll:0x087a30a6(144, 0x7c34246e, 0x0849e934, 0)
[4] jvm.dll:0x087a41df(0x0871ce40, 0x0849f158, 0x0849f098, 0x0849f09c)
[5] jvm.dll:0x0871d34a(0x0849f158, 0x03b84068, 0x08893758, 0x08893aa0)
[6] jvm.dll:0x0871d4c3(0x0849f158, 0x03b84070, 0x03b84068, 0x08893758)
[7] jvm.dll:0x087fd323(0x03b8404c, 0x06379400, 0x7ac95a50, 0)
[8] jvm.dll:0x088009a2(0x06379400, 0x0849f243, 0, 0x0149fbb0)
[9] jvm.dll:0x0872edc0(0x790e4e94, 0x0849fc18, 0x0849fbb0, 0x7ac91100)
[10] jmi.dll:struct JNIEnv_ * __cdecl InitSunVM(void)(0x7ac91100, 0x7ac987b0, 0x7ac91660, 0x06e4d874) + 1945 bytes
[11] jmi.dll:bool __cdecl InitJava(void)(0x7ac91660, 0x7971f5a8, 0, 0) + 232 bytes
[12] jmi.dll:bool __cdecl mljInit(void)(0x06df3d98, 0x06e02520, 1, 0x06e02a98 "E:\program_files\matlab\toolbox\..") + 6 bytes
[13] mcr.dll:unsigned long __cdecl run_init_and_handle_events(void *)(0x0681d5d4, 0x0849ffd4, 0x7707b3f5, 0x0681d5d4) + 87 bytes
[14] kernel32.dll:0x769b1174(0x0681d5d4, 0x7f5ef26c, 0, 0)
[15] ntdll.dll:0x7707b3f5(0x7972b0e0, 0x0681d5d4, 0, 0)
[16] ntdll.dll:0x7707b3c8(0x7972b0e0, 0x0681d5d4, 0, 0x00905a4d)
------------------------------------------------------------------------
Fatal Java Exception detected at Mon Dec 21 23:36:02 2009
------------------------------------------------------------------------
Configuration:
MATLAB Version: 7.6.0.324 (R2008a)
MATLAB License: unknown
Operating System: Microsoft Windows Vista
Window System: Version 6.1 (Build 7600)
Processor ID: x86 Family 6 Model 15 Stepping 13, GenuineIntel
Virtual Machine: Java is not enabled
Default Encoding: GBK
Java is not enabled.
I followed the solution from http://www.mathworks.com/access/helpdesk/help/techdoc/matlab_external/f98533.html#f122001
and set the environment variable "MATLAB_JAVA" to "e:\JAVA\jre6\" in order to appoint the jre home that is required by the Matlab to the JRE that I installed. BUT...it doesn't work on Netbeans anyway! However it works with the .jar file that compiled in Netbeans very well which used not to be the case before.
If you are making some standalone software, try to use the convert tool "exe4j" to convert your jar file to exe and run it.
ReplyDeletesucceed in Matlab 2009b. Environment variables:
ReplyDeleteCLASSPATH:
.;E:\JAVA\jre6\lib\ext\QTJava.zip
JRE_HOME:
E:\JAVA\jre6\
MATLAB_JAVA
E:\JAVA\jre6
PATH
E:\program_files\miktex\miktex\bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;E:\JAVA\jdk\bin;E:\program_files\3.2.2_gcc-4.3.0\bin;C:\Program Files\QuickTime\QTSystem\;F:\shortcuts;C:\Program Files\Common Files\Thunder Network\KanKan\Codecs;E:\program_files\matlab\bin;E:\program_files\matlab\runtime\win32