-
Bug
-
Resolution: Done
-
Major
-
None
Within a pom.xml that uses maven-jaxws-tools-plugin, the following error appears on OSX Snow Leopard:
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Building Template Web Service
[INFO] task-segment: [generate-sources]
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Failed to resolve artifact.
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
Alternatively, if you host your own repository you can deploy the file there:
mvn deploy:deploy-file -DgroupId=com.sun -DartifactId=tools -Dversion=1.5.0 -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
Path to dependency:
1) org.jboss.ws.plugins:maven-jaxws-tools-plugin:maven-plugin:1.0.0.GA
2) com.sun:tools:jar:1.5.0
----------
1 required artifact is missing.
for artifact:
org.jboss.ws.plugins:maven-jaxws-tools-plugin:maven-plugin:1.0.0.GA
from the specified remote repositories:
central (http://repo1.maven.org/maven2),
repository.jboss.org (http://repository.jboss.org/maven2),
snapshots.jboss.org (http://snapshots.jboss.org/maven2),
eviwarePluginRepository (http://www.eviware.com/repository/maven2),
Main Maven repo (http://repo1.maven.org/maven2),
JBOSS-WS (http://repository.jboss.org/maven2)
[INFO] ------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4 seconds
[INFO] Finished at: Wed Apr 28 21:41:40 EDT 2010
[INFO] Final Memory: 45M/81M
[INFO] ------------------------------------------------------------------------
According to various posts on the Internet about this same error with other maven plugins, the problem is connected to the fact that the JDK for OSX does not include the tools.jar file. The objects within this file are, instead, available in the classes.jar file.
The pom at http://repository.jboss.org/maven2/org/jboss/ws/plugins/maven-jaxws-tools-plugin/1.0.0.GA/maven-jaxws-tools-plugin-1.0.0.GA.pom does contain the following entry:
<dependency>
<groupId>com.sun</groupId>
<artifactId>tools</artifactId>
<version>1.5.0</version>
<scope>system</scope>
<systemPath>${java.home}/../lib/tools.jar</systemPath> <!-- Required by wsprovide with Metro stack (because of APT) -->
</dependency>
which appears to affix the plugin to version 1.5.0 of the JDK's tools.jar. Obviously, according to the comment, this is needed. Again, tools.jar is not present on OSX and its objects are present in classes.jar.
This error does not occur with the JDK of Windows XP, Windows 7, or Red Hat Linux.
- is related to
-
JBWS-3129 Review maven-jaxws-tools-plugin dependencies
-
- Closed
-