standalone application Processing with Eclipse

Hello guys,

I'm using the Processing libraries with Eclipse.

Everything works OK, but I can not export to executable file, I've tried several paths, so far unsuccessful.

I tried following some tutorials using Proclipsing, but it is not working as expected, breaking links, etc ... I did adding the libraries manually myself, but I can not export.

Can anyone give any tips on how do I export to standalone application?

Thank you very much for your attention.

Answers

  • Eclipse doesn't have a built-in "export application" feature. You can export it as a runnable jar, but not as a .exe file.

    You're going to have to look into products like JWraper or Launch4J in order to package your program up as an executable.

  • edited March 2018

    Hello Kevin, thanks for the feedback.

    I already tried to generate .jar, I actually tried all the possibilities in exporting it in Eclipse, following the tips I found on the Internet.

    Unfortunately I am not finding solutions to a safe guide to solving the problem, I have already tried the paths in these quoted below, but it seems that they do not work anymore.

    I will try these tips that you passed.

    thank you so much!

  • Are you trying to generate a .jar file or a .exe file?

    If you're trying to generate a .jar file, then Eclipse can already do that. Just go to File > Export > Runnable Jar.

    If you're trying to generate a .exe file, then none of your links are applicable. You need to use a tool like JWrapper or Launch4J.

  • Thanks again Kevin ...

    I tried to generate the .jar by the Eclipse options (I tried all 3 possible options), as in this last example, the system generates the .jar, but it simply does not open.

    In Processing I had this problem, when I exported also did not open, had to mount a .bat file with the commands below, and it worked.

    @echo off java -Djava.ext.dirs=lib -Djava.library.path=lib CalAnima

    But I'm having a hard time adding programs in Project with Processing, so I'm trying to switch to Eclipse.

    What I need to do is export an application that runs independently, either .jar or .exe

    I'm trying with Launch4j, but I still have to understand some things, I do not know how to add external libraries, like Processing, ControlP5, Leap Motion, etc ...

    I will continue trying, if you know a tutorial that can help, thank you.

    Thank you very much.

    ExportEclipse

    this is the error that returns with Launch4j

    ExportEclipse2

  • Focus on one thing at a time. Try to get the .jar file working before you try to create a .exe file.

    Try running the generated .jar file from the command line. What errors do you get? Don't just double-click it. Open a command line and run it from there to see the errors.

  • huummm ... when I ran with command prompt, returned this error below:

    I tried to change the name Class Equal to the name of the Project, before MenuPrincipal, but gave the same error (It's in Portuguese) sorry ... laughs ... says that it was not possible to Locate nor Load Main CalAnima

    ExportEclipse3

    I have more than one class, the CalAnima Class is the Calls menu for other Classes, below is the screen, having a better idea, does not yet have all the classes of the original Project in Processing, I just put some here to start the tests.

    Thank you very much for your attention.

    ExportEclipse4

    ExportEclipse5

  • Does your program work when you run it from Eclipse?

    And your command is a bit different from what I would expect. What are you running? I would expect a command like this:

    java -jar YourJarFile.jar
    
  • yes it works, I run it directly in the Eclipse IDE

    The command I passed was just to show that in Processing even generating the exe, also did not work, I needed to create a .bat file, to call the exe.

    I did not get compiled by command line in Eclipse ...

    Thank you very much

  • Hello,

    Just to register here, I decided to do a test, I removed the Libraries from Leap Motion, which was what error was presented when creating the Executable.

    I left in the Project the Libraries of Processing, ControlP5, G4P and Minim, and I was able to create both .jar and .exe, using launch4j, it worked normal.

    So the problem is with the LeapMotion Library, it uses beyond .jar, 2 dlls, it looks like it is not finding their way.

    I generated the .jar exporting as it is selected in the image below:

    ExportEclipse6

    But this is already a great progress, thank you very much for the help here.

    Thanks anyway, thank you!

  • I spoke early ... laughs ... even open the Start Menu, but when you try to run a second Window (another Class), you can not open ...

    ExportEclipse8

    I will continue searching to see what it is possible to do ...

    Thank you

Sign In or Register to comment.