1

I developed a system using jdk 6. then i want to deploy that system to all kind of users(windows, linux). and also i want to create . exe file to install inside the client machine. this process should check whether there exists java(compatible version) inside the client machine. if there is not java inside the machine then installation process should provides facility to install it.and also software used to do that should be freely available. thanks in advance.

Weli Nuwan
  • 105
  • 2
  • 2
  • 6
  • 2
    But .exe will be supported only in Windows Platform ri8? – Anubhab Mar 13 '13 at 05:32
  • Please check this link: http://www.javatips.net/blog/2011/09/convert-java-jar-file-to-exe – Sudhanshu Umalkar Mar 13 '13 at 05:32
  • I don't mean to be mean, but this the third time I've seen such a question in two days. Having said that, I use exe4j. You will need to pay for it, but it does most of what you asked, at least one Windows. – MadProgrammer Mar 13 '13 at 05:32
  • This is a very common question. You should search this site for other answers. – jahroy Mar 13 '13 at 05:33
  • 1
    duplicates: http://stackoverflow.com/questions/10473194/create-an-exe-with-jar-file-and-resources http://stackoverflow.com/questions/13875587/create-exe-from-jar-file-using-build-xml – rajesh Mar 13 '13 at 05:34
  • If the app. has a GUI the answer is `deployJava.js` + [Java Web Start](http://stackoverflow.com/tags/java-web-start/info). – Andrew Thompson Mar 13 '13 at 05:34
  • Here's [one duplicate](http://stackoverflow.com/q/147181/778118)... and [another](http://stackoverflow.com/q/4330936/778118)... and [another](http://stackoverflow.com/q/2272107/778118)... and [another](http://stackoverflow.com/q/10872204/778118)... – jahroy Mar 13 '13 at 05:35

2 Answers2

1

Please try using NSIS (http://nsis.sourceforge.net/Main_Page). Basically you will need to write a NSIS script to do the following

  1. Check if JAVA exists. [Depending on 32 or 64 bit machine you need to check different node]
  2. Get the java path
  3. Run the command java -jar XXXX

There are many sample scripts available on NSIS site. Let me know if you need more help. I will send you sample script.

abhinav
  • 1,252
  • 10
  • 27
1

there are few tools available for this. google for "JarToExe", "advanceInstaller".

REF: Convert Jar file to EXE executable

Ankit
  • 6,554
  • 6
  • 49
  • 71