build: improve launch4j parameters
This commit is contained in:
@@ -4,7 +4,7 @@
|
|||||||
<module name="jadx.jadx-gui.main"/>
|
<module name="jadx.jadx-gui.main"/>
|
||||||
<option name="PROGRAM_PARAMETERS" value="-v"/>
|
<option name="PROGRAM_PARAMETERS" value="-v"/>
|
||||||
<option name="VM_PARAMETERS"
|
<option name="VM_PARAMETERS"
|
||||||
value="-Xms128M -XX:MaxRAMPercentage=70.0 -Dawt.useSystemAAFontSettings=lcd -Dswing.aatext=true -Djava.util.Arrays.useLegacyMergeSort=true -Djdk.util.zip.disableZip64ExtraFieldValidation=true -XX:+IgnoreUnrecognizedVMOptions --add-opens=java.base/java.lang=ALL-UNNAMED --enable-native-access=ALL-UNNAMED -Dsun.java2d.noddraw=true -Dsun.java2d.d3d=false -Dsun.java2d.ddforcevram=true -Dsun.java2d.ddblit=false -Dswing.useflipBufferStrategy=True"/>
|
value="-Xms128M -XX:MaxRAMPercentage=70.0 -Dawt.useSystemAAFontSettings=lcd -Dswing.aatext=true -Djava.util.Arrays.useLegacyMergeSort=true -Djdk.util.zip.disableZip64ExtraFieldValidation=true -XX:+IgnoreUnrecognizedVMOptions --add-opens=java.base/java.lang=ALL-UNNAMED --enable-native-access=ALL-UNNAMED -Dsun.java2d.noddraw=true -Dsun.java2d.d3d=false -Dsun.java2d.ddforcevram=true -Dsun.java2d.ddblit=false -Dswing.useflipBufferStrategy=true"/>
|
||||||
<method v="2">
|
<method v="2">
|
||||||
<option name="Make" enabled="true"/>
|
<option name="Make" enabled="true"/>
|
||||||
</method>
|
</method>
|
||||||
|
|||||||
@@ -80,7 +80,7 @@ application {
|
|||||||
"-Dsun.java2d.d3d=false",
|
"-Dsun.java2d.d3d=false",
|
||||||
"-Dsun.java2d.ddforcevram=true",
|
"-Dsun.java2d.ddforcevram=true",
|
||||||
"-Dsun.java2d.ddblit=false",
|
"-Dsun.java2d.ddblit=false",
|
||||||
"-Dswing.useflipBufferStrategy=True",
|
"-Dswing.useflipBufferStrategy=true",
|
||||||
)
|
)
|
||||||
applicationDistribution.from("$rootDir") {
|
applicationDistribution.from("$rootDir") {
|
||||||
include("README.md")
|
include("README.md")
|
||||||
@@ -134,16 +134,28 @@ launch4j {
|
|||||||
dontWrapJar.set(true)
|
dontWrapJar.set(true)
|
||||||
icon.set("$projectDir/src/main/resources/logos/jadx-logo.ico")
|
icon.set("$projectDir/src/main/resources/logos/jadx-logo.ico")
|
||||||
outfile.set("jadx-gui-$jadxVersion.exe")
|
outfile.set("jadx-gui-$jadxVersion.exe")
|
||||||
|
version.set(jadxVersion)
|
||||||
copyright.set("Skylot")
|
copyright.set("Skylot")
|
||||||
windowTitle.set("jadx")
|
windowTitle.set("jadx")
|
||||||
companyName.set("jadx")
|
companyName.set("jadx")
|
||||||
jreMinVersion.set("11")
|
jreMinVersion.set("11")
|
||||||
chdir.set("")
|
jvmOptions.set(escapeJVMOptions())
|
||||||
jvmOptions.set(application.applicationDefaultJvmArgs.toSet())
|
|
||||||
requires64Bit.set(true)
|
requires64Bit.set(true)
|
||||||
downloadUrl.set("https://www.oracle.com/java/technologies/downloads/#jdk21-windows")
|
downloadUrl.set("https://www.oracle.com/java/technologies/downloads/#jdk21-windows")
|
||||||
|
supportUrl.set("https://github.com/skylot/jadx")
|
||||||
|
|
||||||
bundledJrePath.set(if (project.hasProperty("bundleJRE")) "%EXEDIR%/jre" else "%JAVA_HOME%")
|
bundledJrePath.set(if (project.hasProperty("bundleJRE")) "%EXEDIR%/jre" else "%JAVA_HOME%")
|
||||||
classpath.set(tasks.getByName("shadowJar").outputs.files.map { "%EXEDIR%/lib/${it.name}" }.toSortedSet())
|
classpath.set(tasks.getByName("shadowJar").outputs.files.map { "%EXEDIR%/lib/${it.name}" }.sorted().toList())
|
||||||
|
println("Launch4J classpath: ${classpath.get()}")
|
||||||
|
|
||||||
|
chdir.set("") // don't change current dir
|
||||||
|
libraryDir.set("") // don't add any libs
|
||||||
|
}
|
||||||
|
|
||||||
|
fun escapeJVMOptions(): List<String> {
|
||||||
|
return application.applicationDefaultJvmArgs
|
||||||
|
.toList()
|
||||||
|
.map { if (it.startsWith("-D")) "\"$it\"" else it }
|
||||||
}
|
}
|
||||||
|
|
||||||
runtime {
|
runtime {
|
||||||
|
|||||||
Reference in New Issue
Block a user