Post

2 followers Follow
0
Avatar

include external library

Hi all,

I am trying to develop a plugin that uses an external library, but when running the plugin, the library wont load (see stack trace below).
Where do I have to put the library jar file on the file system and/or where do I have to include the library in the build process of the plugin so Geneious can find it.

So far, I included it in the build.xml classpath and I moved the library jar to ../GeneiousFiles/lib and to .../Geneious/lib, but this did not help.

Thanks for your help!

stack trace:
java.lang.NoClassDefFoundError
at com.biomax.biomaxImporterPlugin.BiomaxImporter.initBioXMSession(BiomaxImporter.java:47)
at com.biomax.biomaxImporterPlugin.BiomaxImporter.performOperation(BiomaxImporter.java:178)
at com.biomatters.geneious.publicapi.plugin.DocumentOperation.performOperation(DocumentOperation.java:459)
at com.biomatters.geneious.publicapi.plugin.DocumentOperation.performOperation(DocumentOperation.java:405)
at com.biomatters.iseek.plugin.operations.p.run(OperationManager.java:453)
at com.biomatters.geneious.common.operations.b.a(OperationsUtilities.java:149)
at com.biomatters.geneious.common.operations.b.a(OperationsUtilities.java:146)
at com.biomatters.geneious.common.operations.a$c.b(OperationsUtilities.java:125)
at com.biomatters.geneious.common.operations.a$b.a(OperationsUtilities.java:146)
at com.biomatters.iseek.plugin.operations.e.a(OperationManager.java:447)
at com.biomatters.iseek.plugin.operations.u.a(OperationPerformer.java:98)
at com.biomatters.iseek.plugin.operations.OperationAction.performAction(OperationAction.java:122)
at com.biomatters.iseek.plugin.operations.OperationAction.access$000(OperationAction.java:29)
at com.biomatters.iseek.plugin.operations.a.run(OperationAction.java:85)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.ClassNotFoundException: com.biomax.bioxm.remotecli.BioXMCli
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 15 more

Elisabeth Frank

Please sign in to leave a comment.

4 comments

0
Avatar

I want to run the plugin from inside Geneious. So no IDE involved.

I need to know where to put the jar libraries so that they can be found during runtime, not compilation.

Elisabeth Frank 0 votes
Comment actions Permalink
0
Avatar

Sorry for the misunderstanding.

You need to build your plugin as a folder which contains your main jar alongside any other required jars. If you have a look at the build.xml files that are included with the sample plugins (we always recommend building new plugins on top of one of the examples), there is commented out code in there along with instructions for building your plugin as a folder. Your jars go where the build.xml mentions "ExtraFiles". If anything is unclear, let me know.

For existing examples of this, have a look inside the bundledPlugins folder in your Geneious install directory. We have a few folder type plugins that contain additional jars.

Richard Moir 0 votes
Comment actions Permalink
0
Avatar

Fantastic, that worked perfect! Thanks for your help on this!

Elisabeth Frank 0 votes
Comment actions Permalink