A data type that defines a set of C compiler configuration.
The CC task.
Attribute | Description | Required |
name | The name of the toolset to use. See the CC task for a list of supported toolsets. | No |
if | Only use this compiler configuration if the specified property is set. | No |
unless | Do not use this compiler configuration if the specified property is set. | No |
Each of the nested elements may appear multiple times.
An additional command-line argument to pass to the compiler.
A set of preprocessor macros to define and/or undefine. See the DefineSet data type for details.
A Path that specifies the directories to use when searching for header files. This path is passed to the compiler, and is used by the CC task when it is performing header file dependency checking.
A Path that specifies the directories to use when searching for system header files. This path is passed to the compiler. It is not used by the CC task when it is performing header file dependency checking.
The following example defines a compiler configuration that is used
when the release.windows
property is set. It configures the
CC task to:
NDEBUG
preprocessor macro.
/Ox
compiler argument to enable maximum optimisation.
<compiler name="msvc" if="release.windows"> <defineset define="NDEBUG"/> <compilerarg value="/Ox"/> </compiler>