Hi Sapan,

We use Launch4j http://launch4j.sourceforge.net/ to create
.exe files that run Vergil etc. and then use
IzPack (http://www.izforge.com/izpack/) to set up the start menu.

$PTII/mk/jnlp.mk contains rules to create the .exe files such
as vergil.exe

$PTII/bin/mkl4j is a shell script that takes arguments such as
the name of the exe, the classname that contains the main, the
icon, the command line arguments and the jar files and then
produces an xml file that is passed to Launch4j.

Launch4j then produces the .exe

jnlp.mk is a little raw, you may need to edit jnlp.mk and change
PTCYGPATH and L4J_DIR.

To build vergil.exe, first build the jar files, then vergil.exe:
 cd $PTII
 make install
 make vergil.exe

You could look around at the Launch4j web page and see if there
is a way to add to the classpath at runtime.  They mention
"Supports executable jars and dynamic classpath resolution using environment variables and wildcards." but I did not see
an obvious way to do that, so it seems building a new vergil.exe
to include your jar files is the right way to do it.

Another way would be to unjar one of the jar files, add your
.class files to the directory that was created, then create a new
jar file that includes the previous .class files and your .class files.

_Christopher



Sapan AGARWAL wrote:
Hi All,
I want to add one external jar in the classpath. When I launch vergil thorugh eclipse, I add the jar file in classpath through project properties and I am able to run properly. When I launch vergil.exe (outside eclipse framework), I am not able to add my jar file in the classpath. What is the correct way to add jar files in classpath so that execution is correct even if we launch vergil.exe directly. I even tried to modiy the .classpath file but it did not help. Thanks & Regards,
Sapan

--
Christopher Brooks (cxh at eecs berkeley edu) University of California
CHESS Executive Director                      US Mail: 337 Cory Hall
Programmer/Analyst CHESS/Ptolemy/Trust        Berkeley, CA 94720-1774
ph: 510.643.9841 fax:510.642.2718             (Office: 545Q Cory)
home: (F-Tu) 707.665.0131 (W-F) 510.655.5480

----------------------------------------------------------------------------
Posted to the ptolemy-hackers mailing list.  Please send administrative
mail for this list to: ptolemy-hackers-requ...@ptolemy.eecs.berkeley.edu

Reply via email to