Commit abdd4077 authored by Dmitriy.Panov's avatar Dmitriy.Panov Committed by Dmitriy Panov
Browse files

IDEA-CR-44105: JRE-1215: jbrsdk-11/jbr-11 customization for IDEA EDU

(cherry picked from commit 6e48f42d)
parent ab872409
Showing with 9 additions and 5 deletions
+9 -5
......@@ -7,7 +7,8 @@ task setupJbre()
def targetOs = System.getProperty("intellij.build.target.os", "all")
def jreVersion = System.getProperty("intellij.build.bundled.jre.version", "8").toInteger()
def jreBuild = System.getProperty("intellij.build.bundled.jre.build", jdkBuild)
createJbreTasks(jreBuild, jreVersion, targetOs)
def jrePrefix = System.getProperty("intellij.build.bundled.jre.prefix")
createJbreTasks(jreBuild, jreVersion, targetOs, jrePrefix)
if (System.getProperty('intellij.build.bundle.second.jre', 'false').toBoolean()) {
def secondJreBuild = System.getProperty("intellij.build.bundled.second.jre.build", secondJreBuild)
......@@ -39,9 +40,9 @@ static def splitJreBuild(String jreBuild, String version) {
}
}
def createJbreTasks(String defaultBuild, int version, String targetOs) {
def createJbreTasks(String defaultBuild, int version, String targetOs, String prefix = null) {
def isModular = version >= 9
def prefix = isModular ? 'jbr-' : 'jbrx-'
if (prefix == null) prefix = isModular ? 'jbr-' : 'jbrx-'
jrePlatformsToDownload(targetOs).each { platform ->
archToDownload(platform, !isModular).each { arch ->
def jreBuild = project.ext.has("jreBuild_$platform") ? project.ext["jreBuild_$platform"] : defaultBuild
......
......@@ -212,8 +212,11 @@ class BundledJreManager {
def jreBuild = getExpectedJreBuild(osName)
String suffix = jreArchiveSuffix(jreBuild, buildContext.options.bundledJreVersion.toString(), arch, osName)
String prefix = buildContext.isBundledJreModular() ? vendor.jreNamePrefix :
buildContext.productProperties.toolsJarRequired ? vendor.jreWithToolsJarNamePrefix : vendor.jreNamePrefix
String prefix = System.getProperty("intellij.build.bundled.jre.prefix")
if (prefix == null) {
prefix = buildContext.isBundledJreModular() ? vendor.jreNamePrefix :
buildContext.productProperties.toolsJarRequired ? vendor.jreWithToolsJarNamePrefix : vendor.jreNamePrefix
}
def jreArchive = new File(jreDir, "$prefix$suffix")
if (!jreArchive.file || !jreArchive.exists()) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment