Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > What is the best way to make a Java Application executable?

Reply
Thread Tools

What is the best way to make a Java Application executable?

 
 
C-man
Guest
Posts: n/a
 
      08-09-2004
What is the best way to make a Java Application executable?



Thanks

Cleave


 
Reply With Quote
 
 
 
 
Michael Cox
Guest
Posts: n/a
 
      08-09-2004
Depends where you want to run it I should think


 
Reply With Quote
 
 
 
 
Steven J Sobol
Guest
Posts: n/a
 
      08-09-2004
C-man <(E-Mail Removed)> wrote:
> What is the best way to make a Java Application executable?


which platform? Windows or something else?

--
JustThe.net Internet & New Media Services, http://JustThe.net/
Steven J. Sobol, Geek In Charge / 888.480.4NET (463 / http://www.velocityreviews.com/forums/(E-Mail Removed)
PGP Key available from your friendly local key server (0xE3AE35ED)
Apple Valley, California Nothing scares me anymore. I have three kids.
 
Reply With Quote
 
Andrew Thompson
Guest
Posts: n/a
 
      08-09-2004
On Mon, 09 Aug 2004 21:26:52 GMT, C-man wrote:

> What is the best way to make a Java Application executable?


'Not'
<http://www.physci.org/codes/javafaq.jsp#exe>

HTH

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
 
Reply With Quote
 
Steven J Sobol
Guest
Posts: n/a
 
      08-10-2004
Andrew Thompson <(E-Mail Removed)> wrote:
> On Mon, 09 Aug 2004 21:26:52 GMT, C-man wrote:
>
>> What is the best way to make a Java Application executable?

>
> 'Not'
> <http://www.physci.org/codes/javafaq.jsp#exe>


That describes reasons not to compile Java bytecode into native code. However,
I don't see any compelling reason not to wrap an app in a Windows or other
executable that fires up the JVM and launches your app via JNI. The question
is, which was C-man talking about: compiling to native code, or using an
exe wrapper? If the former, I'd agree with your reply. If the latter, not.

--
JustThe.net Internet & New Media Services, http://JustThe.net/
Steven J. Sobol, Geek In Charge / 888.480.4NET (463 / (E-Mail Removed)
PGP Key available from your friendly local key server (0xE3AE35ED)
Apple Valley, California Nothing scares me anymore. I have three kids.
 
Reply With Quote
 
Andrew Thompson
Guest
Posts: n/a
 
      08-10-2004
On Mon, 09 Aug 2004 21:43:44 -0500, Steven J Sobol wrote:

> I don't see any compelling reason not to wrap an app in a Windows or other
> executable that fires up the JVM and launches your app via JNI.


How about these three..
a) non-portability
b) extra overhead
c) lack of need (no advantages over JWS)

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
 
Reply With Quote
 
Jacob
Guest
Posts: n/a
 
      08-10-2004
C-man wrote:
> What is the best way to make a Java Application executable?


A .jar file with an appropriate manifest file *is* an
executable, and should (in principle) run perfectly on
any platform. The exact approach for starting the
application may differ (on MS/Windows or Solaris you
double click on the .jar or write its name as a command
in a console window), and you might need to do some
OS setup adjustments to set it up correctly.

Remember that the Java runtime environment (JRE) must be
available on the client machine in order for a Java
application to run. This is the price for platform
independency, but as an application programmer this is
not really of your concern.

 
Reply With Quote
 
Steven J Sobol
Guest
Posts: n/a
 
      08-10-2004
Andrew Thompson <(E-Mail Removed)> wrote:

>> I don't see any compelling reason not to wrap an app in a Windows or other
>> executable that fires up the JVM and launches your app via JNI.

>
> How about these three..
> a) non-portability
> b) extra overhead
> c) lack of need (no advantages over JWS)


I like to use exe4j because it allows the exe to automatically set up its
classpath, find the VM, etc., but mostly because it's nice to be able to
search for the program in the Windows task manager, so I can see what kind
of resources it's using, and not have to wade through a dozen javaw.exe
processes (the task manager will show the name of the exe instead). I'd have
the same reasons for doing something similar on a Unix box.

I certainly wouldn't do it because it's portable.

--
JustThe.net Internet & New Media Services, http://JustThe.net/
Steven J. Sobol, Geek In Charge / 888.480.4NET (463 / (E-Mail Removed)
PGP Key available from your friendly local key server (0xE3AE35ED)
Apple Valley, California Nothing scares me anymore. I have three kids.
 
Reply With Quote
 
Victor Chew
Guest
Posts: n/a
 
      08-10-2004
I tend to agree. I use NativeJ to wrap some common Java apps that I use
on a daily basis (jEdit, nntprss). It is definitely nicer than having to
muck around with batch files and environment variables, plus I can use
Win32 services when I need them (eg. for nntprss).

I even got jEdit set up so that everything (including preferences and
extensions) are stored on a USB drive. That way, I can use it across my
home and office machines. Nice!

Steven J Sobol wrote:

> Andrew Thompson <(E-Mail Removed)> wrote:
>
>
>>>I don't see any compelling reason not to wrap an app in a Windows or other
>>>executable that fires up the JVM and launches your app via JNI.

>>
>>How about these three..
>>a) non-portability
>>b) extra overhead
>>c) lack of need (no advantages over JWS)

>
>
> I like to use exe4j because it allows the exe to automatically set up its
> classpath, find the VM, etc., but mostly because it's nice to be able to
> search for the program in the Windows task manager, so I can see what kind
> of resources it's using, and not have to wade through a dozen javaw.exe
> processes (the task manager will show the name of the exe instead). I'd have
> the same reasons for doing something similar on a Unix box.
>
> I certainly wouldn't do it because it's portable.
>

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Manipulating a Third-Party Java Application from another Java Application travis.troyer@gmail.com Java 6 04-10-2007 05:43 AM
What's the best way to make a survey in .NET? Gummy ASP .Net 2 10-27-2005 02:49 PM
What is the best way to make dual-way xml databinding? Stan ASP .Net 3 05-05-2005 02:07 PM
What is the best way to Invoke a java application from ASP.NET Aimee ASP .Net 3 10-21-2004 05:49 PM
The best way to make a generic report page using a web service indicated in a xml file. Pablo Gutierrez ASP .Net 0 10-27-2003 11:03 PM



Advertisments