views:

278

answers:

1

I'm using JODConverter 3.0 to handle communicating with OpenOffice to convert documents. Everything is working fine except that JODConverter uses a Java library from OpenOffice that uses JNI to grab certain library files from the system. This throws an exception if I don't set the java.library.path method using -D when running java.

The application I'm building is platform independent and has one central configuration file. I'd like to keep it that way. I was thinking about adding each file needed in the URE bin using System.load, but seems like a bit much. I also was thinking of maybe in my initialization script (the script that runs my application) have some kind of way of finding the location to the URE bin directory dynamically. I haven't been able to find a good solution for this as OpenOffice doesn't set any environment variables when installed.

I hope my question isn't to vague or too library specific (or both), it's late here and I've been at this for awhile.

Thanks!

A: 

I ended up having the command put directly into the startup script which will be created on install. When installing the user can specify the path and also change it in the future.

William