On Tue, Apr 1, 2008 at 1:54 AM, Dirk Olmes <[EMAIL PROTECTED]> wrote:
> Milos Kleint wrote:
>
> > On Mon, Mar 31, 2008 at 2:57 AM, Dirk Olmes <[EMAIL PROTECTED]>
> wrote:
> >
> > > Milos Kleint wrote:
> > >  > check the toolchains proposal that is supposed to address this issue.
> > >  >
> > >  > http://docs.codehaus.org/display/MAVEN/Toolchains
> > >
> > >  The way the toolchain proposal chooses is somewhat doable with Maven
> > >  right now: define a set of VM specific properties in each developers'
> > >  settings.xml and use that in the config of the various plugins.
> > >
> >
> > toolchains also ensures that any plugin that understands toochains
> > will ue them, thus instead of configuring compiler-plugin,
> > surefire-plugin, javadoc-plugin etc. you just configure the toolchain.
> >
>
>  But I would still have to tell the plugins which jdk to use from the
> toolchain config, would I?
>

you only tell the toolchains-plugin, the rest of the plugins grabs the
active toolchain from build context.



>
>
> >
> > >  What I don't like about the appraoch is that one has to hand-maintain
> > >  the properties/toolchain.xml still. If I update my JDK, I still have to
> > >  remember updating the settings or the build will break.
> > >
> >
> > oh well, what do you mean by "update my jdk"? the default jdk you run
> > stuff with on your computer?
> >
>
>  No, it's about the various JDKs that are needed to do the build. Example:
> you need JDK 1.4 and JDK 5 for building, that's currently jdk-1.4.2.17 and
> jdk-1.5.0.15 on my machine. I use both JDKs to build the software, only one
> at a time.

That would mean including profile(s) with different toolchain-plugin
configuration.


>
>  I have to update the PATH, JAVA_HOME etc each time a JDK is updated (ok I'm
> on Gentoo so that's all done for my by the distro but for the sake of the
> discussion let's image I would be on windows). With the toolchain I don't
> only have to update my environment but also update the toolchain.xml and
> maybe even some more config locations e.g. netbeans' JDK config comes to
> mind.

yes, you have to include the your build environment setup in the
toolchains file, however you can avoid any updates with smart use of
symlinks I guess. Have ~/javatools/jdk15 and ~/javatools/jdk14
symlinked to the latest and greatest stuff you have.

The netbeans JDK config will by automatically synchronized with
toolchains (actually that's why I actually wrote the toolchains, to
have a way to figure what jdk is used in the project.)

Milos


>
>  -dirk
>
>
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: [EMAIL PROTECTED]
>  For additional commands, e-mail: [EMAIL PROTECTED]
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to