Re: jar problems
Ignore my previous email. I got it wrong.
You cannot have both -classpath and -jar as path of the java command.
"When you use -jar, the JAR file is the source of all user classes, and
other user class path settings are ignored." This is why it cant find
the JarMan class because the jarman jar file is being ignored.
What you need to do is add the Class-Path attribute to the manifest:
Class-Path: jarman.jar
--
Fahd Shariff
"Let the code do the talking... "
.
Relevant Pages
- Re: jar access problem
... other user class path settings are ignored." ... This is why it cant find ... the JarMan class because the jarman jar file is being ignored. ... What you need to do is add the Class-Path attribute to the manifest: ... (comp.lang.java.programmer) - Re: Weird JVM Behaviour?
... the "java" command, you'll notice what the last line says: ... and other user class path settings are ignored. ... The jar file provides a way of specifying additional jar files to be ... included in the classpath (through the "Class-Path:" attribute in the ... (comp.lang.java.programmer) - Re: Starting java with -jar option precludes *.class files on CLASSPATH ?
... >What "application classes" are not loaded from the JAR file? ... Sun classes ... classes mentioned in the Jar's Class-Path ... Prev by Date: ... (comp.lang.java.programmer) - Re: JAR files and manifest: Class-Path
... HTH, ... > I have a base dir, where the application JAR file resides. ... > dir, there's also a lib dir, nothing special really. ... > Is there any way to use the Class-Path entry in the manifest, ... (comp.lang.java.programmer) - Re: Starting java with -jar option precludes *.class files on CLASSPATH ?
... > and OTHER USER CLASS PATH SETTINGS ARE IGNORED. ... loaded from anywhere except that JAR file -- which is manifestly false. ... leaves open the question of whether it is possible to refer to external ... (comp.lang.java.programmer) |
|