Browse Source

enable <javac>'s source attribute for jikes as well.

PR: 7002


git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@271934 13f79535-47bb-0310-9956-ffa450edef68
master
Stefan Bodewig 23 years ago
parent
commit
808b91716a
3 changed files with 16 additions and 3 deletions
  1. +2
    -0
      WHATSNEW
  2. +9
    -3
      docs/manual/CoreTasks/javac.html
  3. +5
    -0
      src/main/org/apache/tools/ant/taskdefs/compilers/Jikes.java

+ 2
- 0
WHATSNEW View File

@@ -232,6 +232,8 @@ Other changes:
to the standard Java 1.4 doclet. The element is ignored when not running to the standard Java 1.4 doclet. The element is ignored when not running
on Java 1.4. on Java 1.4.


* <java>'s source attribute is now enabled for jikes as well.

Changes from Ant 1.4 to Ant 1.4.1 Changes from Ant 1.4 to Ant 1.4.1
=========================================== ===========================================




+ 9
- 3
docs/manual/CoreTasks/javac.html View File

@@ -284,11 +284,17 @@ invoking the compiler.</p>
</tr> </tr>
<tr> <tr>
<td valign="top">source</td> <td valign="top">source</td>

<td valign="top">Value of the <code>-source</code> command-line <td valign="top">Value of the <code>-source</code> command-line
switch; will be ignored by all implementations except switch; will be ignored by all implementations except
<code>modern</code>. Legal values are <code>1.3</code> and
<code>1.4</code> &ndash; by default, no <code>-source</code> argument
will be used at all.</td>
<code>modern</code> and <code>jikes</code>.<br>
If you use this attribute together with <code>jikes</code>, you
must make sure that your version of jikes supports the
<code>-source</code> switch.<br>
Legal values are <code>1.3</code> and <code>1.4</code> &ndash; by
default, no <code>-source</code> argument will be used at
all.</td>

<td align="center" valign="top">No</td> <td align="center" valign="top">No</td>
</tr> </tr>
<tr> <tr>


+ 5
- 0
src/main/org/apache/tools/ant/taskdefs/compilers/Jikes.java View File

@@ -209,6 +209,11 @@ public class Jikes extends DefaultCompilerAdapter {
cmd.createArgument().setValue("+F"); cmd.createArgument().setValue("+F");
} }


if (attributes.getSource() != null) {
cmd.createArgument().setValue("-source");
cmd.createArgument().setValue(attributes.getSource());
}

addCurrentCompilerArgs(cmd); addCurrentCompilerArgs(cmd);


int firstFileName = cmd.size(); int firstFileName = cmd.size();


Loading…
Cancel
Save