Can't resolve dependencies for Java library.

2 visualizaciones (últimos 30 días)
Claas Kähler
Claas Kähler el 1 de Oct. de 2015
Editada: Rohit Kudva el 21 de Oct. de 2015
I'm trying to build a *.jar File from some Matlab code. This code has dependencies that i added at "Files required for your library to run". But if i run the jar i get: "Can't find "MyCode.p"", but the file was added like other Libs that are working. What did i miss?
By the way: There are some yellow triangles at "Files required for your library to run", i couldn't find a meaning for it.

Respuestas (1)

Rohit Kudva
Rohit Kudva el 21 de Oct. de 2015
Editada: Rohit Kudva el 21 de Oct. de 2015
Hi Claas,
I understand that you have compiled your MATLAB function to a JAR file which you using in a Java driver application. But the dependency p-code file that you added during compilation in not being detected by your driver application
One way to check if the p-code file was successfully extracted is to check the MCR cache directory. For Windows OS, by default this directory will be [C:\Users\{username}\AppData\Local\Temp\{username}\mcrCache{mcrversion}]. If you have set the MCR_CACHE_ROOT environment variable, then the files would have been extracted in the directory pointed by that environment variable.
One possible reason for this issue is that starting MATLAB R2014a, you can't compile pure p-code file. If you compile p-code file, you also need to have the corresponding .m file in the same folder.
Regards,
Rohit

Categorías

Más información sobre File Operations en Help Center y File Exchange.

Productos

Community Treasure Hunt

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

Start Hunting!

Translated by