solving packaging issues once and for all

I usually use ant for my little applications and it usually takes me a little bit to organize it to include the system files JOGL requires. My end goal is to be able to get the entire package into a single jar file per OS (project_windows.jar, project_linux.jar, etc.). I’ve started using jarjar, which seems fine for including non-system-based libraries into the final jar file, but it doesn’t handle the dynamic libraries. I’m told I need to actually move the so’s and dll’s to a new directory outside of a jar for the JVM to read them, but that’s been a headache. I’ve been trying to search through the jar at runtime to find the so’s and dll’s and copy them to a temp dir, but it’s not working somewhere. Is there a different way to go about this? Is there some generic one-size-fits-all JOGL jar file I link to on the internet? I just want everything into one little jar file and be callable without modifying the classpath manually…

java -jar project_windows.jar

Well if you’re using webstart then you can just include the JOGL/LWJGL jnlp extension file in your app and that takes care of everything. Otherwise if you’re deploying on desktop then you’ll have to extract the DLL/SO files from the jar during runtime so it works.