On Nov 1, 2007, at 7:36 PM, Eric Lessard wrote:
Jason,
I tried adding the configuration element with the providerSelection
to my pom like so:
<build>
<plugins>
<plugin>
<groupId> org.codehaus.mojo.groovy</groupId>
<artifactId>groovy-maven-plugin</artifactId>
<extensions>true</extensions>
<configuration>
<providerSelection>1.0</
providerSelection>
</configuration>
</plugin>
</plugins>
</build>
and it didn't make any difference. I am still getting a
java.lang.NoClassDefFoundError: org/codehaus/groovy/runtime/
GStringImpl error when I use the groovy jar file my pom creates
with the program that uses groovy 1.0.
First, make sure you are using version 1.0-beta-3-SNAPSHOT.. or none
of the new runtime stuff will work. W/o specifying the version you
will pick up the latest release which is 1.0-beta-2. You will *need*
to setup a pluginRepository configuration as described here:
http://mojo.codehaus.org/using-sandbox-plugins.html
I tried adding the groovy-runtime-1.0 dependency, but it cannot be
found in the Maven repository (http://repo1.maven.org/maven2).
Anything else I need to do? Do I need the dependency or it is not
necessary?
Thanks a lot for your help!
The 1.0-beta-3-SNAPSHOT artifacts, which have the new runtime bits in
it are *not* yet released and thus you won't find them on central.
They are in the 'haus snapshot repo right now, pending an official
release:
http://snapshots.repository.codehaus.org
--jason
Eric
On Nov 1, 2007 5:08 PM, Jason Dillon <[EMAIL PROTECTED]> wrote:
See these example modules for how to execute/compile using the 1.0
runtime:
http://svn.codehaus.org/mojo/trunk/mojo/groovy/groovy-mojo-
testsuite/src/it/groovy-1.0/
--jason
On Nov 1, 2007, at 12:14 PM, Eric Lessard wrote:
I am using the Maven 2 Groovy plug-in to build a jar file that can
be used with a Groovy 1.0 runtime. If I use the plug-in without
any kind of special configuration and I try to use the generated
jar file with a 1.0 runtime, I get the following exception:
java.lang.NoClassDefFoundError: org/codehaus/groovy/runtime/
GStringImpl
How can I work around this problem?
Here's what my pom file look like:
<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>
<!-- +++ PROJECT INFO +++ -->
<groupId>...</groupId>
<artifactId>...</artifactId>
<packaging>groovy-jar</packaging>
<version>1.0</version>
<name>...</name>
<!-- +++ MODULES (SUB-PROJECTS) +++ -->
<modules>
<!-- None for now -->
</modules>
<!-- +++ GLOBAL DEPENDENCIES +++ -->
<dependencies>
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.13</version>
</dependency>
<dependency>
<groupId>groovy</groupId>
<artifactId>groovy-all</artifactId>
<version>1.0</version>
</dependency>
<dependency>
<groupId>xmlunit</groupId>
<artifactId>xmlunit</artifactId>
<version>1.1</version>
</dependency>
</dependencies>
<!-- +++ BUILD +++ -->
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo.groovy </groupId>
<artifactId>groovy-maven-plugin</artifactId>
<extensions>true</extensions>
</plugin>
</plugins>
</build>
</project>
Any help would be appreciated.
Thanks,
Eric
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email