You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Karl Heinz Marbaise <kh...@gmx.de> on 2014/02/19 19:12:44 UTC

Q: Maven Toolchain

Hi,

maybe i didn't see a thing, but can someone explain me the intention of 
the maven toolchain in relationship with a plugin ...

Currently i only see that it can find some kind of executable which is 
configured in somekind of buildcontext...which i currently don't 
understand how to configure (I've taken a look into the 
maven-toolchains-plugin which didn't enlighten me)...

But what are the advantages / disadvantages of that ?

May be i just be blockhead ...;-(


Kind regards
Karl Heinz Marbaise

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


Re: Q: Maven Toolchain

Posted by Karl Heinz Marbaise <kh...@gmx.de>.
Hello Mirko,
Hello Anders,

this have been the information what i have missed...

Thanks for your help.

Kind regards.
Karl-Heinz
 >
> you may take a look at
> https://github.com/mfriedenhagen/org.jacoco.filteringsamples. These
> are some code samples for JDK5, 6, 7 and 8, which will be asmified
> (decompiled) to see differences in byte code produced by different
> JDKs.
>
> This is how the maven-compiler-plugin uses the toolchain:
> https://github.com/apache/maven-plugins/blob/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java#L430
>
> Regards
> Mirko
> Regards Mirko
> --
> http://illegalstateexception.blogspot.com/
> https://github.com/mfriedenhagen/ (http://osrc.dfm.io/mfriedenhagen)
> https://bitbucket.org/mfriedenhagen/
>
>
> On Wed, Feb 19, 2014 at 7:17 PM, Anders Hammar <an...@hammar.net> wrote:
>> One thing it can be used for is to define a different JDK to be used (than
>> the one used for executing Maven itself). More info here:
>> http://maven.apache.org/guides/mini/guide-using-toolchains.html
>>
>> /Anders
>>
>>
>> On Wed, Feb 19, 2014 at 7:12 PM, Karl Heinz Marbaise <kh...@gmx.de>wrote:
>>
>>> Hi,
>>>
>>> maybe i didn't see a thing, but can someone explain me the intention of
>>> the maven toolchain in relationship with a plugin ...
>>>
>>> Currently i only see that it can find some kind of executable which is
>>> configured in somekind of buildcontext...which i currently don't understand
>>> how to configure (I've taken a look into the maven-toolchains-plugin which
>>> didn't enlighten me)...
>>>
>>> But what are the advantages / disadvantages of that ?
>>>
>>> May be i just be blockhead ...;-(
>>>
>>>
>>> Kind regards
>>> Karl Heinz Marbaise
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>>> For additional commands, e-mail: dev-help@maven.apache.org
>>>
>>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>


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


Re: Q: Maven Toolchain

Posted by Mirko Friedenhagen <mf...@gmail.com>.
Hello Karl-Heinz,

you may take a look at
https://github.com/mfriedenhagen/org.jacoco.filteringsamples. These
are some code samples for JDK5, 6, 7 and 8, which will be asmified
(decompiled) to see differences in byte code produced by different
JDKs.

This is how the maven-compiler-plugin uses the toolchain:
https://github.com/apache/maven-plugins/blob/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java#L430

Regards
Mirko
Regards Mirko
--
http://illegalstateexception.blogspot.com/
https://github.com/mfriedenhagen/ (http://osrc.dfm.io/mfriedenhagen)
https://bitbucket.org/mfriedenhagen/


On Wed, Feb 19, 2014 at 7:17 PM, Anders Hammar <an...@hammar.net> wrote:
> One thing it can be used for is to define a different JDK to be used (than
> the one used for executing Maven itself). More info here:
> http://maven.apache.org/guides/mini/guide-using-toolchains.html
>
> /Anders
>
>
> On Wed, Feb 19, 2014 at 7:12 PM, Karl Heinz Marbaise <kh...@gmx.de>wrote:
>
>> Hi,
>>
>> maybe i didn't see a thing, but can someone explain me the intention of
>> the maven toolchain in relationship with a plugin ...
>>
>> Currently i only see that it can find some kind of executable which is
>> configured in somekind of buildcontext...which i currently don't understand
>> how to configure (I've taken a look into the maven-toolchains-plugin which
>> didn't enlighten me)...
>>
>> But what are the advantages / disadvantages of that ?
>>
>> May be i just be blockhead ...;-(
>>
>>
>> Kind regards
>> Karl Heinz Marbaise
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> For additional commands, e-mail: dev-help@maven.apache.org
>>
>>

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


Re: Q: Maven Toolchain

Posted by Bernd Eckenfels <ec...@zusammenkunft.net>.
Am Wed, 19 Feb 2014 19:17:03 +0100
schrieb Anders Hammar <an...@hammar.net>:

> One thing it can be used for is to define a different JDK to be used
> (than the one used for executing Maven itself). More info here:
> http://maven.apache.org/guides/mini/guide-using-toolchains.html

What is quite interesting on this page, it talks about
exec-maven-plugin, but not the maven-invoker-plugin. The later does
require JDK homes and Maven Homes, both could be toolchained. In fact
there is already a bug about it:

https://jira.codehaus.org/browse/MINVOKER-100

We could think about providing the toolchain entries as special
properties, then one could use:

             <mavenHome>${toolchain.mavenhome.3.0.x}</mavenHome>
             <javaHome>${toolchain.jdkhome.1.7.0.51}</javaHome>

Or similiar?

Gruss
Bernd




 maven-invoker-plugin



> 
> /Anders
> 
> 
> On Wed, Feb 19, 2014 at 7:12 PM, Karl Heinz Marbaise
> <kh...@gmx.de>wrote:
> 
> > Hi,
> >
> > maybe i didn't see a thing, but can someone explain me the
> > intention of the maven toolchain in relationship with a plugin ...
> >
> > Currently i only see that it can find some kind of executable which
> > is configured in somekind of buildcontext...which i currently don't
> > understand how to configure (I've taken a look into the
> > maven-toolchains-plugin which didn't enlighten me)...
> >
> > But what are the advantages / disadvantages of that ?
> >
> > May be i just be blockhead ...;-(
> >
> >
> > Kind regards
> > Karl Heinz Marbaise
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> >
> >
> 

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


Re: Q: Maven Toolchain

Posted by Anders Hammar <an...@hammar.net>.
One thing it can be used for is to define a different JDK to be used (than
the one used for executing Maven itself). More info here:
http://maven.apache.org/guides/mini/guide-using-toolchains.html

/Anders


On Wed, Feb 19, 2014 at 7:12 PM, Karl Heinz Marbaise <kh...@gmx.de>wrote:

> Hi,
>
> maybe i didn't see a thing, but can someone explain me the intention of
> the maven toolchain in relationship with a plugin ...
>
> Currently i only see that it can find some kind of executable which is
> configured in somekind of buildcontext...which i currently don't understand
> how to configure (I've taken a look into the maven-toolchains-plugin which
> didn't enlighten me)...
>
> But what are the advantages / disadvantages of that ?
>
> May be i just be blockhead ...;-(
>
>
> Kind regards
> Karl Heinz Marbaise
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>