Hi there,

I'm trying to use m2eclipse on a project that uses the
apt-maven-plugin [1] and it's having difficulty locating the apt
compiler.

It appears to be a classloader problem in AptUtils.getAptClass [2]
which attempts to locate the tools.jar class com.sun.tools.apt.Main in
the mojo's classloader.  This works fine on the command line when
Maven is run using a JDK (as opposed to a JRE), but fails in m2eclipse
even when Eclipse is run with a JDK.  I'm not surprised given the
complex Eclipse/OSGi classloader hierarchy, but was wondering if
anyone can share their Eclipse knowledge on how to obtain a suitable
classloader that could access tools.jar, if possible?  The alternative
I guess is to fork the execution.

Cheers,

Mark

[1] http://mojo.codehaus.org/apt-maven-plugin/
[2] 
http://svn.codehaus.org/mojo/trunk/mojo/apt-maven-plugin/src/main/java/org/codehaus/mojo/apt/AptUtils.java

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

    http://xircles.codehaus.org/manage_email


Reply via email to