Configurations

You can have several configurations of the project in one project file. The configuration system is very simple. Every configuration keeps the enable/disable state of all components in the project (it does not keep any component settings). If you enable/disable a component in the project, the component state is updated in the currently selected configuration. If you create a new configuration the current project state is memorized.

Configurations of the current project are listed in the Generator_Configurations folder of the Components view.

Configurations can also hold additional settings that may influence code generation. These settings can be changed in the configuration inspector. See Configuration Inspector for details.

The symbol for conditional compilation is defined if it is supported by the selected language/compiler. The symbol PEcfg_[ConfigurationName] is defined in the processor interface.

You can switch using this symbol between variants of code according to the active configuration (see example in this chapter).

Configuration also stores which processor is selected as the target processor.

If the name of the configuration matches the name of one of the CodeWarrior's targets, the target is automatically selected as an active target when the user runs code generation.

Note: It is possible to have two components with the same name in project. Each of the components could be enabled in different configuration. This way you can have different setup of a component (a component with the same name) in multiple configurations.