jira.codehaus.org

  • Log In Access more options
    • Online Help
    • Keyboard Shortcuts
    • About JIRA
    • JIRA Credits
    • What?s New
  • Dashboards Access more options (Alt+d)
  • Projects Access more options (Alt+p)
  • Issues Access more options (Alt+i)
  • Enunciate
  • ENUNCIATE-79

Using Maven 2 with Enunciate on OS X results in an error

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.4
  • Fix Version/s: 1.6
  • Component/s: None
  • Labels:
    None
  • Patch Submitted:
    Yes

Description

[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Failed to resolve artifact.

Missing:
----------
1) sun.jdk: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=sun.jdk -DartifactId=tools \
-Dversion=1.5.0 -Dpackaging=jar -Dfile=/path/to/file

Path to dependency:
1) org.codehaus.enunciate:maven-enunciate-plugin:maven-plugin:1.4
2) org.codehaus.enunciate:enunciate-top:jar:1.4
3) org.codehaus.enunciate:enunciate-core:jar:1.4
4) sun.jdk:tools:jar:1.5.0

----------
1 required artifact is missing.

for artifact:
org.codehaus.enunciate:maven-enunciate-plugin:maven-plugin:1.4

from the specified remote repositories:
central (http://repo1.maven.org/maven2),
java.net (https://maven-repository.dev.java.net/nonav/repository)

tools.jar is included in the Mac's classpath by default, so you should only have a dependency on tools.jar when running on Windows. Here's the fix:

http://maven.apache.org/general.html#tools-jar-dependency

Activity

Ascending order - Click to sort in descending order
  • All
  • Comments
  • Work Log
  • History
  • Activity
Hide
Permalink
Ryan Heaton added a comment - 19/Sep/07 4:58 PM

Hmmm... That's how I have it in the pom:

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

Why isn't Maven behaving?

Show
Ryan Heaton added a comment - 19/Sep/07 4:58 PM Hmmm... That's how I have it in the pom: <dependency> <groupId>sun.jdk</groupId> <artifactId>tools</artifactId> <version>1.5.0</version> <scope>system</scope> <systemPath>${java.home}/../lib/tools.jar</systemPath> </dependency> Why isn't Maven behaving?
Hide
Permalink
Matt Raible added a comment - 19/Sep/07 5:08 PM

Do you have it in a profile that's only activated when the JDK is Sun? That's what the example provides. I've seen this issue with other projects.

http://jira.codehaus.org/browse/MOJO-632

Show
Matt Raible added a comment - 19/Sep/07 5:08 PM Do you have it in a profile that's only activated when the JDK is Sun? That's what the example provides. I've seen this issue with other projects. http://jira.codehaus.org/browse/MOJO-632
Hide
Permalink
Ryan Heaton added a comment - 19/Sep/07 5:44 PM

Oh. I see. I'll get this fixed.

Is there a workaround for right now or is this pretty much broken on the Mac OSX until a fix is published?

Show
Ryan Heaton added a comment - 19/Sep/07 5:44 PM Oh. I see. I'll get this fixed. Is there a workaround for right now or is this pretty much broken on the Mac OSX until a fix is published?
Hide
Permalink
Matt Raible added a comment - 20/Sep/07 12:47 AM

I was able to workaround the problem by adding the following to the plugin's configuration:

<dependencies>
<dependency>
<groupId>org.codehaus.enunciate</groupId>
<artifactId>enunciate-core</artifactId>
<version>1.4</version>
<exclusions>
<exclusion>
<groupId>sun.jdk</groupId>
<artifactId>tools</artifactId>
</exclusion>
</exclusions>
</dependency>
</dependencies>

Show
Matt Raible added a comment - 20/Sep/07 12:47 AM I was able to workaround the problem by adding the following to the plugin's configuration: <dependencies> <dependency> <groupId>org.codehaus.enunciate</groupId> <artifactId>enunciate-core</artifactId> <version>1.4</version> <exclusions> <exclusion> <groupId>sun.jdk</groupId> <artifactId>tools</artifactId> </exclusion> </exclusions> </dependency> </dependencies>
Hide
Permalink
Øyvind Matheson Wergeland added a comment - 20/Sep/07 9:25 AM

Another workaround (assuming you don't use a snapshot version) is to edit the enunciate-core pom in your local repo and change systemPath to:
<systemPath>${java.home}/../Classes/classes.jar</systemPath>

Installing classes.jar as tools.jar in your local repo does not solve the problem, probably because systemPath is used.

Overriding systemPath using a profile in my local pom did not work either, but a profile in the enunciate-core pom may do the trick.

I found some useful comments here: http://www.jroller.com/bsnyder/entry/mac_os_x_java_issues

Show
Øyvind Matheson Wergeland added a comment - 20/Sep/07 9:25 AM Another workaround (assuming you don't use a snapshot version) is to edit the enunciate-core pom in your local repo and change systemPath to: <systemPath>${java.home}/../Classes/classes.jar</systemPath> Installing classes.jar as tools.jar in your local repo does not solve the problem, probably because systemPath is used. Overriding systemPath using a profile in my local pom did not work either, but a profile in the enunciate-core pom may do the trick. I found some useful comments here: http://www.jroller.com/bsnyder/entry/mac_os_x_java_issues

People

  • Assignee:
    Ryan Heaton
    Reporter:
    Matt Raible
Vote (0)
Watch (0)

Dates

  • Created:
    19/Sep/07 4:21 PM
    Updated:
    11/Jan/08 2:00 PM
    Resolved:
    11/Jan/08 2:00 PM
  • Atlassian JIRA (v5.0.4#731-sha1:3aa7374)
  • Report a problem
  • Powered by a free Atlassian JIRA open source license for Codehaus. Try JIRA - bug tracking software for your team.