openjdk24: init at 24+36

This commit is contained in:
Tom van Dijk 2025-05-01 11:24:20 +02:00
parent cd2ccdd6aa
commit 71dd692741
No known key found for this signature in database
GPG key ID: 7A984C8207ADBA51
6 changed files with 77 additions and 6 deletions

View file

@ -0,0 +1,13 @@
--- a/src/hotspot/os/linux/os_linux.cpp 2025-04-08 14:43:06.765198522 +0200
+++ b/src/hotspot/os/linux/os_linux.cpp 2025-04-08 14:43:27.890301990 +0200
@@ -2758,9 +2758,7 @@
assert(ret, "cannot locate libjvm");
char *rp = nullptr;
if (ret && dli_fname[0] != '\0') {
- rp = os::realpath(dli_fname, buf, buflen);
- }
- if (rp == nullptr) {
+ snprintf(buf, buflen, "%s", dli_fname);
return;
}

View file

@ -0,0 +1,30 @@
--- a/src/java.base/share/classes/sun/security/ssl/TrustStoreManager.java 2017-06-26 21:48:25.000000000 -0400
+++ b/src/java.base/share/classes/sun/security/ssl/TrustStoreManager.java 2017-07-05 20:45:57.491295030 -0400
@@ -71,6 +71,7 @@
*
* The preference of the default trusted KeyStore is:
* javax.net.ssl.trustStore
+ * system environment variable JAVAX_NET_SSL_TRUSTSTORE
* jssecacerts
* cacerts
*/
@@ -125,7 +126,8 @@
static TrustStoreDescriptor run() {
// Get the system properties for trust store.
String storePropName = System.getProperty(
- "javax.net.ssl.trustStore", jsseDefaultStore);
+ "javax.net.ssl.trustStore",
+ System.getenv("JAVAX_NET_SSL_TRUSTSTORE"));
String storePropType = System.getProperty(
"javax.net.ssl.trustStoreType",
KeyStore.getDefaultType());
@@ -137,6 +139,9 @@
String temporaryName = "";
File temporaryFile = null;
long temporaryTime = 0L;
+ if (storePropName == null) {
+ storePropName = jsseDefaultStore;
+ }
if (!"NONE".equals(storePropName)) {
String[] fileNames =
new String[] {storePropName, defaultStore};

View file

@ -0,0 +1,6 @@
{
"hash": "sha256-ogWq6oLyZzzvxGTqEEoPMXdtfbobUyXcC5bXXxBxfuo=",
"owner": "openjdk",
"repo": "jdk24u",
"rev": "refs/tags/jdk-24+36"
}

View file

@ -13,6 +13,7 @@
lndir,
unzip,
ensureNewerSourcesForZipFilesHook,
pandoc,
cpio,
file,
@ -76,6 +77,7 @@
temurin-bin-17,
temurin-bin-21,
temurin-bin-23,
temurin-bin-24,
jdk-bootstrap ?
{
"8" = temurin-bin-8.__spliced.buildBuild or temurin-bin-8;
@ -83,6 +85,7 @@
"17" = temurin-bin-17.__spliced.buildBuild or temurin-bin-17;
"21" = temurin-bin-21.__spliced.buildBuild or temurin-bin-21;
"23" = temurin-bin-23.__spliced.buildBuild or temurin-bin-23;
"24" = temurin-bin-24.__spliced.buildBuild or temurin-bin-24;
}
.${featureVersion},
}:
@ -98,6 +101,7 @@ let
atLeast17 = lib.versionAtLeast featureVersion "17";
atLeast21 = lib.versionAtLeast featureVersion "21";
atLeast23 = lib.versionAtLeast featureVersion "23";
atLeast24 = lib.versionAtLeast featureVersion "24";
tagPrefix = if atLeast11 then "jdk-" else "jdk";
version = lib.removePrefix "refs/tags/${tagPrefix}" source.src.rev;
@ -143,7 +147,9 @@ stdenv.mkDerivation (finalAttrs: {
patches =
[
(
if atLeast21 then
if atLeast24 then
./24/patches/fix-java-home-jdk24.patch
else if atLeast21 then
./21/patches/fix-java-home-jdk21.patch
else if atLeast11 then
./11/patches/fix-java-home-jdk10.patch
@ -151,7 +157,9 @@ stdenv.mkDerivation (finalAttrs: {
./8/patches/fix-java-home-jdk8.patch
)
(
if atLeast11 then
if atLeast24 then
./24/patches/read-truststore-from-env-jdk24.patch
else if atLeast11 then
./11/patches/read-truststore-from-env-jdk10.patch
else
./8/patches/read-truststore-from-env-jdk8.patch
@ -254,6 +262,9 @@ stdenv.mkDerivation (finalAttrs: {
]
++ lib.optionals atLeast21 [
ensureNewerSourcesForZipFilesHook
]
++ lib.optionals atLeast24 [
pandoc
];
buildInputs =
@ -475,10 +486,15 @@ stdenv.mkDerivation (finalAttrs: {
doInstallCheck = atLeast23;
${if atLeast17 then "postPatch" else null} = ''
chmod +x configure
patchShebangs --build configure
'';
${if atLeast17 then "postPatch" else null} =
''
chmod +x configure
patchShebangs --build configure
''
+ lib.optionalString atLeast24 ''
chmod +x make/scripts/*.{template,sh,pl}
patchShebangs --build make/scripts
'';
${if !atLeast17 then "preConfigure" else null} =
''

View file

@ -6061,6 +6061,11 @@ with pkgs;
jdk23 = openjdk23;
jdk23_headless = openjdk23_headless;
openjdk24 = javaPackages.compiler.openjdk24;
openjdk24_headless = javaPackages.compiler.openjdk24.headless;
jdk24 = openjdk24;
jdk24_headless = openjdk24_headless;
# default JDK
jdk = jdk21;
jdk_headless = jdk21_headless;

View file

@ -49,6 +49,7 @@ with pkgs;
openjdk17 = mkOpenjdk "17";
openjdk21 = mkOpenjdk "21";
openjdk23 = mkOpenjdk "23";
openjdk24 = mkOpenjdk "24";
# Legacy aliases
openjdk8-bootstrap = temurin-bin.jdk-8;