Problem Compiling with groovy-eclipse-plugin

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Problem Compiling with groovy-eclipse-plugin

Marc von Renteln
Hello,

I have a problem compiling a maven plugin written in groovy. I know this is the domain of GMaven and no stubs will be created. I only want to compile the sources. No stub generation will be used. I used the default configuration from the project homepage:

<plugin>
    <artifactId>maven-compiler-plugin</artifactId>
    <version>2.3.1</version>
    <configuration>
      <compilerId>groovy-eclipse-compiler</compilerId>
      <verbose>true</verbose>
    </configuration>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.groovy</groupId>
        <artifactId>groovy-eclipse-compiler</artifactId>
        <version>2.5.2-01</version>
      </dependency>
    </dependencies>
  </plugin>

Even if I use <packaging>jar</packaging> the console output states that no sources are found that could be compiled:


[INFO] --- maven-compiler-plugin:2.3.1:compile (default-compile) @ hello-groovy-maven-plugin ---
[INFO] No sources to compile


If I use the maven-buildhelper-plugin configuration stated as workaround for 2.5.1-1 and earlier the sources are found and compiled correctly.

It seems like this bug is not solved in 2.5.2-01 or do I miss something?

The problem with the workaround is that the plugin descriptor generator then finds two annotated classes (because the same build path was added twice) and fails with an error that two exact identical classes can not be generated...

Regards
 -- Marc
Reply | Threaded
Open this post in threaded view
|

Re: Problem Compiling with groovy-eclipse-plugin

Andrew Eisenberg
Seems like you have hit this bug:
https://jira.codehaus.org/browse/GRECLIPSE-1221

The bug report describes a few workarounds you can try.  Let me know
if this works for you.

On Mon, Dec 12, 2011 at 5:11 AM, Marc von Renteln <[hidden email]> wrote:

> Hello,
>
> I have a problem compiling a maven plugin written in groovy. I know this is
> the domain of GMaven and no stubs will be created. I only want to compile
> the sources. No stub generation will be used. I used the default
> configuration from the project homepage:
>
> <plugin>
>     <artifactId>maven-compiler-plugin</artifactId>
>     <version>2.3.1</version>
>     <configuration>
>       <compilerId>groovy-eclipse-compiler</compilerId>
>       <verbose>true</verbose>
>     </configuration>
>     <dependencies>
>       <dependency>
>         <groupId>org.codehaus.groovy</groupId>
>         <artifactId>groovy-eclipse-compiler</artifactId>
>         <version>2.5.2-01</version>
>       </dependency>
>     </dependencies>
>   </plugin>
>
>
> Even if I use <packaging>jar</packaging> the console output states that no
> sources are found that could be compiled:
>
>
> [INFO] --- maven-compiler-plugin:2.3.1:compile (default-compile) @
> hello-groovy-maven-plugin ---
> [INFO] No sources to compile
>
>
> If I use the maven-buildhelper-plugin configuration stated as workaround for
> 2.5.1-1 and earlier the sources are found and compiled correctly.
>
> It seems like this bug is not solved in 2.5.2-01 or do I miss something?
>
> The problem with the workaround is that the plugin descriptor generator then
> finds two annotated classes (because the same build path was added twice)
> and fails with an error that two exact identical classes can not be
> generated...
>
> Regards
>  -- Marc

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email