groovy

Groovyc ant task cannot be found when using embeddable/groovy-all*.jar in ant build script

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.1-beta-3
  • Fix Version/s: 1.1-rc-2
  • Component/s: Ant integration
  • Labels:
    None
  • Environment:
    Windows XP, Ant 1.7, JDK1.5_R12
  • Number of attachments :
    2

Description

Ant fails to find Groovyc class when using the groovy-all*.jar. However if the classpath is changed to point to GROOVY_HOME\lib it works fine. I have attached the build.xml file and fibonacci.groovy for example.

Here is the error ....
C:\Z>ant
Buildfile: build.xml

BUILD FAILED
C:\Z\build.xml:10: taskdef A class needed by class org.codehaus.groovy.ant.Groovyc cannot be found: org/apache/commons/cli/ParseException

Total time: 0 seconds
C:\Z>

  1. build.xml
    26/Sep/07 3:47 PM
    0.8 kB
    Gig Patel
  2. Fibonacci.groovy
    26/Sep/07 3:47 PM
    0.1 kB
    Gig Patel

Activity

Hide
Paul King added a comment -

This isn't a bug but current behaviour. The all jar doesn't include the commons-cli which you need. You may ask for a feature enhancement if you want a jar merging commons-cli.

Show
Paul King added a comment - This isn't a bug but current behaviour. The all jar doesn't include the commons-cli which you need. You may ask for a feature enhancement if you want a jar merging commons-cli.
Hide
Stefan Saring added a comment -

Hi,

I have the same problem. It's really annoying to include the commons-cli.jar everytime just for the groovyc Ant task. The idea of the groovy-all-1.1-rc-1.jar is to include all dependencies. It contains the groovyc Ant task but not the required commons-cli.jar. It would be great when it could be included, hopefully in the 1.1 release.

Thanks,
Stefan

Show
Stefan Saring added a comment - Hi, I have the same problem. It's really annoying to include the commons-cli.jar everytime just for the groovyc Ant task. The idea of the groovy-all-1.1-rc-1.jar is to include all dependencies. It contains the groovyc Ant task but not the required commons-cli.jar. It would be great when it could be included, hopefully in the 1.1 release. Thanks, Stefan
Hide
Guillaume Laforge added a comment -

We should probably include commons-cli in the all jar.

Show
Guillaume Laforge added a comment - We should probably include commons-cli in the all jar.
Hide
Paul King added a comment -

Fixed in head

Show
Paul King added a comment - Fixed in head
Hide
Russel Winder added a comment -

This change has broken Grails. cf. GROOVY-2295. The problem is to do with Gant and how to compile it for use with groovy-all instead of groovy + commons-cli.

Show
Russel Winder added a comment - This change has broken Grails. cf. GROOVY-2295. The problem is to do with Gant and how to compile it for use with groovy-all instead of groovy + commons-cli.
Hide
Paul King added a comment -

A fix has been proposed for the issue Russel mentioned which should mean the solution to this issue will not be impacted.

Show
Paul King added a comment - A fix has been proposed for the issue Russel mentioned which should mean the solution to this issue will not be impacted.
Hide
Russel Winder added a comment -

Which is why I didn't reopen the issue

I put the marker here more to ensure we had a proper connection between issues for documentation purposes.

Show
Russel Winder added a comment - Which is why I didn't reopen the issue I put the marker here more to ensure we had a proper connection between issues for documentation purposes.

People

Vote (1)
Watch (2)

Dates

  • Created:
    Updated:
    Resolved: