Re: JAR problem

From: Daniel Schneller (danny_reMo_ve_for__spam_Protection_schneller_at_bigfoot.com)
Date: 10/16/03


Date: Thu, 16 Oct 2003 17:05:53 +0200

Hi!

> I have created a Jar file for my project with *.classes, lib folder and
> Manifest file.
Sounds good so far, except for the lib folder...

> I can run the Jar file successfully to get desired output from the same
> directory, I have created the Jar file from.
That is quite normal. Your application can read the jars from the lib
folder, i. e. *not* from the newly built jar file. You cannot nest jars
in jars. You have two alternatives:

- unpack all jars and repack them into a single one without an included
"lib" folder
- copy your lib folder *and* your own jar to the 2nd machine. You could
zip them together and make them self extracting.

Daniel



Relevant Pages

  • jar package is running me nuts
    ... I've generated a jar file with a nant script, put all required jars ... all jars are contained in lib and it stumbles on log4J. ... What's wrong with my manifest file? ...
    (comp.lang.java.programmer)
  • Re: jar package is running me nuts
    ... I've generated a jar file with a nant script, put all required jars ... all jars are contained in lib and it stumbles on log4J. ...
    (comp.lang.java.programmer)
  • Re: Building classpath at runtime
    ... I sometimes need to create emergency fixes or jars. ... put them in an "updates" directory. ... As names of these jar files will be ... first all jars from update and then all jars from lib ...
    (comp.lang.java.programmer)
  • Re: Executable JAR ClassPath problem
    ... or am I forced to have an 'install' step then? ... into a single jar file, and you wouldn't even need the Class-Path ... library jars in their prescribed locations. ... Users understand that apps ...
    (comp.lang.java.programmer)
  • Re: Connect to db2/400 through jsp
    ... If jt400.jar has to be pkaced in WEB-INF,ho winstall .jar file here? ... just like it is a basic fact that individual packages/classes go into the WEB-INF/classes directory and the deployment descriptor is WEB-INF/web.xml. ... How you get the JARs into the right directory can be by "copy", "cp", Ant, graphical interfaces to the file system, your favorite IDE and so forth. ...
    (comp.lang.java.programmer)