RE: Trouble configuring custom extension in xmlcalabash

Hi Andrew,

Thanks!

Listing all dependencies doesn't seem necessary though. I just have my own jar and calabash.jar in the classpath, and it is still able to locate for instance saxon, which is quite necessary and certainly not loaded with JRE by default.. ;-)

Saves me a lot of trouble. It might be a feature from java 1.6, I hadn't expected it to work like this myself either..

Kind regards,
Geert

-----Oorspronkelijk bericht-----
Van: Andrew Welch [mailto:andrew.j.welch@gmail.com] 
Verzonden: donderdag 21 juli 2011 10:53
Aan: Romain Deltour
CC: Geert Josten; XProc Dev (xproc-dev@w3.org)
Onderwerp: Re: Trouble configuring custom extension in xmlcalabash

> I'm really not sure, but could it be that the Java "cp" option is not used
> when trying to execute a Jar (instead of a main class) ?

Sorry I haven't followed the thread, but yes in Java if you use the
-jar option then any classpath settings are ignored as the manifest in
the specified jar is used.

If you need to add your items to the classpath then you can't use -jar
and have to use -cp (or -classpath), manually specifying the jar and
all of its dependencies (which you can get from its manifest).  On
Windows you can use wildcards like lib/* to pick up all jars in the
lib, but on OSX you will need to list them all.


-- 
Andrew Welch
http://andrewjwelch.com

Received on Thursday, 21 July 2011 09:06:40 UTC