Project

General

Profile

Actions

Feature #13083

closed

Enable gate builds with OpenJDK 11

Added by Peter Tribble over 3 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
-
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:
External Bug:

Description

The Java world is moving on, and JDK8 is getting rather old.

It would be beneficial to support gate builds with a newer version in addition to 8: JDK 11, as an LTS release, would appear to be the ideal target.

Queries haven't yet turned up anyone using a version of Java older than 8, so it seems unnecessary to try and support older versions as well.

Actions #1

Updated by Electric Monk over 3 years ago

  • Gerrit CR set to 877
Actions #2

Updated by Joshua M. Clulow over 3 years ago

Looking at the packages available in OpenIndiana, it seems that they only currently have OpenJDK 7 & 8 under:

https://github.com/OpenIndiana/oi-userland/tree/oi/hipster/components/runtime/

On the other hand, OmniOS has OpenJDK 11 here:

https://github.com/omniosorg/omnios-build/tree/master/build/openjdk11

I believe you've been maintaining JDK builds for a while, as well, Peter. Do you have a best set of patches, or some sense of what we might do to harmonise JDK availability throughout the distributions a bit more, as we have done with GCC?

Actions #3

Updated by Peter Tribble over 3 years ago

Joshua M. Clulow wrote:

Looking at the packages available in OpenIndiana, it seems that they only currently have OpenJDK 7 & 8 under:

https://github.com/OpenIndiana/oi-userland/tree/oi/hipster/components/runtime/

Yes, but 8 is the default.

On the other hand, OmniOS has OpenJDK 11 here:

https://github.com/omniosorg/omnios-build/tree/master/build/openjdk11

Yes, and OmniOS gave me a little nudge to get this done.

So distributions are at least at 8; some have 11 as well.

And I queried whether anyone was still using 7.

https://illumos.topicbox.com/groups/developer/Td5ea8857a63bae25-M441951b6ad52a537eaa79791/what-java-do-people-use-to-build-the-gate

I believe you've been maintaining JDK builds for a while, as well, Peter. Do you have a best set of patches, or some sense of what we might do to harmonise JDK availability throughout the distributions a bit more, as we have done with GCC?

I believe OmniOS used my patches as is. But yes, it might make sense to split the primary copy out into a separate repo.

Actions #4

Updated by Andy Fiddaman over 3 years ago

FWIW - the OmniOS OpenJDK11 package is directly using the patches that Peter kindly provided in https://illumos.topicbox.com/groups/developer/Tee40bb1913d3a634-M7fb362f818baad265bd3ec96/patches-for-openjdk-with-gcc
and the original bootstrap was done with the provided artefacts.

Actions #5

Updated by Peter Tribble about 3 years ago

In Java 11, javah is no more. It is claimed that 'javac -h' is the replacement, but this isn't quite true, as it does not allow either the specification of the output file name nor does it merge the header declarations into a single file. The simplest approach is then to check the Java 8 generated headers into the gate, rather than create them anew every build. I have, however, verified that the actual header contents that Java 11 gives are equivalent.

With Java 8, the build should be unchanged - and wsdiff shows that the jni shared objects created are identical, as they should be.

Actions #6

Updated by Electric Monk about 3 years ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100

git commit 51396a8ee7fb52fe0ab33bfe7b4f495ad431904a

commit  51396a8ee7fb52fe0ab33bfe7b4f495ad431904a
Author: Peter Tribble <peter.tribble@gmail.com>
Date:   2020-09-18T18:31:28.000Z

    13083 Enable gate builds with OpenJDK 11
    Reviewed by: Richard Lowe <richlowe@richlowe.net>
    Reviewed by: Andy Fiddaman <andy@omniosce.org>
    Reviewed by: Toomas Soome <tsoome@me.com>
    Approved by: Joshua M. Clulow <josh@sysmgr.org>

Actions

Also available in: Atom PDF