Closed hanslovsky closed 2 months ago
Relevant for #251
Possibly related: https://bugs.openjdk.java.net/browse/JDK-8138944
Also related (and look who created that post :smile:): https://stackoverflow.com/questions/30809330/how-can-dynamic-jvm-command-line-flags-be-passed-to-a-self-contained-javafx-appl
Also have a look at jpackage
:
https://www.infoq.com/news/2019/03/jep-343-jpackage/
https://jdk.java.net/jpackage/
Probably(?) not compatible with Java8.
I don't know if this has been discussed elsewhere, but would it be possible to ship with Fiji? I.e. adding it via a paintera update site. This would be the easiest way to deploy it to users.
Unfortunately, that is not possible because Fiji uses swing/awt and Paintera uses the JavaFX UI framework. Interop is not great between those
Unfortunately, that is not possible because Fiji uses swing/awt and Paintera uses the JavaFX UI framework. Interop is not great between those
Thanks for the clarification. In that case, having a standalone app would indeed be a very good solution. Once you have a first version, I am happy to test.
I think the easiest way for ward is to create tar/zip files with (or without) the required Java Runtime and all Jars and shell (Linux/macOS) and batch (Windows) scripts that execute that, with installers for macOS/Windows and deb (or other packages) for Linux. I will not be at Janelia much longer, so I will not be able to address this but this may be a good community contribution because it does not require any (deep) knowledge about Java programming.
Also, cc @igorpisarev and @axtimwalde
The most recent Paintera release now has some platform specific standalone installers for MacOS, Windows, and Ubuntu. It's not currently a replacement for the conda release process, but it's useful for installing a version that tracks against the master branch. It uses the jtoolprovider-plugin for maven, which facilitates using jpackage
to generate the standalone JRE.
It's triggered on pushes to master, through github actions, so should always track with the most recent master commit.
The README has some more information about it, including some known limitations at the moment.
Releases are here: https://github.com/saalfeldlab/paintera/releases
I tested it this morning on a Mac M2. And it works! Great job!.
This is surprising because we do not build releases for M1/2...
To be clear, it can be done, I have tested locally on an M1 and it works well. But the github automatic releases are not built on M1/M2 Macs. It's something I hope to set up soon, as we refine this release process
Well, to me it looks like you are very good at it for something you don't do:
Currently, the Github Actions based release is the formal release, so I will close this as done. There are still some questions about publishing the releases to native store, and how to automate updates, but I think those are best tracked in dedicated issues.
The installation process is hard for people who are not familiar with command line and conda. To make Paintera more accessible, we should try to create standalone packages that ideally ships Java as well.
Self contained packaging through the
javapackager
might be a good way to do that. I tried so far, with mixed success. For all cases, add these lines topom.xml
inside the<prpofiles></profiles>
tag:javafx-maven-plugin
Add these lines to
pom.xml
:Then run
[JavaFX Application Thread] INFO org.janelia.saalfeldlab.paintera.PainteraCommandLineArgs - Paintera version: null
Not sure if this package is still maintained (last commit in March of 2018) and is a package with the same artifactId but I do not know if and how they are related.
Build uber jar and then use
javapackager
Add these lines to
pom.xml
inside the<profiles></profiles>
tag:Then run
2.77.0
(probably resolvable with shading)If those issue can be resolved, then package it with
When packaged natively, there is also a weird delay also observed with
javafx-maven-plugin
.Build shaded jar and then use
javapackager
Add these lines to
pom.xml
inside the<profiles></profiles>
tag:Then run
No Proejct
:General Issues:
-Xmx60g
from the command line when using the native app.