# How to pick toolchain to be used?

**URL:** <https://discuss.gradle.org/t/how-to-pick-toolchain-to-be-used/12094>\
**Category:** Help/Discuss\
**Created:** [October 8, 2015, 4:27pm UTC](https://discuss.gradle.org/t/how-to-pick-toolchain-to-be-used/12094 "2015-10-08T16:27:39Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mareq](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/mareq/32/3118_2.png) [@mareq](https://discuss.gradle.org/u/mareq)\
**Post date:** [October 8, 2015, 4:27pm UTC](https://discuss.gradle.org/t/how-to-pick-toolchain-to-be-used/12094/1 "2015-10-08T16:27:39Z")

</div>

I have several versions of different compilers installed on my system and I want my build to work with all of them. But, at some occasions, I want to force build system to use single particular compiler (e.g. I want to compile everything with gcc 4.8 and I do not want to spend any time on other versions of gcc, nor any version of clang at that particular run). With Boost.Build, I can just say [`./bjam toolset=g++-4.8`](http://www.boost.org/build/doc/html/bbv2/overview/invocation.html), which is defined in my [configuration file](http://www.boost.org/build/doc/html/bbv2/overview/configuration.html) and I will force that particular compiler (potentially with particular flags) to be used. Is there any way of achieving similar effect using Gradle?
