You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by "Matthew Pocock (JIRA)" <ji...@codehaus.org> on 2005/08/30 14:44:02 UTC

[jira] Created: (MNG-806) tools.jar needs to be supported as a normal dependency

tools.jar needs to be supported as a normal dependency
------------------------------------------------------

         Key: MNG-806
         URL: http://jira.codehaus.org/browse/MNG-806
     Project: Maven 2
        Type: Improvement
 Environment: sun sdk
 Reporter: Matthew Pocock


Sun SDKs have a tools.jar that provides API for extending the Sun java tools. This includes APT and Javadoc. There is no mechanism in maven for loading in tools.jar as a dependency. It can be added to the classpath before maven is launched, or manually loaded into the local repository. However, neither of these solutions are very satisfactory.

Could we have some smarts in the dependency loading that understands a magical jdk groupId that resolves to the current JDK being used for compilation? This would let JDK-dependent stuff be linked in. In the case of tools.jar, the dependency snippet would look something like this:

<dependency>
  <groupId>sun.jdk</groupId>
  <artifactId>tools</artifactId>
  <type>jar</type>
  <scope>provided</scope>
</dependency>


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Commented: (MNG-806) tools.jar needs to be supported as a normal dependency

Posted by "Matthew Pocock (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-806?page=comments#action_48361 ] 

Matthew Pocock commented on MNG-806:
------------------------------------

This is great. Adding dependencies to the profiles section would work arround the issue with osx, and possibly be generally useful, particularly if there was a library of profiles & dependencies for different platforms.

> tools.jar needs to be supported as a normal dependency
> ------------------------------------------------------
>
>          Key: MNG-806
>          URL: http://jira.codehaus.org/browse/MNG-806
>      Project: Maven 2
>         Type: Improvement
>  Environment: sun sdk
>     Reporter: Matthew Pocock
>     Assignee: John Casey
>      Fix For: 2.0-beta-1

>
>
> Sun SDKs have a tools.jar that provides API for extending the Sun java tools. This includes APT and Javadoc. There is no mechanism in maven for loading in tools.jar as a dependency. It can be added to the classpath before maven is launched, or manually loaded into the local repository. However, neither of these solutions are very satisfactory.
> Could we have some smarts in the dependency loading that understands a magical jdk groupId that resolves to the current JDK being used for compilation? This would let JDK-dependent stuff be linked in. In the case of tools.jar, the dependency snippet would look something like this:
> <dependency>
>   <groupId>sun.jdk</groupId>
>   <artifactId>tools</artifactId>
>   <type>jar</type>
>   <scope>provided</scope>
> </dependency>

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Updated: (MNG-806) tools.jar needs to be supported as a normal dependency

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-806?page=all ]

Brett Porter updated MNG-806:
-----------------------------

    Fix Version: 2.0-beta-2

> tools.jar needs to be supported as a normal dependency
> ------------------------------------------------------
>
>          Key: MNG-806
>          URL: http://jira.codehaus.org/browse/MNG-806
>      Project: Maven 2
>         Type: Improvement
>  Environment: sun sdk
>     Reporter: Matthew Pocock
>     Assignee: John Casey
>      Fix For: 2.0-beta-2

>
>
> Sun SDKs have a tools.jar that provides API for extending the Sun java tools. This includes APT and Javadoc. There is no mechanism in maven for loading in tools.jar as a dependency. It can be added to the classpath before maven is launched, or manually loaded into the local repository. However, neither of these solutions are very satisfactory.
> Could we have some smarts in the dependency loading that understands a magical jdk groupId that resolves to the current JDK being used for compilation? This would let JDK-dependent stuff be linked in. In the case of tools.jar, the dependency snippet would look something like this:
> <dependency>
>   <groupId>sun.jdk</groupId>
>   <artifactId>tools</artifactId>
>   <type>jar</type>
>   <scope>provided</scope>
> </dependency>

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Closed: (MNG-806) tools.jar needs to be supported as a normal dependency

Posted by "John Casey (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-806?page=all ]
     
John Casey closed MNG-806:
--------------------------

    Resolution: Fixed

I've added a new type of dependency to the mix: scope == system.

