How to package JAVA apps?


ekianjo

Hardcore Member
Joined
May 7, 2012
Messages
8,261
Location
神戸市、日本 (Japan)
One thing I was wondering, since there are a LOT of open source Java apps out there (and a lot being platform independent as well), is how would one go about packaging a java app ?


I understand that you can run a jar file from the terminal with java -jar xxxx.jar command, but how about other java programs which are not contained in jar?
 
I use Sebt3's Tool chain.


I setup a script to just execute the needed java -jar your_jarfile.jar and then make the PXML for it.. then use the pnd_make executable to package the PND..



Code:
Usage: pnd_make.sh -p your.pnd -d folder/containing/your/app/ -x

	your.pxml (or "guess" to try to generate it from the folder) -i icon.png
 
Last edited by a moderator:
I usually take the generic linux package of the app which quite often contains the .sh script with all necessary calls and parameters and amend it a bit to Pandora's environment if needed, adding some variables, wrapping it into PND with manually edited PXML.
 
I use Sebt3's Tool chain.


I setup a script to just execute the needed java -jar your_jarfile.jar and then make the PXML for it.. then use the pnd_make executable to package the PND..



Code:
Usage: pnd_make.sh -p your.pnd -d folder/containing/your/app/ -x

	your.pxml (or "guess" to try to generate it from the folder) -i icon.png

My question was for non-jar files :)
 
Last edited by a moderator:
Can use the same method as long as you can execute it in via a shell script. This just creates a PND from the folder you specify, the script you specify to be executed in the PXML can run it anyway you want.
 
Last edited by a moderator:
Can use the same method as long as you can execute it in via a shell script. This just creates a PND from the folder you specify, the script you specify to be executed in the PXML can run it anyway you want.

Can you execute a non-jar file (like a .java ?) using the same instructions in the shell?
 
yeah I haven't done it in a while, isn't it just javac -g your_file.java ?
 
Can use the same method as long as you can execute it in via a shell script. This just creates a PND from the folder you specify, the script you specify to be executed in the PXML can run it anyway you want.

Can you execute a non-jar file (like a .java ?) using the same instructions in the shell?
No. .java are source files. Using javac would compile them, not execute them. You would either need the class file(s) or the jar.
 
Back
Top