Solved

How to generate executable jar file from JSystemTrader with Eclipse ?

Posted on 2007-04-03
9
1,262 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
ID: 18842434
I could add the JSystemTrader into eclipse and compile it. Try refreshing the workspace using F5
0
 

Author Comment

by:Couturier
ID: 18844726
Hi Jaax,

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

Expert Comment

by:objects
ID: 18847214
theres a field in the about the 3rd jar export screen to enter the Main Class
0
Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

 

Author Comment

by:Couturier
ID: 18849007
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
 
LVL 92

Expert Comment

by:objects
ID: 18849141
u need to specify the main class when exporting the jar
0
 

Author Comment

by:Couturier
ID: 18849190
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
ID: 18849219
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
ID: 18858876

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
ID: 18863938
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

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
groupSum6 challenge 6 85
JUnit 4 @Before and @BeforeClass differences 3 59
servlet example issue 6 38
java stored proc example 9 29
For customizing the look of your lightweight component and making it look lucid like it was made of glass. Or: how to make your component more Apple-ish ;) This tip assumes your component to be of rectangular shape and completely opaque. (COD…
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…
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.

813 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

13 Experts available now in Live!

Get 1:1 Help Now