From c2ec2a4af59a2da8521425387fc0483e85817186 Mon Sep 17 00:00:00 2001 From: phit <2097483+phit@users.noreply.github.com> Date: Mon, 9 Aug 2021 18:43:55 +0200 Subject: [PATCH] GH-3996 Detect Adoptium JDK's --- launcher/java/JavaUtils.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/launcher/java/JavaUtils.cpp b/launcher/java/JavaUtils.cpp index 4b231e6a..c00ee710 100644 --- a/launcher/java/JavaUtils.cpp +++ b/launcher/java/JavaUtils.cpp @@ -265,6 +265,12 @@ QList JavaUtils::FindJavaPaths() QList ADOPTOPENJDK64s = this->FindJavaFromRegistryKey( KEY_WOW64_64KEY, "SOFTWARE\\AdoptOpenJDK\\JDK", "Path", "\\hotspot\\MSI"); + // Adoptium (Eclipse) + QList ECLIPSEJDK32s = this->FindJavaFromRegistryKey( + KEY_WOW64_32KEY, "SOFTWARE\\Eclipse Foundation\\JDK", "Path", "\\hotspot\\MSI"); + QList ECLIPSEJDK64s = this->FindJavaFromRegistryKey( + KEY_WOW64_64KEY, "SOFTWARE\\Eclipse Foundation\\JDK", "Path", "\\hotspot\\MSI"); + // Microsoft QList MICROSOFTJDK64s = this->FindJavaFromRegistryKey( KEY_WOW64_64KEY, "SOFTWARE\\Microsoft\\JDK", "Path", "\\hotspot\\MSI"); @@ -291,6 +297,7 @@ QList JavaUtils::FindJavaPaths() java_candidates.append(JDK64s); java_candidates.append(NEWJDK64s); java_candidates.append(ADOPTOPENJDK64s); + java_candidates.append(ECLIPSEJDK64s); java_candidates.append(MICROSOFTJDK64s); java_candidates.append(ZULU64s); java_candidates.append(LIBERICA64s); @@ -304,6 +311,7 @@ QList JavaUtils::FindJavaPaths() java_candidates.append(JDK32s); java_candidates.append(NEWJDK32s); java_candidates.append(ADOPTOPENJDK32s); + java_candidates.append(ECLIPSEJDK32s); java_candidates.append(ZULU32s); java_candidates.append(LIBERICA32s);