I have never used the packager before and decided to learn/use it. There was a lot of trial and error, and scrapping of a number of forum threads to figure this packager out. And I am still not sure I am doing things properly. I am Linux only, no Android or Mac or Windows. So: (everything was done in release mode)
1: I used a sample program (not mine) to test it, using the internal packager everything worked fine, and was very easy to use. Produced a nice executable.
2: Unfortunately I am not a windows user, and need to do this via a separate Linux box, hooked up with the debugger.
3: I honestly could not figure out how to tell the internal packager to make a package remotely on the Linux platform, kept producing a Windows executable.
4: Switched to the B4J 1.21 external packager - changed the input string to point to the file on the remote Linux box, ran fine, everything worked.
5: The issue on the Linux box was - the external packager produces a bash file called run.command, I thought bash files had an extension of .sh, was a bit confusing at first.
For whatever reason (I am not a expert Linux user), I could not run the run.command bash script using sudo, or ./ from the terminal, however I was able to run it from the desktop by just double clicking it for the file explorer. Not sure why this is the case.
Now I tried my original program, that I am writing for my embedded boards.
1: Using the external packager, as with the before program, I was able to create the packaged files etc.., but whenever I ran the program, it immediately crashed (window would launch then immediately shut down). I just in case went back to windows and created an executable instead and the program worked fine.
2: Also tested in a compile and run mode (no debugger) on the Linux desktop, from the B4J environment - ran fine, so I copied the released Java file to the Linux desktop and ran it directly with no problems, using the Java - jar etc.. from the terminal.
3: My program at startup does a start of the serial ports, I stripped this call out, and reran the external packager and the program ran fine, so I have some kind of issue with the serial port initialization at run time????
To sum up the above into a few succinct questions:
1: Can the internal packager package for a Linux platform, what have I missed or done wrong (I don't know how to point to the external platform using the debugger - something probably obvious that I missed)- I am using B4j 8.5.
2: When using the external packager, something must be going wrong when jserial is in the code? Am I missing something in the steps, some declaration?
3: Is there a real difference in running (I can create a script) from the terminal using Java -jar, versus using the packager?? Is it worth the bother? The app is distributed on my embedded boards, only.
But I would still like to figure this out.
1: I used a sample program (not mine) to test it, using the internal packager everything worked fine, and was very easy to use. Produced a nice executable.
2: Unfortunately I am not a windows user, and need to do this via a separate Linux box, hooked up with the debugger.
3: I honestly could not figure out how to tell the internal packager to make a package remotely on the Linux platform, kept producing a Windows executable.
4: Switched to the B4J 1.21 external packager - changed the input string to point to the file on the remote Linux box, ran fine, everything worked.
5: The issue on the Linux box was - the external packager produces a bash file called run.command, I thought bash files had an extension of .sh, was a bit confusing at first.
For whatever reason (I am not a expert Linux user), I could not run the run.command bash script using sudo, or ./ from the terminal, however I was able to run it from the desktop by just double clicking it for the file explorer. Not sure why this is the case.
Now I tried my original program, that I am writing for my embedded boards.
1: Using the external packager, as with the before program, I was able to create the packaged files etc.., but whenever I ran the program, it immediately crashed (window would launch then immediately shut down). I just in case went back to windows and created an executable instead and the program worked fine.
2: Also tested in a compile and run mode (no debugger) on the Linux desktop, from the B4J environment - ran fine, so I copied the released Java file to the Linux desktop and ran it directly with no problems, using the Java - jar etc.. from the terminal.
3: My program at startup does a start of the serial ports, I stripped this call out, and reran the external packager and the program ran fine, so I have some kind of issue with the serial port initialization at run time????
To sum up the above into a few succinct questions:
1: Can the internal packager package for a Linux platform, what have I missed or done wrong (I don't know how to point to the external platform using the debugger - something probably obvious that I missed)- I am using B4j 8.5.
2: When using the external packager, something must be going wrong when jserial is in the code? Am I missing something in the steps, some declaration?
3: Is there a real difference in running (I can create a script) from the terminal using Java -jar, versus using the packager?? Is it worth the bother? The app is distributed on my embedded boards, only.
But I would still like to figure this out.