提交 46aecdde 编写于 作者: S Skylot

build: bundle JRE with jadx-gui

上级 82d40995
......@@ -156,6 +156,16 @@ task dist(dependsOn: [pack, copyExe]) {
description = 'Build jadx distribution zip'
}
task distWin(type: Copy, dependsOn: 'jadx-gui:distWinWithJre') {
group 'jadx'
description = 'Copy bundle to build dir'
destinationDir buildDir
from(tasks.getByPath('jadx-gui:distWinWithJre').outputs) {
include '*.zip'
}
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
}
task samples(dependsOn: 'jadx-samples:samples') {
group 'jadx'
}
......
plugins {
id 'application'
id 'edu.sc.seis.launch4j' version '2.4.8'
id 'com.github.johnrengelman.shadow' version '6.0.0'
id 'edu.sc.seis.launch4j' version '2.4.9'
id 'com.github.johnrengelman.shadow' version '6.1.0'
id 'org.beryx.runtime' version '1.11.4'
}
dependencies {
......@@ -71,15 +72,47 @@ launch4j {
copyright = 'Skylot'
windowTitle = 'jadx'
companyName = 'jadx'
jreMinVersion = '1.8.0'
jreMinVersion = '11'
jvmOptions = ['-Dawt.useSystemAAFontSettings=lcd', '-Dswing.aatext=true', '-XX:+UseG1GC']
jreRuntimeBits = "64"
bundledJre64Bit = true
initialHeapPercent = 5
maxHeapSize = 4096
maxHeapPercent = 70
downloadUrl = 'https://adoptopenjdk.net/releases.html?variant=openjdk11&jvmVariant=hotspot#x64_win'
bundledJrePath = '%JAVA_HOME%'
downloadUrl = 'https://adoptopenjdk.net/releases.html?variant=openjdk14&jvmVariant=hotspot#x64_win'
// bundledJrePath = '%JAVA_HOME%'
bundledJrePath = '%EXEDIR%/jre' // TODO: merge java search paths
}
runtime {
addOptions('--strip-debug', '--compress', '2', '--no-header-files', '--no-man-pages')
addModules(
'java.desktop',
'java.naming',
'java.sql', // TODO: GSON register adapter for java.sql.Time
'java.xml',
)
jpackage {
imageOptions = ['--icon', "${projectDir}/src/main/resources/logos/jadx-logo.ico"]
skipInstaller = true
}
launcher{
noConsole = true
}
}
task distWinWithJre(type: Zip, dependsOn: ['runtime', 'createExe']) {
group 'jadx'
destinationDirectory = buildDir
archiveFileName = "jadx-gui-${jadxVersion}-with-jre-win.zip"
from(runtime.jreDir) {
include '**/*'
into 'jre'
}
from(createExe.outputs){
include '*.exe'
}
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
}
test {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册