From: acolyer Date: Fri, 20 Jan 2006 12:21:11 +0000 (+0000) Subject: support for ... when forking (needed by profiling scripts) X-Git-Tag: POST_MEMORY_CHANGES~166 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=7a9a69e5c82ee9ee59f94cc68d69a3c25c36b5ff;p=aspectj.git support for ... when forking (needed by profiling scripts) --- diff --git a/taskdefs/src/org/aspectj/tools/ant/taskdefs/AjcTask.java b/taskdefs/src/org/aspectj/tools/ant/taskdefs/AjcTask.java index 44de9a318..27fc98cbc 100644 --- a/taskdefs/src/org/aspectj/tools/ant/taskdefs/AjcTask.java +++ b/taskdefs/src/org/aspectj/tools/ant/taskdefs/AjcTask.java @@ -400,7 +400,10 @@ public class AjcTask extends MatchingTask { /** true if -XincrementalFile (i.e, setTagFile)*/ private boolean inIncrementalFileMode; - + + /** used when forking */ + private CommandlineJava javaCmd = new CommandlineJava(); + // also note MatchingTask grabs source files... public AjcTask() { @@ -443,6 +446,7 @@ public class AjcTask extends MatchingTask { verbose = false; xweaveDir = null; xdoneSignal = null; + javaCmd = new CommandlineJava(); } protected void ignore(String ignored) { @@ -634,6 +638,11 @@ public class AjcTask extends MatchingTask { public void setMaxmem(String maxMem) { this.maxMem = maxMem; } + + /** support for nested <jvmarg> elements */ + public Commandline.Argument createJvmarg() { + return this.javaCmd.createVmArgument(); + } // ---------------- public void setTagFile(File file) { @@ -1315,7 +1324,6 @@ public class AjcTask extends MatchingTask { this.logger.warning("message holder ignored when forking: " + messageHolder.getClass().getName()); } - CommandlineJava javaCmd = new CommandlineJava(); javaCmd.setClassname(org.aspectj.tools.ajc.Main.class.getName()); final Path vmClasspath = javaCmd.createClasspath(getProject());