Skip to content

Commit c2c9a14

Browse files
committed
U sets jspawnhelper permissions when jre already exists (only linux and macos)
1 parent 85a9140 commit c2c9a14

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/main/java/io/github/fvarrui/javapackager/packagers/BundleJre.java

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,17 @@ protected File doApply(Packager packager) throws Exception {
6969

7070
// copies JRE folder to bundle
7171
FileUtils.copyFolderContentToFolder(specificJreFolder, destinationFolder);
72-
72+
7373
// sets execution permissions on executables in jre
7474
File binFolder = new File(destinationFolder, "bin");
7575
Arrays.asList(binFolder.listFiles()).forEach(f -> f.setExecutable(true, false));
76+
77+
// sets execution permissions on jspawnhelper in jre
78+
File libFolder = new File(destinationFolder, "lib");
79+
File jshFile = new File(libFolder, "jspawnhelper");
80+
if (jshFile.exists()) {
81+
jshFile.setExecutable(true, false);
82+
}
7683

7784
} else if (JavaUtils.getJavaMajorVersion() <= 8) {
7885

0 commit comments

Comments
 (0)