Skip to content

Commit 182c09a

Browse files
committed
disable ext.dirs on Linux export and set jna.nosys as well
1 parent 1ad18a4 commit 182c09a

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

java/src/processing/mode/java/JavaBuild.java

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1093,18 +1093,21 @@ protected boolean exportApplication(File destFolder,
10931093
// Do the newlines explicitly so that Windows CRLF
10941094
// isn't used when exporting for Unix.
10951095
pw.print("#!/bin/sh\n\n");
1096-
//ps.print("APPDIR=`dirname $0`\n");
1097-
pw.print("APPDIR=$(readlink -f \"$0\")\n"); //Allow Symlinks
1098-
pw.print("APPDIR=$(dirname \"$APPDIR\")\n"); // more posix compliant
1096+
pw.print("APPDIR=$(readlink -f \"$0\")\n"); // allow symlinks
1097+
pw.print("APPDIR=$(dirname \"$APPDIR\")\n"); // more POSIX compliant
1098+
10991099
// another fix for bug #234, LD_LIBRARY_PATH ignored on some platforms
11001100
//ps.print("LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$APPDIR\n");
1101+
11011102
if (embedJava) {
11021103
// https://github.com/processing/processing/issues/2349
11031104
pw.print("$APPDIR/java/bin/");
11041105
}
11051106
String runOptionsStr = runOptions.join(" ");
11061107
pw.print("java " + runOptionsStr +
11071108
" -Djava.library.path=\"$APPDIR:$APPDIR/lib\"" +
1109+
" -Djava.ext.dirs=\"$APPDIR/java/lib/ext\"" +
1110+
" -Djna.nosys=true" +
11081111
" -cp \"" + exportClassPath + "\"" +
11091112
" " + sketch.getName() + " \"$@\"\n");
11101113

todo.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ X https://github.com/processing/processing/issues/4623
66
_ might be ext.dirs trouble with spaces in path names?
77
_ or the backwards slashes?
88
X fixes for Python Mode crashing on startup
9+
X disable ext.dirs on Linux export and set jna.nosys as well
910
_ JavaInputHandler not registering
1011

1112
_ library compilations handled oddly

0 commit comments

Comments
 (0)