No Java Builder package working

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).

 Respuesta aceptada

Titus Edelhofer
Titus Edelhofer el 20 de Feb. de 2015

1 voto

Hi,
just a guess: you used Java JDK 1.8.x? You need to use JDK 1.7.x ...
Titus

4 comentarios

MKNote
MKNote el 24 de Jun. de 2015
Why doesn't it work with JDK 1.8?
Titus Edelhofer
Titus Edelhofer el 25 de Jun. de 2015
Each version of MATLAB (and MATLAB Builder JA or now Compiler SDK) comes with a specific major version of Java. The Java SDK needs to have the same major version number (i.e., for older versions of MATLAB it was Java 1.6, for newer versions Java 1.7).
MKNote
MKNote el 1 de Jul. de 2015
So MATLAB doesn't work with Java 1.8?
hocine boudene
hocine boudene el 1 de Mzo. de 2017
a have The same JDK version in matlab but does not working ???? matlab R2015a ------- JDK 1.7.60

Iniciar sesión para comentar.

Más respuestas (1)

Dhara Shah
Dhara Shah el 20 de Feb. de 2015

0 votos

Hi,
Thanks a lot. Yes the problem was I had jdk 1.8. Now I get the results with jdk 1.7.

Categorías

Preguntada:

el 20 de Feb. de 2015

Comentada:

el 1 de Mzo. de 2017

Community Treasure Hunt

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

Start Hunting!

Translated by