I developed a project using Java and now I've to deliver it to client who is using Linux. Which executable file format will be delivered and how to make that?
Java is the world's popular software development platform that James Gosling develops. It is designed to support multiple platforms like Linux, macOS and Windows. Mobile and Desktop applications can also be developed using Java language.
Java code compiled on Windows can run on Linux.
Executable file format?
If you're delivering a Java app, give them a jar file (and associated libs).
Provide a shell script to set up its environment and execute it.
For example, assuming I define ROOT_DIR
as my app's install directory, and so on:
CLASSPATH="${ADD_JARS}:${CLASSPATH}:${ROOT_DIR}/lib/myApp.jar:\
${ROOT_DIR}/lib/jibx/jibx-run.jar:\
${ROOT_DIR}/lib/jibx/xpp3.jar:\
${ROOT_DIR}/lib/bindings.jar:\
${ROOT_DIR}/lib/commons-lang-2.0.jar:\
${ROOT_DIR}/lib/forms-1.0.5.jar"
"${JAVACMD}" -Xmx256M -DanyDefsNeeded=foobar -Dbase.dir="${ROOT_DIR}" -cp "${CLASSPATH}" myApp.main.Launcher "$@"
What goes into the shell script depends totally on what your app actually needs to start up.
A jar. If it is not executable, then a script (.sh) to launch the jar.
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