Configure jpackage to launch JVM with cwd set to Contents/Resources

This commit is contained in:
Edwin Jakobs
2022-12-19 21:33:10 +01:00
parent 63f10ce2bb
commit 4631eced38

View File

@@ -192,7 +192,10 @@ runtime {
jpackage { jpackage {
imageName = "openrndr-application" imageName = "openrndr-application"
skipInstaller = true skipInstaller = true
if (OperatingSystem.current() == OperatingSystem.MAC_OS) jvmArgs.add("-XstartOnFirstThread") if (OperatingSystem.current() == OperatingSystem.MAC_OS) {
jvmArgs.add("-XstartOnFirstThread")
jvmArgs.add("-Duser.dir=${"$"}APPDIR/../Resources")
}
} }
options.set(listOf("--strip-debug", "--compress", "1", "--no-header-files", "--no-man-pages")) options.set(listOf("--strip-debug", "--compress", "1", "--no-header-files", "--no-man-pages"))
modules.set(listOf("jdk.unsupported", "java.management")) modules.set(listOf("jdk.unsupported", "java.management"))