How to create a standalone app? [message #102881] |
Mon, 19 September 2005 07:31  |
Eclipse User |
|
|
|
Originally posted by: leo_zen.gmx.at
I have written my first app in Eclipse and now have the problem, not
knowing how to export it as standalone java-app.
What I've done:
Export => select the path 'src' with everything in it, selected 'export
generated class files and resources', specified a destination, selected to
generate a new Manifest and specify the main-entry point. Click on
'Finish' and I receive 'JAR creation failed with a list of 'Warnings'.
When I try to launch the app with
java -jar test.jar
I get an exception,
Exception in thread "main" java.lang.NoClassDefFoundError:
org/apache/log4j/Logger
And here I don't know, where to define the missing files. Startup via
Eclipse works without any kind of problem.
Anybody an idea what's missing?
|
|
|
|
|
Re: How to create a standalone app? [message #102950 is a reply to message #102924] |
Mon, 19 September 2005 09:29   |
Eclipse User |
|
|
|
Originally posted by: ns_dkerber.ns_WarrenRogersAssociates.com
In article <df9a51c91e973cb630f6d77048f51f49$1@www.eclipse.org>,
leo_zen@gmx.at says...
> > The jars your application depends on are probably missing from the
> > classpath.
>
> I highly assumend that the export of Eclipse does this. i.e. include the
> Classpath into the Manifest, resp. provide a fully functional export to
> one dir.
>
> so, I have in my project 'external' jars, which are included in my project
> build path. execution via Eclipse works fine. but for the standalone, I
> have to take care by myself?
>
> additionally not very clear for me, how to set them. should I include them
> as well into my jar-file, or keep them separte?
You can't put jars within jars, so you need to have them either in the
same folder, or on the classpath.
--
Remove the ns_ from if replying by e-mail (but keep posts in the
newsgroups if possible).
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.08873 seconds