Note that there are some explanatory texts on larger screens.

plurals
  1. POMaven + Delombok issue when compiling in Eclipse
    text
    copied!<p>I have a maven project in Eclipse that uses lombok/delombok.</p> <p>When I build, from Eclipse, using a maven script (e.g. <code>mvn clean package</code>), everything works fine.</p> <p>However, when I run directly from Eclipse (say with a clean/build of my project), I have a classpath issue concerning a class that should be present in the tools.jar from the JDK. I have tried adding the tools.jar directly in my project build path, without any success.</p> <p>[Edit]<br> The stack trace is: </p> <pre><code>03/07/11 23:39:44 CEST: Maven Builder: FULL_BUILD 03/07/11 23:39:44 CEST: [WARN] The POM for com.google.code.gwt-log:gwt-log:jar:3.1.2 is missing, no dependency information available 03/07/11 23:39:44 CEST: Build errors for fiveorbs; org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.projectlombok:maven-lombok-plugin:0.9.3.1:delombok (default) on project fiveorbs: Execution default of goal org.projectlombok:maven-lombok-plugin:0.9.3.1:delombok failed: A required class was missing while executing org.projectlombok:maven-lombok-plugin:0.9.3.1:delombok: com/sun/tools/javac/util/Context ----------------------------------------------------- realm = plugin&gt;org.projectlombok:maven-lombok-plugin:0.9.3.1 strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy urls[0] = file:/C:/Users/Daedin/.m2/repository/org/projectlombok/maven-lombok- plugin/0.9.3.1/maven-lombok-plugin-0.9.3.1.jar urls[1] = file:/C:/Program%20Files/Java/jdk1.6.0_26/jre/../lib/tools.jar urls[2] = file:/C:/Users/Daedin/.m2/repository/org/projectlombok/lombok/0.9.3/lombok-0.9.3.jar urls[3] = file:/C:/Users/Daedin/.m2/repository/org/codehaus/plexus/plexus-utils/1.1/plexus-utils-1.1.jar Number of foreign imports: 1 import: Entry[import from realm ClassRealm[maven.api, parent: null]] ----------------------------------------------------- </code></pre> <p>[/Edit]</p> <p>My configuration is as follows:</p> <ul> <li>Eclipse 3.6 Helios </li> <li>Maven 2.3 </li> <li>JDK 1.6 </li> <li>Lombok 0.9.3 </li> <li>Delombok maven plugin 0.9.3.1 </li> </ul> <p>The part of the pom.xml that contains the declaration of the delombok plugin is as follows:</p> <pre><code>&lt;plugin&gt; &lt;groupId&gt;org.projectlombok&lt;/groupId&gt; &lt;artifactId&gt;maven-lombok-plugin&lt;/artifactId&gt; &lt;version&gt;0.9.3.1&lt;/version&gt; &lt;executions&gt; &lt;execution&gt; &lt;phase&gt;generate-sources&lt;/phase&gt; &lt;goals&gt; &lt;goal&gt;delombok&lt;/goal&gt; &lt;/goals&gt; &lt;/execution&gt; &lt;/executions&gt; &lt;dependencies&gt; &lt;dependency&gt; &lt;groupId&gt;sun.jdk&lt;/groupId&gt; &lt;artifactId&gt;tools&lt;/artifactId&gt; &lt;version&gt;1.6&lt;/version&gt; &lt;scope&gt;system&lt;/scope&gt; &lt;systemPath&gt;${java.home}/../lib/tools.jar&lt;/systemPath&gt; &lt;/dependency&gt; &lt;/dependencies&gt; &lt;/plugin&gt; </code></pre> <p>I apologize if this question seems trivial, but I have been looking for an answer for a couple of hours, and I'm starting to get stuck.</p> <p>Thanks in advance for any hint you may be able to provide - and please let me know if I have omitted any useful information.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload