Thursday, April 19, 2012

Runnable JAR not working with referenced libraries

I want to create a runnable JAR that include referenced libraries, namely jackson, in eclipse via the export. There used to be fat jar that seemed to be the goto solution before Eclipse offered to export to runnable JAR.



From this question, the first option would be what I'm looking for. Since it is for the moment a small project, it wouldn't be a problem to always have everything together (plus it's easier for me since I'm just starting with JARs, runnables and jnlp)



When I try to launch it, there's an alert window saying there was a problem and to try to find it in the console (which I can't get to open).



If I remove any use of this referenced library everything runs perfectly (except the part that it's not doing what I what at all). The window looks the way I designed it, but no functionality without the library.



I don't even have a stack trace to help with the problem. I've created other projects without any referenced libraries and everything is fine. So I've pretty much narrowed it down.



Since I let Eclipse handle the exporting and everything, I don't suppose you need the manifest to see if it is alright. Any questions you might have, I'll provide the informations you need. It goes without saying that the project runs directly from Eclipse.



Eclipse
Version: Indigo Service Release 2
Build id: 20120216-1857





No comments:

Post a Comment