void () { final Set<JpsSdk<?>> sdks = myCompileContext.getProjectDescriptor().getProjectJavaSdks(); JpsSdk javaSdk = null; for (JpsSdk<?> sdk : sdks) { final JpsSdkType<? extends JpsElement> sdkType = sdk.getSdkType(); if (sdkType instanceof JpsJavaSdkType && JpsJavaSdkType.getJavaVersion(sdk) >= 14) { javaSdk = sdk; break; } } if (javaSdk == null) { error(JavaFXJpsBundle.message("java.version.14.or.higher.is.required.to.build.platform.specific.package.using.jpackage")); return; } final String homePath = javaSdk.getHomePath(); final String jpackagePath = homePath + File.separatorChar + "bin" + File.separatorChar + "jpackage"; final String archiveName = getArchiveName(); if (archiveName == null) { error(JavaFXJpsBundle.message("no.archive.found")); return; } List<String> commands = new ArrayList<>(); commands.add(jpackagePath); final String outputPath = myArtifact.getOutputFilePath(); if (myProperties.verbose) { commands.add("--verbose"); } addOption(commands, "--input", outputPath); addOption(commands, "--main-jar", archiveName); addOption(commands, "--name", myArtifact.getName()); addOption(commands, "--dest", outputPath); addOption(commands, "--app-version", myProperties.version); addOption(commands, "--copyright", myProperties.copyright); addOption(commands, "--description", myProperties.description); addOption(commands, "--vendor", myProperties.vendor); //addOption(commands, "--icon", myProperties.icon); //addOption(commands, "--arguments", myProperties.appArguments); //addOption(commands, "--java-options", myProperties.javaArguments); addOption(commands, "--main-class", myProperties.mainClass); final int errorCode = startProcess(commands); if (errorCode != 0) { error(JavaFXJpsBundle.message("jpackage.task.has.failed")); } }