mirror of
https://github.com/processing/processing4.git
synced 2026-01-28 19:01:08 +01:00
work on quoting of java.ext.dirs (#4623)
This commit is contained in:
@@ -956,13 +956,13 @@ public class JavaBuild {
|
||||
if (embedJava) {
|
||||
// if people don't embed Java, it might be a mess, but what can we do?
|
||||
if (exportPlatform == PConstants.MACOSX) {
|
||||
runOptions.append("-Djava.ext.dirs=$APP_ROOT/Contents/PlugIns/jdk" +
|
||||
runOptions.append("-Djava.ext.dirs=\"$APP_ROOT/Contents/PlugIns/jdk" +
|
||||
PApplet.javaVersionName +
|
||||
".jdk/Contents/Home/jre/lib/ext");
|
||||
".jdk/Contents/Home/jre/lib/ext\"");
|
||||
} else if (exportPlatform == PConstants.WINDOWS) {
|
||||
runOptions.append("-Djava.ext.dirs=%EXEDIR%/java/lib/ext");
|
||||
runOptions.append("-Djava.ext.dirs=\"%EXEDIR%/java/lib/ext\"");
|
||||
} else if (exportPlatform == PConstants.LINUX) {
|
||||
runOptions.append("-Djava.ext.dirs=$APPDIR/java/lib/ext");
|
||||
runOptions.append("-Djava.ext.dirs=\"$APPDIR/java/lib/ext\"");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -266,13 +266,25 @@ public class Runner implements MessageConsumer {
|
||||
}
|
||||
}
|
||||
|
||||
// params.add("-Djava.ext.dirs=nuffing");
|
||||
|
||||
if (Preferences.getBoolean("run.options.memory")) {
|
||||
params.append("-Xms" + Preferences.get("run.options.memory.initial") + "m");
|
||||
params.append("-Xmx" + Preferences.get("run.options.memory.maximum") + "m");
|
||||
}
|
||||
|
||||
// Surprised this wasn't here before; added for 3.2.1
|
||||
params.append("-Djna.nosys=true");
|
||||
|
||||
// Added for 3.2.1, was still using the default ext.dirs in the PDE
|
||||
try {
|
||||
String extPath =
|
||||
new File(Platform.getJavaHome(), "lib/ext").getCanonicalPath();
|
||||
// quoting this on OS X causes it to fail
|
||||
//params.append("-Djava.ext.dirs=\"" + extPath + "\"");
|
||||
params.append("-Djava.ext.dirs=" + extPath);
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
if (Platform.isMacOS()) {
|
||||
params.append("-Xdock:name=" + build.getSketchClassName());
|
||||
// params.add("-Dcom.apple.mrj.application.apple.menu.about.name=" +
|
||||
|
||||
Reference in New Issue
Block a user