maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rfscho...@apache.org
Subject svn commit: r1162905 - in /maven/plugins/trunk/maven-compiler-plugin/src: it/mcompiler-135/ it/mcompiler-135/src/ it/mcompiler-135/src/main/ it/mcompiler-135/src/main/java/ main/java/org/apache/maven/plugin/
Date Mon, 29 Aug 2011 17:19:51 GMT
Author: rfscholte
Date: Mon Aug 29 17:19:50 2011
New Revision: 1162905

URL: http://svn.apache.org/viewvc?rev=1162905&view=rev
Log:
Fix MCOMPILER-135: Passing multiple parameters to Java 6 annotation processors with javac
does not work

Added:
    maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/
    maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/invoker.properties
    maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/pom.xml
    maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/src/
    maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/src/main/
    maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/src/main/java/
    maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/src/main/java/MyClass.java
Modified:
    maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/AbstractCompilerMojo.java

Added: maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/invoker.properties
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/invoker.properties?rev=1162905&view=auto
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/invoker.properties (added)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/invoker.properties Mon
Aug 29 17:19:50 2011
@@ -0,0 +1,2 @@
+invoker.goals = clean compile
+invoker.java.version = 1.6+
\ No newline at end of file

Added: maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/pom.xml?rev=1162905&view=auto
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/pom.xml (added)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/pom.xml Mon Aug 29 17:19:50
2011
@@ -0,0 +1,27 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>org.apache.maven.plugins.compiler.it</groupId>
+  <artifactId>mcompiler-135</artifactId>
+  <version>1.0-SNAPSHOT</version>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-compiler-plugin</artifactId>
+        <version>@project.version@</version>
+        <configuration>
+          <fork>true</fork>
+          <source>1.6</source>
+          <target>1.6</target>
+            <compilerArguments>
+              <Averbose>true</Averbose>
+              <AaddResDir>src/main/webapp</AaddResDir>
+            </compilerArguments>
+        </configuration>
+      </plugin>
+    </plugins>
+
+  </build>
+</project>

Added: maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/src/main/java/MyClass.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/src/main/java/MyClass.java?rev=1162905&view=auto
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/src/main/java/MyClass.java
(added)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/mcompiler-135/src/main/java/MyClass.java
Mon Aug 29 17:19:50 2011
@@ -0,0 +1,4 @@
+public class MyClass
+{
+
+}

Modified: maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/AbstractCompilerMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/AbstractCompilerMojo.java?rev=1162905&r1=1162904&r2=1162905&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/AbstractCompilerMojo.java
(original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/AbstractCompilerMojo.java
Mon Aug 29 17:19:50 2011
@@ -452,7 +452,15 @@ public abstract class AbstractCompilerMo
                     {
                         key = "-" + key;
                     }
-                    cplrArgsCopy.put( key, value );
+
+                    if( key.startsWith( "-A" ) && StringUtils.isNotEmpty( value )
)
+                    {
+                        cplrArgsCopy.put( key + "=" + value, null );
+                    }
+                    else
+                    {
+                        cplrArgsCopy.put( key, value );
+                    }
                 }
             }
             if ( !StringUtils.isEmpty( effectiveCompilerArgument ) )



Mime
View raw message