We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
Page Index Toggle Pages: 1
Export Application (Read 1416 times)
Export Application
May 8th, 2005, 12:43am
 
I hope this is posted in the correct forum -- I checked around first and it seemed like a decent match.. if it's not, I'll scold myself.

Er, anyway.  I see an "Export Application" in the P5 IDE (0087 Beta), and was just wondering what is planned for this?  Will this create a (cross-platform) executable JAR file?  If so, will the end result work/perform similarly to the results when pressing the "Play" button in the IDE?

I'm doing a fairly big project with P5 right now that involves OpenGL, sockets and perhaps some .ogg library.  So I'm very curious about the Export Application feature Smiley

Thanks very much,
dxtx
Re: Export Application
Reply #1 - Jul 17th, 2005, 10:31pm
 
this would be the kind of stuff that i'm planning for the export to application.. the idea is that it would also bundle up all the libraries and whatnot, and create a .exe on the pc (which would have a supporting data folder) and a .app file on the mac (which may not need a support folder). for linux or elsewhere, an "executable jar" file will be created. though you'll be able to create the .app from the pc or the .exe from that mac as well and so on.

this is actually a good part of the delay in getting it implemented, that making it work correctly (and consistently) with exported libraries and across many platforms it gets a little tricky. i can hack it quickly but would waste too much time supporting it here on the board because it would only work a percentage of the time.
Re: Export Application
Reply #2 - Jul 17th, 2005, 11:31pm
 
I'd be happy just with the executable JAR option, and I'd presume any files saved would end up in the same directory as where I executed the JAR from.
Re: Export Application
Reply #3 - Nov 8th, 2005, 7:01pm
 
http://processing.org/discourse/yabb/YaBB.cgi?board=Tools;action=display;num=1084266556;start=8
for more on the fixes (Ben seemed to report a "major upcoming release" on this in March 04)
Re: Export Application
Reply #4 - Nov 10th, 2005, 5:44am
 
if you have a sketch named "blah" and add these lines to your code:

Code:
static public void main(String args[]) {
PApplet.main(new String[] { "blah" });
}


and export the sketch, then double clicking the jar file may work with current releases.

this *will not* work when using libraries (or at least not consistently).

export to application status:
http://dev.processing.org/bugs/show_bug.cgi?id=60
Re: Export Application
Reply #5 - Nov 23rd, 2005, 7:16pm
 
Once it's an application in .JAR form, an application like http://launch4j.sourceforge.net/ can wrap it into a windows application that includes the JVM.DLL, complete with its own icon and executable.  Launch4J boasts some nice features, but didn't work on my machine.

There is also http://www.sfu.ca/~tyuen/jelude/ which provides documentation on how to set up a Windows executable which will detect the presence of Java before it executes your JAR.  This particular solution depends on Creative-Commons compatible NSIS files, a Nullsoft script compiler.

There is also the freeware exeJ, commercial applications JExeWrapper, and JNIWrapper.

Re: Export Application feature
There might be an issue of platform-specific differences; on Windows, Java is not always installed; so for the Mac or Linux versions of an application, the application might just as well be left as a jar, with an included execution script (chmod 700)

-milf
Page Index Toggle Pages: 1