Installed the current nightly "Windows without JRE" built on 21st May.
This machine doesn't have any old JRE installed. However, it has the JDK 12.0.1 installed. I can use it to run OmegaT.jar, but when trying to run OmegaT.exe it tells me there's no JRE and I'd have to download it.
JAVA_HOME environment variable points to the correct folder and I've added /bin to PATH, which didn't help either.
Are you using an OpenJDK? If so , this is probably a bug in Launch4J (see [launch4j:bugs:#197]).
Launch4j executables don't rely on
%JAVA_HOME%to detect the installed JDK but use Regsitry Keys instead. Since OpenJDK does not add any Registry Keys, it won't detect the installed JRE.Although it seems we could use the following configuration to avoid this problem, this would mean we would have two different
Omegat.exeto create (one with the bundled JRE, one without)Related
Launch4j Executable Wrapper: Bugs:
#197I actually didn't know about the Oracle published JDK's term changes, so had their JDK installed, then installed the OpenJDK version. Didn't detect either version.
Launch4J bug has been fixed and closed.
Can we close here?
@mliebisch Could you give us a feedback? Has it already fixed?
Switched back to using the version coming with the runtime long time ago, since it's just easier to maintain (and we no longer use anything else based on Java). I'd say it's safe to close this, especially considering it was (is?) more a Launch4J kind of issue and Bug 192 mentioned above has been fixed, too.
Quick and easy workaround for those running into the same issue (and wanting to avoid screwing around with Windows Registry and/or batch files):
Right click the Start menu, click Command Prompt (Administrator) and use the following command:
64 bit Windows:
If you have
JAVA_HOMEset, you can also replace the second path:32 bit Windows:
If this fails, since the
jresub folder exists already, just delete it first.Launch4J will pick up the (faked) sub folder and use the installed JDK as intended.