My project builds ok in command line, but in Eclipse with 0.0.10 I can not get rid of

22.2.07 16:00:44 CET: Missing:
1) com.sun:tools:jar:1.5.0
 Try downloading the file manually from the project website.
 Then, install it using the command:
     mvn install:install-file -DgroupId=com.sun -DartifactId=tools \
         -Dversion=1.5.0 -Dpackaging=jar -Dfile=/path/to/file
 Path to dependency:
     1) com.interseek:feed-index-server:jar:1.1.5
     2) org.htmlparser:htmlparser:jar:1.6
     3) com.sun:tools:jar:1.5.0
1 required artifact is missing.
for artifact:
 com.interseek:feed-index-server:jar:1.1.5
from the specified remote repositories:
 central (http://repo1.maven.org/maven2)


At first I thought the artifact is really missing but it is not. Then I discovered one of my project's dependency

       <dependency>
           <groupId>org.htmlparser</groupId>
           <artifactId>htmlparser</artifactId>
           <version>1.6</version>
       </dependency>

is itself dependent on

       <dependency>
         <groupId>com.sun</groupId>
         <artifactId>tools</artifactId>
         <version>1.5.0</version>
         <scope>system</scope>
         <systemPath>${java.home}/../lib/tools.jar</systemPath>
       </dependency>

I have put an ant task in my pom to display the ${java.home} just to be sure where it is pointing

           <plugin>
               <artifactId>maven-antrun-plugin</artifactId>
               <executions>
                   <execution>
                       <id>echohome</id>
                       <phase>validate</phase>
                       <goals>
                           <goal>run</goal>
                       </goals>
                       <configuration>
                           <tasks>
                               <echo>JAVA_HOME=${java.home}</echo>
                           </tasks>
                       </configuration>
                   </execution>
               </executions>
           </plugin>

It prints

[INFO] [antrun:run {execution: echohome}]
    [echo] JAVA_HOME=C:\Program Files\Java\jdk1.5.0_11\jre

I have set the system user variable JAVA_HOME to both

   * C:\Program Files\Java\jdk1.5.0_11\jre
   * C:\Program Files\Java\jdk1.5.0_11

and none of them helps getting rid of red error icon on my project's pom.xml which is well-formed and valid.

Any help appreciated,
Borut

Reply via email to