No Java Builder package working

조회 수: 2 (최근 30일)
Dhara Shah
Dhara Shah 2015년 2월 20일
댓글: hocine boudene 2017년 3월 1일
Hi I am following the tutorial to build java class from Matlab code. Tutorial on this link Tutorial
All the time package fails and following is the error message.
I have tried multiple functions none of them builds into Java package. I have installed Matlab R2014b trial version. I am evaluating whether to buy the Matlab Java builder or not and so far it doesn't look good.
Please let me know if I am doing something wrong-
ant: ant dir="C:\Users\Dhara\Documents\MATLAB\makeSqr\for_redistribution" / dir="C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing" / dir="C:\Users\Dhara\Documents\MATLAB\makeSqr\for_redistribution_files_only" / /ant mcc -W 'java:makeSqr,MLTest' -T link:lib -d C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing class{MLTest:G:\ForensityLaptop\M2\M2\makeSqr.m} [Warning: Adding path "G:\ForensityLaptop\M2\M2" to Compiler path instance.] Loading source files for package makeSqr... Constructing Javadoc information... Creating destination directory: "C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\" Standard Doclet version 1.8.0_25 Building tree for all the packages and classes... Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\makeSqr\MakeSqrMCRFactory.html... Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\makeSqr\MLTest.html... C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\makeSqr\MLTest.java:109: warning: no @param for args public static void main (String[] args) ^ C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\makeSqr\MLTest.java:59: warning: no @throws for com.mathworks.toolbox.javabuilder.MWException public MLTest() throws MWException ^ C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\makeSqr\MLTest.java:88: warning: no @throws for com.mathworks.toolbox.javabuilder.MWException public MLTest(MWComponentOptions componentOptions) throws MWException ^ C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\makeSqr\MLTest.java:77: warning: no @throws for com.mathworks.toolbox.javabuilder.MWException public MLTest(String pathToComponent) throws MWException ^ Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\makeSqr\MLTestRemote.html... C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\makeSqr\MLTestRemote.java:58: error: reference not found * @throws java.jmi.RemoteException An error has occurred during the function call or ^ C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\makeSqr\MLTestRemote.java:61: warning: no @throws for java.rmi.RemoteException public Object[] makeSqr(int nargout, Object... rhs) throws RemoteException; ^ C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\makeSqr\MLTestRemote.java:64: warning: no @throws for java.rmi.RemoteException void dispose() throws RemoteException; ^ Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\makeSqr\package-frame.html... Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\makeSqr\package-summary.html... C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\makeSqr\package-info.java:8: warning: empty p tag * p ^ C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\makeSqr\package-info.java:15: error: unexpected end tag: /p * /p ^ C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\makeSqr\package-info.java:21: warning: empty p tag * p ^ C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\makeSqr\package-info.java:27: error: unexpected end tag: /p * /p ^ Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\makeSqr\package-tree.html... Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\constant-values.html... Building index for all the packages and classes... Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\overview-tree.html... Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\index-all.html... Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\deprecated-list.html... Building index for all classes... Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\allclasses-frame.html... Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\allclasses-noframe.html... Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\index.html... Generating C:\Users\Dhara\Documents\MATLAB\makeSqr\for_testing\doc\html\help-doc.html... 3 errors 8 warnings Error: An error occurred while shelling out to javadoc (error code = 1). Unable to build executable (specify the -v option for more information).

채택된 답변

Titus Edelhofer
Titus Edelhofer 2015년 2월 20일
Hi,
just a guess: you used Java JDK 1.8.x? You need to use JDK 1.7.x ...
Titus
  댓글 수: 4
MKNote
MKNote 2015년 7월 1일
So MATLAB doesn't work with Java 1.8?
hocine boudene
hocine boudene 2017년 3월 1일
a have The same JDK version in matlab but does not working ???? matlab R2015a ------- JDK 1.7.60

댓글을 달려면 로그인하십시오.

추가 답변 (1개)

Dhara Shah
Dhara Shah 2015년 2월 20일
Hi,
Thanks a lot. Yes the problem was I had jdk 1.8. Now I get the results with jdk 1.7.

카테고리

Help CenterFile Exchange에서 Java Package Integration에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by