If I run project from eclipse - it's ok. If I run project as runnable jar exception thrown:
.Exception in thread "main" java.lang.ExceptionInInitializerError
at de.intarsys.pdf.platform.cwt.font.freetype.FreetypeFontFactory.getLib
rary(Unknown Source)
at de.intarsys.pdf.platform.cwt.font.freetype.FreetypeFontFactory.create
PlatformFont(Unknown Source)
at de.intarsys.pdf.platform.cwt.rendering.CSPlatformDevice.textSetFont(U
nknown Source)
at de.intarsys.pdf.content.CSDeviceBasedInterpreter.render_Tf(Unknown So
urce)
at de.intarsys.pdf.content.CSInterpreter.process(Unknown Source)
at de.intarsys.pdf.content.CSInterpreter.process(Unknown Source)
at de.intarsys.pdf.content.CSDeviceBasedInterpreter.process(Unknown Sour
ce)
at RenderDoc.renderPage(RenderDoc.java:75)
at RenderDoc.renderPages(RenderDoc.java:97)
at RenderDoc.run(RenderDoc.java:139)
at RenderDoc.main(RenderDoc.java:48)
Caused by: java.lang.NullPointerException: no native interface available
at de.intarsys.nativec.api.NativeInterface.set(Unknown Source)
at de.intarsys.nativec.api.NativeInterface.get(Unknown Source)
at de.intarsys.cwt.freetype.nativec._FTNI.init(Unknown Source)
at de.intarsys.cwt.freetype.nativec._FTNI.<init>(Unknown Source)
at de.intarsys.cwt.freetype.Freetype.<clinit>(Unknown Source)
... 11 more
My system windows7 64 bit, java 8 64 bit. I think problem, that freetype.dll not seen outside eclipse. I found it inside jar (jpod dependencies). How I can correctly include this dll in packaging jar, and why it works from eclipse?
This question is from May but in case anyone still has this problem ... The Freetype dll is automatically extracted from the jar file into your temp folder and loaded from there. But the message you get means that the JNA bridge cannot be initialized. That's a problem with your classpath. You need jna.jar and the other jpod dependencies in your classpath.