Re: [mojo-dev] Interacting with the SDK

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: [mojo-dev] Interacting with the SDK

brettporter
Shouldn't this be contributed to commons-lang?

- Brett

jerome lacoste wrote:

> There are many plugins who interact with the SDK, its programs and libraries.
>
> I've found the following piece of code [1] usable for several plugins:
> jar, javadoc, keytool, jdiff (which in fact duplicates partly the
> javadoc plugin). I've had to fix one of those to help support Mac OS X
> (MNG-1130), but not all of those usages have been updated. If we
> support a new platform with a different install, this will have to be
> updated everywhere.
>
> I've also seen code that deals with "tools.jar" (rmic and javac plugin).
>
> This has been duplicated in several places, so I am wondering if we
> should try to share this implementation somewhere. The (small)
> resulting lib would depend on commons-lang.
>
> Anyone finds this interesting?
>
> [1]
>
>     private static File getJDKCommandExe( String command )
>     {
>         String fullCommand = command + ( SystemUtils.IS_OS_WINDOWS ?
> ".exe" : "" );
>
>         File exe;
>
>         // For IBM's JDK 1.2
>         if ( SystemUtils.IS_OS_AIX )
>         {
>             exe = new File( SystemUtils.getJavaHome() + "/../sh", fullCommand );
>         }
>         else if ( SystemUtils.IS_OS_MAC_OSX )
>         {
>             exe = new File( SystemUtils.getJavaHome() + "/bin", fullCommand );
>         }
>         else
>         {
>             exe = new File( SystemUtils.getJavaHome() + "/../bin",
> fullCommand );
>         }
>
>         return exe;
>     }
>
Reply | Threaded
Open this post in threaded view
|

Re: [mojo-dev] Interacting with the SDK

Jerome Lacoste-2
On 11/1/05, Brett Porter <[hidden email]> wrote:
> Shouldn't this be contributed to commons-lang?

Maybe. That's what I first thought. I wondered then if it wasn't
better first to see exactly what were maven needs, write the code
internally to the project, then submit it to commons-lang.

Should I bypass this?

Cheers,

Jerome
Reply | Threaded
Open this post in threaded view
|

Re: [mojo-dev] Interacting with the SDK

brettporter
I think so.

jerome lacoste wrote:

> On 11/1/05, Brett Porter <[hidden email]> wrote:
>
>>Shouldn't this be contributed to commons-lang?
>
>
> Maybe. That's what I first thought. I wondered then if it wasn't
> better first to see exactly what were maven needs, write the code
> internally to the project, then submit it to commons-lang.
>
> Should I bypass this?
>
> Cheers,
>
> Jerome
>