Solved

How to generate executable jar file from JSystemTrader with Eclipse ?

Posted on 2007-04-03
9
1,253 Views
Last Modified: 2008-01-09
Hi,

Eclipse 3.2
I try to generate executable jar file from this Java program under BSD licence :
http://www.myjavaserver.com/~nonlinear/JSystemTrader/JSystemTrader.html

I do :
Menu / file / Export...
Etc.

I have the following Error dialogue box :

JAR creation failed. See details for additional information.
Exported with compile warnings: /JSystemTrader/source/com/ib/client/EReader.java
Exported with compile warnings: /JSystemTrader/source/com/jsystemtrader/backdata/BackDataDialog.java
Exported with compile warnings:

Then warning about all class
Then  this error message :

Resource is out of sync with the file system: /JSystemTrader/log/EventLog.htm.

I think it is not the warning which stop generate Jar.
I think it is the last error message :
Resource is out of sync with the file system: /JSystemTrader/log/EventLog.htm.

How to generate executable jar file from JSystemTrader with Eclipse ?

Thanks.
0
Comment
Question by:Couturier
  • 5
  • 3
9 Comments
 
LVL 10

Accepted Solution

by:
Jaax earned 500 total points
Comment Utility
I could add the JSystemTrader into eclipse and compile it. Try refreshing the workspace using F5
0
 

Author Comment

by:Couturier
Comment Utility
Hi Jaax,

Could you show me MANIFEST.MF file or ant script ?
0
 
LVL 92

Expert Comment

by:objects
Comment Utility
theres a field in the about the 3rd jar export screen to enter the Main Class
0
 

Author Comment

by:Couturier
Comment Utility
Hi Jaax,

I try F5 and it help me to do a step.
Now I do a jar file but when I double click I have the following error box :

Failed to load Main-Class manifest attribute from S:\testJSystemTrader.jar


0
Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 92

Expert Comment

by:objects
Comment Utility
u need to specify the main class when exporting the jar
0
 

Author Comment

by:Couturier
Comment Utility
Hi objects,

I have specified the main class during the exporting process.
But I have the message :

Failed to load Main-Class manifest attribute from S:\testJSystemTrader.jar
0
 
LVL 92

Expert Comment

by:objects
Comment Utility
check you have specified the correcxt class name

and try running it from command line to see if there are any exceptions at startuip

java -jar testJSystemTrader.jar
0
 

Author Comment

by:Couturier
Comment Utility

I think that only a ready to use built.xml ant file could realy help me.
Could someone to made it ?

0
 

Author Comment

by:Couturier
Comment Utility
Hi,

Eclipse 3.2

Eclipse 3.2
I try to generate executable jar file from this Java open source program under BSD licence :
http://www.myjavaserver.com/~nonlinear/JSystemTrader/JSystemTrader.html

Source code :
http://www.myjavaserver.com/~nonlinear/JSystemTrader/JSystemTrader.zip

There is a tutorial How to install JSystemTrader under Eclipse here :
http://groups.google.com/group/JavaTraders

I have already write 2 files :
A batch file to launch JSystemTrader.jar with the current directory parameter :

RunJST.bat

JSystemTrader.jar  cd
pause


And a xml for ANT

build.xml

<?xml version="1.0" encoding="UTF-8"?>

<project name="JST.makejar" default="makejar" basedir=".">

      <target name="compile" description="Compile the project">
            <javac fork="yes" srcdir="source/" destdir="bin/" classpath="lib/" />
      </target>

      <target name="makejar" description="Create a jar for the JSystemTrader project">
            <jar destfile="JSystemTrader.jar" basedir="bin/" compress="true">
                  <manifest>
                        <attribute name="Main-Class" value="com.jsystemtrader.client.JSystemTrader" />
                        <attribute name="Class-path" value="./;resources/;lib/jfreechart-1.0.0.jar;lib/jcommon-1.0.0.jar;lib/liquidlnf.jar" />
                  </manifest>
            </jar>
      </target>

</project>


The ANT xml  create 2 error dialogue boxs.
The first is :
Unable to set custom look & feel. The default L&F will be used.

Please help me to terminate this ANT xml.



0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
Viewers will learn about basic arrays, how to declare them, and how to use them. Introduction and definition: Declare an array and cover the syntax of declaring them: Initialize every index in the created array: Example/Features of a basic arr…
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now