my dog learned polymorphism*
The moose likes Java in General and the fly likes Linux Executable from .class Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Linux Executable from .class" Watch "Linux Executable from .class" New topic
Author

Linux Executable from .class

Preetham M
Greenhorn

Joined: Sep 18, 2002
Posts: 12
Hi All,
Could somebody help me with converting my .class file to a linux executable. Would also help if you could tell me how i could also create a win exe(.exe) from .class
Appreciate the help.
Thanks,
Preetham.
Mathew Kuruvilla
Ranch Hand

Joined: Nov 27, 2001
Posts: 135
The simplest way is to download the full gcc 3.0 or higher. It contains the gcj compiler which will create a binary from either a .java or a .class file. Read the documentation for the exact flags that you will need to use for .java or .class.
There are other Java to binary compilers. 2 towers is one. Kaffe is another. Then there are a couple of others.
Matt
 
jQuery in Action, 2nd edition
 
subject: Linux Executable from .class
 
Similar Threads
Unhandled execption in EXE containing executable jar file.
regarding classes in jar
running a .exe from JAVA on Linux
Calling executable from an action class
How to run a commandline command from a java program