I want to created a JAR file and I want to run it on a client machine.So, I have a couple of questions:
The Java Packager tool compiles, packages, and prepares Java and JavaFX applications for distribution. The javapackager command is the command-line version. The javapackager utility ships with the JDK. It can generate .exe files with the -native exe flag, among many other things.
An Exe file is an executable file that can be executed in Microsoft OS environment. Jar file is container of Java Class files, including other resources related to the project. Jar file can be executed only if Java run time environment.
See this link: Java to Exe. It also explains what valid reasons are to do this, and when you should not.
You can't really encrypt binaries as the machine has to understand them. That said, an optimized executable is very difficult to decompile, while plain class files are ease.
If you have an exe there are installers enough.
JSmooth is a application which will wrap your Jar in an exe
it also allows you to check if the correct version of JRE is available on the system you're deploying to
http://jsmooth.sourceforge.net/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With