FindJava: Update check to avoid accepting macOS stub 'java' as Java
Since commit dd378258 we try to avoid using the macOS
/usr/bin/java stub if no underlying implementation of Java is actually
installed. However, the message that
/usr/bin/java prints when there
is no Java available has changed since then. Update our check to also
look for the new message.
While at it, revise the way we suppress
Previously we set its cache entry to
but that would cause the same find-and-reject sequence to be followed
every time CMake runs in a build tree. Instead, use the approach used by
!4813 (merged) for
svn. Leave the cache entry alone and just set a normal variable of the same name to hide it.