Configuration Files

A set of source files, input libraries, and processing options that are used to generate one or more targets is called a configuration. Each configuration is defined using a configuration file. A VisualAge C++ project must have a configuration file.

A configuration file is similar to a makefile, but with some important differences. Configuration files are easier to create and maintain than makefiles, and using them can simplify the build process. Unlike a makefile, you do not need to specify any C++ file-dependency or processing information. A configuration file simply contains definitions of targets, the source files used to build those targets, and the options used to process the source files and targets. Once you tell VisualAge C++ what to build, it figures out how to do the build. Makefiles can still be used with configuration files.

A configuration file consists of a series of statements called directives that can be nested. The most commonly used directives are target, source, group, and option directives:

There are other directives, such as if, for, and run.

A build processes the configuration file to create a new codestore or to update an existing one. The processing of each configuration file produces one updated codestore. The codestore contains information about the configuration, and is queried to determine changes from build to build.

The default extension for a configuration file is .icc, but you can use any extension. The configuration file can reside in any directory.

When you create a project using the Project SmartGuide, you create the configuration file. The Project SmartGuide can open the Target SmartGuide to allow you to define targets, such as an executable. With a set of views in the Configuration section of the IDE, you can view, add, change and remove target, group, source and option directives easily. You can also apply options to source files, targets and the project, or remove them. To modify other parts of the configuration file, the Configuration section provides Source views where you can use the IDE's Editor to edit the file directly.

Example of a Configuration File



Project
Codestore
How Configuration Files are Processed
When to Use Makefiles
Incremental C++ Builds
Editor Overview


Create a Project
View a Build Setup (Configuration File)
Change a Build Setup (Configuration File)


Configuration File Syntax