Add option to FindJava to select between 32- and 64-bit version on Windows
Currently FindJava
requests the Windows registry to find the Java installation. Depending on the selected generator the request returns the 32-bit or the 64-bit Java version.
I would like to be able to select the returned Java version manually with an additional option.
Rationale
In my case I use Java to generate some code (Eclipse Modeling Framework). The generator sometimes requires more resources than 32-bit Java can supply and a 64-bit Java would produce the same result.
Using the JAVA_HOME
option of FindJava
is not sufficient, because the build system is used by many developers on different machines, which may have different paths to the Java installation.
Related issues
#12056: disable registry request in FindJava
(might be solved together with this issue)
#17460 (closed): shows how to make a registry request explicit for 32-bit or 64-bit in FindMatlab
#19473 (closed): problems with registry access in FindPython
when cross-compiling