Open rsanchez-wsu opened 7 years ago
I'm going to be working on this one!
@rsanchez-wsu So after wrapping the .jar file into a shell file it shows that I have 167, 364 additions in it. I was wondering if something like that was correct before submitting a pull request.
I was also wondering how the wrapping works. I'm assuming that a file is placed inside the .jar file with the Main class location, but if that's changed I'm not sure if that gets automatically fixed. Possibly a future issue if we decide to change the location of the main file?
Thanks!
@aar118 I think that you have misunderstood the intent of this task. You have committed a .exe, a .jar, and a .sh into the repository, which is not correct. The build currently only creates a collection of .class
files. What needs to happen is that the build (i.e., when you run ant all
, or when you run gradle later on when that transition is complete) needs to also output an executable jar, the jar wrapped in an .exe and the jar wrapped in a shell script. All of your changes should be made within the build.xml
file. I recommend that you revert your commit.
Here's a nice plugin that could be very useful in building the exe wrapper. https://github.com/TheBoegl/gradle-launch4j
@aar118 The fat JAR creation works, but it looks like the exe wrapper isn't getting built:
./gradlew createExec
FAILURE: Build failed with an exception.
* What went wrong:
Task 'createExec' not found in root project 'raiderplanner'. Some candidates are: 'createExe'.
* Try:
Run gradlew tasks to get a list of available tasks. Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
* Get more help at https://help.gradle.org
BUILD FAILED in 0s
./gradlew createExe
Download https://jcenter.bintray.com/net/sf/launch4j/launch4j/3.11/launch4j-3.11-workdir-linux64.jar
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':createExe'.
> net.sf.launch4j.BuilderException: Icon doesn't exist.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
* Get more help at https://help.gradle.org
BUILD FAILED in 24s
4 actionable tasks: 1 executed, 3 up-to-date
Is this expected?
The project build should produce a single executable jar, which can be wrapped in an appropriate shell wrapper (for Linux and Unix) or an .exe wrapper (for Windows).
java -jar RadierPlanner.jar
)./RaiderPlanner
on Linux and Unix)RaiderPlanner.exe
or by double-clicking on Windows)Related resources: