Compile Message Files During a Build (Windows)

On Windows, you can use the Windows message compiler during builds. Simply supply your message files as sources for the build. If the message files have the file extension .mc, the build process recognizes them as message files. If they have any other file extension, you must explicitly specify that their type is mc. The build process runs the message compiler automatically as a build extension separately for each message file listed in your configuration file.

The message compiler creates the following files for each message file supplied as a source:

You can apply the following option to message files:

For example, the following lines from a configuration file compile the message file named msgfile, and apply the option -e hdr.

option mc_opt ("-e hdr") {
source type( "mc" ) "msgfile"
}

The lines above have the same effect as entering the following on the command line:

mc -e hdr msgfile

When you supply message files as sources for a build, you can use the resource source files and the C or C++ source files produced by the message compiler as sources files in the same build. For example you can specify msgfile.mc as a source. If the message compiler creates msgfile.rc and msgfile.h from msgfile.mc, you can also specify msgfile.rc and msgfile.h, along with your other source files, as sources for an executable target.



Configuration Files
Build Extensions and Specification (.ice) Files


Add or Change Source Files
Override the Default Type of a Source
Compile and Bind Resources
Use Resource Sources Files as Sources for a Build
Set Build Options
Build


Build Extensions Supplied with VisualAge C++
Message Compiler Overview