This new dependency has the potential to break portability, but is used to incorporate dependencies that are assumed to be on the system already at build time...for instance, tools.jar. To use this for the tools.jar, specify:

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

HOWEVER, this path specification will lead to failure of the build when run on OS X or any non-Sun JDK...hence the portability warning above. My suggestion is that these dependencies be used with the utmost care. Multiple profiles activated based on 'os.name' or similar might help to mitigate the breakage on non-Sun platforms. See it0063 for more information.

> tools.jar needs to be supported as a normal dependency
> ------------------------------------------------------
>
>          Key: MNG-806
>          URL: http://jira.codehaus.org/browse/MNG-806
>      Project: Maven 2
>         Type: Improvement
>  Environment: sun sdk
>     Reporter: Matthew Pocock
>     Assignee: John Casey
>      Fix For: 2.0-beta-2

>
>
> Sun SDKs have a tools.jar that provides API for extending the Sun java tools. This includes APT and Javadoc. There is no mechanism in maven for loading in tools.jar as a dependency. It can be added to the classpath before maven is launched, or manually loaded into the local repository. However, neither of these solutions are very satisfactory.
> Could we have some smarts in the dependency loading that understands a magical jdk groupId that resolves to the current JDK being used for compilation? This would let JDK-dependent stuff be linked in. In the case of tools.jar, the dependency snippet would look something like this:
> <dependency>
>   <groupId>sun.jdk</groupId>
>   <artifactId>tools</artifactId>
>   <type>jar</type>
>   <scope>provided</scope>
> </dependency>

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Closed: (MNG-806) tools.jar needs to be supported as a normal dependency

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-806?page=all ]
     
Brett Porter closed MNG-806:
----------------------------

     Resolution: Fixed
    Fix Version:     (was: 2.0-beta-2)
                 2.0-beta-1

> tools.jar needs to be supported as a normal dependency
> ------------------------------------------------------
>
>          Key: MNG-806
>          URL: http://jira.codehaus.org/browse/MNG-806
>      Project: Maven 2
>         Type: Improvement
>  Environment: sun sdk
>     Reporter: Matthew Pocock
>     Assignee: John Casey
>      Fix For: 2.0-beta-1

>
>
> Sun SDKs have a tools.jar that provides API for extending the Sun java tools. This includes APT and Javadoc. There is no mechanism in maven for loading in tools.jar as a dependency. It can be added to the classpath before maven is launched, or manually loaded into the local repository. However, neither of these solutions are very satisfactory.
> Could we have some smarts in the dependency loading that understands a magical jdk groupId that resolves to the current JDK being used for compilation? This would let JDK-dependent stuff be linked in. In the case of tools.jar, the dependency snippet would look something like this:
> <dependency>
>   <groupId>sun.jdk</groupId>
>   <artifactId>tools</artifactId>
>   <type>jar</type>
>   <scope>provided</scope>
> </dependency>

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Reopened: (MNG-806) tools.jar needs to be supported as a normal dependency

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-806?page=all ]
     
Brett Porter reopened MNG-806:
------------------------------


fixing fix for

> tools.jar needs to be supported as a normal dependency
> ------------------------------------------------------
>
>          Key: MNG-806
>          URL: http://jira.codehaus.org/browse/MNG-806
>      Project: Maven 2
>         Type: Improvement
>  Environment: sun sdk
>     Reporter: Matthew Pocock
>     Assignee: John Casey
>      Fix For: 2.0-beta-2

>
>
> Sun SDKs have a tools.jar that provides API for extending the Sun java tools. This includes APT and Javadoc. There is no mechanism in maven for loading in tools.jar as a dependency. It can be added to the classpath before maven is launched, or manually loaded into the local repository. However, neither of these solutions are very satisfactory.
> Could we have some smarts in the dependency loading that understands a magical jdk groupId that resolves to the current JDK being used for compilation? This would let JDK-dependent stuff be linked in. In the case of tools.jar, the dependency snippet would look something like this:
> <dependency>
>   <groupId>sun.jdk</groupId>
>   <artifactId>tools</artifactId>
>   <type>jar</type>
>   <scope>provided</scope>
> </dependency>

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org